6 changed files with 582 additions and 471 deletions
-
226src/components/doctorCheck/PatientRegisterBase.vue
-
287src/components/patientRegister/PatientRegisterEdit.vue
-
238src/components/patientRegister/PatientRegisterEditQuery.vue
-
286src/components/patientRegister/PatientRegisterForChoose.vue
-
10src/components/patientRegister/PatientRegisterList.vue
-
6src/store/index.js
@ -0,0 +1,238 @@ |
|||
<template> |
|||
<div> |
|||
<div style="display: flex; flex-wrap: wrap; height:32px;border: 1px solid #888;border-radius:5px;background-color: #F5F7FA;"> |
|||
<div class="query"> |
|||
<span class="querySpan">查找: 条码号</span> |
|||
<el-input placeholder="条码号" v-model="query.patientRegisterNo" size="small" |
|||
clearable style="width: 140px"/> |
|||
</div> |
|||
<div class="query"> |
|||
<span class="querySpan">档案号</span> |
|||
<el-input placeholder="档案号" v-model="query.patientNo" size="small" |
|||
clearable style="width: 100px" /> |
|||
</div> |
|||
<div class="query"> |
|||
<span class="querySpan">姓名</span> |
|||
<el-input placeholder="姓名" v-model="query.patientName" size="small" |
|||
clearable style="width: 80px"/> |
|||
</div> |
|||
<div class="query"> |
|||
<span class="querySpan">手机号</span> |
|||
<el-input placeholder="预约手机号" v-model="query.tel" size="small" |
|||
clearable style="width: 120px"/> |
|||
</div> |
|||
</div> |
|||
|
|||
<!-- 体检人员记录列表 --> |
|||
<el-dialog title="体检人员列表" :visible.sync="dialogWin.PatientRegisterForChoose" width="800px" :show-close="false" :close-on-click-modal="false" |
|||
:append-to-body="true"> |
|||
<PatientRegisterForChoose :params="PatientRegisterForChooseParams"/> |
|||
</el-dialog> |
|||
|
|||
|
|||
|
|||
</div> |
|||
</template> |
|||
<script> |
|||
|
|||
import { mapState, mapActions } from "vuex"; |
|||
import { getapi, postapi, putapi, deletapi } from "@/api/api"; |
|||
import mm from "../../utlis/mm"; |
|||
import { getPagePriv,checkPagePriv, objCopy, setNull, dddw,checkIDCode, parseID, birthdayToAge,ageToBirthday, deepCopy, arrayFilter, arrayReduce,parsIcCardtoLocal, photoParse, savePeoplePhoto, arrayExistObj } from "../../utlis/proFunc"; |
|||
import PatientRegisterForChoose from "./PatientRegisterForChoose.vue"; |
|||
export default { |
|||
components: { |
|||
PatientRegisterForChoose |
|||
}, |
|||
data() { |
|||
return { |
|||
query: { |
|||
patientRegisterNo: '', |
|||
patientNo: '', |
|||
patientName: '', |
|||
tel: '' |
|||
}, |
|||
PatientRegisterForChooseParams:{}, |
|||
}; |
|||
}, |
|||
|
|||
created() { |
|||
}, |
|||
|
|||
//挂载完成 |
|||
mounted() { |
|||
this.enterToQuery() |
|||
}, |
|||
|
|||
computed: { |
|||
...mapState(["dialogWin","dataTransOpts"]), |
|||
}, |
|||
methods: { |
|||
|
|||
//回车替代查询 |
|||
enterToQuery() { |
|||
// console.log('enterToTab'); |
|||
this.$nextTick(() => { |
|||
let inputs = document.querySelectorAll(["input"]); //用数组可以读取多个标签的元素 //.inline-input |
|||
|
|||
// 为每个输入框添加键盘事件监听器 |
|||
inputs.forEach((input,i) => { |
|||
// console.log('input',input); |
|||
input.addEventListener('keydown', (event) => { |
|||
if (event.keyCode === 13){ |
|||
// 阻止回车键的默认行为(换行) |
|||
event.preventDefault(); |
|||
|
|||
// 如果按下的是回车查询 |
|||
console.log(input.getAttribute('placeholder'),input.value) |
|||
let placeholder = input.getAttribute('placeholder') |
|||
switch (placeholder) { |
|||
case '条码号': |
|||
if(input.value) this.quickQuery('patientRegisterNo') |
|||
break; |
|||
case '档案号': |
|||
if(input.value) this.quickQuery('patientNo') |
|||
break; |
|||
case '姓名': |
|||
if(input.value) this.quickQuery('patientName') |
|||
break; |
|||
case '预约手机号': |
|||
if(input.value) this.quickQuery('tel') |
|||
break; |
|||
} |
|||
} |
|||
}); |
|||
}); |
|||
}); |
|||
}, |
|||
|
|||
//快速查找个人数据 |
|||
quickQuery(type) { |
|||
let url1 = '/api/app/patientregister/getpatientregisterorpatient' |
|||
let body={} |
|||
let url2 = '/api/app/patientregister/getlistinfilter' |
|||
|
|||
switch (type) { |
|||
case 'patientNo': |
|||
if(!this.query.patientNo) return; |
|||
body = { |
|||
sType:2, |
|||
patientNo:this.query.patientNo |
|||
} |
|||
this.getpatientregisterorpatient(url1,body) |
|||
break; |
|||
case 'patientRegisterNo': |
|||
if(!this.query.patientRegisterNo) return; |
|||
body = { |
|||
sType:1, |
|||
patientRegisterNo:this.query.patientRegisterNo |
|||
} |
|||
this.getpatientregisterorpatient(url1,body) |
|||
break; |
|||
case 'tel': |
|||
if(!this.query.tel) return; |
|||
body = { |
|||
phone:this.query.tel |
|||
} |
|||
this.getlistinfilter(url2,body); |
|||
break; |
|||
case 'patientName': |
|||
if(!this.query.patientName) return; |
|||
body = { |
|||
patientName:this.query.patientName |
|||
} |
|||
this.getlistinfilter(url2,body); |
|||
break; |
|||
default: |
|||
return; |
|||
} |
|||
|
|||
}, |
|||
|
|||
//按流水号或档案号查客户信息 |
|||
getpatientregisterorpatient(url,body){ |
|||
postapi(url,body) |
|||
.then((res) => { |
|||
console.log('getpatientregisterorpatient', res) |
|||
if (res.code == 1) { |
|||
objCopy(res.data, this.form) |
|||
this.dataTransOpts.tableS.patient_register.id = res.data.id |
|||
setTimeout(() => { |
|||
this.dataTransOpts.refresh.patient_register.S++ |
|||
}, 20); |
|||
// this.patientRegister.patientRegisterId = res.data.id |
|||
// this.patientRegister.photo = res.data.photo |
|||
// this.getPatientRegisterAbs(res.data.id) |
|||
}else if(res.code == 0){ |
|||
this.$message.info("未找到相关信息") |
|||
} |
|||
}); |
|||
}, |
|||
|
|||
//按手机号或姓名查找客户信息 |
|||
getlistinfilter(url,body){ |
|||
// url = '/api/app/patientregister/getlistinfilter' |
|||
// postapi(url, body) |
|||
// .then((res) => { |
|||
// if (res.code != -1) { |
|||
// if(res.data.items.length == 0){ |
|||
// this.$message.info("未找到相关信息") |
|||
// }else if(res.data.items.length == 1){ |
|||
// objCopy(res.data.items[0], this.form) |
|||
// this.dataTransOpts.tableS.patient_register.id = res.data.items[0].id |
|||
// setTimeout(() => { |
|||
// this.dataTransOpts.refresh.register_asbitem.M++ |
|||
// }, 20); |
|||
// // objCopy(res.data.items[0], this.patientRegister.patientRegisterRd) |
|||
// // this.patientRegister.patientRegisterId = res.data.items[0].id |
|||
// // this.patientRegister.photo = res.data.items[0].photo |
|||
// // this.getPatientRegisterAbs(res.data.items[0].id) |
|||
// }else{ |
|||
// //显示列表,供选择 |
|||
// this.patientRegisters = res.data.items |
|||
// this.registerVisible = true |
|||
// } |
|||
// } |
|||
// }); |
|||
this.PatientRegisterForChooseParams = body |
|||
this.dialogWin.PatientRegisterForChoose = true |
|||
setTimeout(() => { |
|||
this.dataTransOpts.refresh.patient_register.M++ |
|||
}, 10); |
|||
}, |
|||
}, |
|||
|
|||
//监听事件 |
|||
watch: { |
|||
// 清空查询条件 |
|||
"dataTransOpts.plus.clearPatientRegisterQuery":{ |
|||
immediate:true, |
|||
handler(newVal, oldVal) { |
|||
console.log(`watch 清空查询条件 newVal:${newVal} oldVal:${oldVal}`); |
|||
this.query.patientRegisterNo = '' |
|||
this.query.patientNo = '' |
|||
this.query.patientName = '' |
|||
this.query.tel = '' |
|||
} |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
|||
<style scoped> |
|||
|
|||
|
|||
.btn { |
|||
margin-top: 5px; |
|||
} |
|||
|
|||
.commonbutton { |
|||
width: 100px; |
|||
} |
|||
|
|||
.query { |
|||
margin-left: 10px; |
|||
} |
|||
.querySpan { |
|||
margin-right: 2px; |
|||
} |
|||
</style> |
|||
@ -0,0 +1,286 @@ |
|||
<template> |
|||
<div> |
|||
<div> |
|||
<el-table :data="patientRegisters" border width="800" height="480" highlight-current-row |
|||
@row-click="registerRowClick" @row-dblclick="rowDblclick" size="small"> |
|||
<el-table-column prop="completeFlag" label="体检进度"> |
|||
<template slot-scope="scope"> |
|||
<div>{{ dddw(dict.completeFlag, "id", scope.row.completeFlag, "displayName") }}</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="guidePrintTimes" label="打印" width="50"> |
|||
<template slot-scope="scope"> |
|||
<i class="el-icon-printer" v-if="scope.row.guidePrintTimes > 0" style="font-size: 24px;color: green;"></i> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="isLock" label="锁住"> |
|||
<template slot-scope="scope"> |
|||
<div>{{ scope.row.isLock == "Y" ? "是" : "否" }}</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="customerOrgParentName" label="单位" width="180"> |
|||
<template slot-scope="scope"> |
|||
<div>{{ scope.row.customerOrgParentName ? scope.row.customerOrgParentName : scope.row.customerOrgName }}</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="customerOrgName" label="部门" width="180"> |
|||
<template slot-scope="scope"> |
|||
<div>{{ scope.row.customerOrgParentName ? scope.row.customerOrgName : "" }}</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="patientName" label="姓名" /> |
|||
<el-table-column prop="sexId" label="性别"> |
|||
<template slot-scope="scope"> |
|||
<div>{{ dddw(dict.sex, "id", scope.row.sexId, "displayName") }}</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="age" label="年龄" /> |
|||
<el-table-column prop="patientRegisterNo" label="条码号" width="150" /> |
|||
<el-table-column prop="patientNo" label="档案号" /> |
|||
<el-table-column prop="medicalTimes" label="体检次数"></el-table-column> |
|||
<el-table-column label="分组/套餐" width="150"> |
|||
<template slot-scope="scope"> |
|||
<div v-if="scope.row.medicalPackageId !== dict.personOrgId && scope.row.customerOrgId === dict.personOrgId"> |
|||
{{ dddw(dict.medicalPackage, "id", scope.row.medicalPackageId, "displayName") }} |
|||
</div> |
|||
<div v-if="scope.row.medicalPackageId !== dict.personOrgId && scope.row.customerOrgId !== dict.personOrgId"> |
|||
{{ dddw(dict.customerOrgGroupAll, "id", scope.row.customerOrgGroupId, "displayName") }} |
|||
</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="nationId" label="民族"> |
|||
<template slot-scope="scope"> |
|||
<div> |
|||
{{ dddw(dict.nation, "nationId", scope.row.nationId, "displayName") }} |
|||
</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="idNo" label="身份证" width="150" /> |
|||
<el-table-column prop="birthDate" label="出生日期" width="100"> |
|||
<template slot-scope="scope"> |
|||
<div v-if="scope.row.birthDate"> |
|||
{{ moment(scope.row.birthDate).format("yyyy-MM-DD") }} |
|||
</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="email" label="邮箱" width="180" /> |
|||
<el-table-column prop="mobileTelephone" label="手机" width="100" /> |
|||
<el-table-column prop="telephone" label="电话" width="100" /> |
|||
<el-table-column prop="address" label="地址" width="300" /> |
|||
<el-table-column prop="medicalCardNo" label="体检卡号" /> |
|||
<el-table-column prop="jobCardNo" label="工卡号" /> |
|||
<el-table-column prop="maritalStatusId" label="婚姻状况"> |
|||
<template slot-scope="scope"> |
|||
<div> |
|||
{{ dddw(dict.maritalStatus, "id", scope.row.maritalStatusId, "displayName") }} |
|||
</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="medicalTypeId" label="体检类别"> |
|||
<template slot-scope="scope"> |
|||
<div v-if="scope.row.medicalTypeId !== dict.personOrgId"> |
|||
{{ dddw(dict.medicalType, "id", scope.row.medicalTypeId, "displayName") }} |
|||
</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="personnelTypeId" label="人员类别"> |
|||
<template slot-scope="scope"> |
|||
<div v-if="scope.row.personnelTypeId !== dict.personOrgId"> |
|||
{{ dddw(dict.personnelType, "id", scope.row.personnelTypeId, "displayName") }} |
|||
</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="jobPost" label="职务" /> |
|||
<el-table-column prop="jobTitle" label="职称" /> |
|||
<el-table-column prop="salesman" label="介绍人" /> |
|||
<el-table-column prop="isVip" label="是否VIP"> |
|||
<template slot-scope="scope"> |
|||
<div>{{ scope.row.isVip == "Y" ? "是" : "否" }}</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="creatorName" label="登记人" /> |
|||
<el-table-column prop="creationTime" label="登记日期" width="100"> |
|||
<template slot-scope="scope"> |
|||
<div v-if="scope.row.creationTime">{{ moment(scope.row.creationTime).format("yyyy-MM-DD") }}</div> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column prop="isUpload" label="是否上传"> |
|||
<template slot-scope="scope"> |
|||
<div>{{ scope.row.isUpload == "Y" ? "是" : "否" }}</div> |
|||
</template> |
|||
</el-table-column> |
|||
|
|||
<!-- |
|||
"sexHormoneTermId": "00000000-0000-0000-0000-000000000000", |
|||
"interposeMeasure": null, |
|||
"medicalConclusionId": "00000000-0000-0000-0000-000000000000", |
|||
"reportPrintTimes": 0, |
|||
"isMedicalStart": "N", |
|||
"medicalStartDate": "6/28/2023", |
|||
"isRecoverGuide": "N", |
|||
"summaryDate": "", |
|||
"summaryDoctor": null, |
|||
"isAudit": "N", |
|||
"auditDoctor": null, |
|||
"auditDate": "", |
|||
"isNameHide": "N", |
|||
"isPhoneFollow": "N", |
|||
"thirdInfo": null, |
|||
"guidePrintTimes": null, |
|||
"remark": null, |
|||
"organizationUnitId": "00000000-0000-0000-0000-000000000000", |
|||
"customerOrgRegisterId": "00000000-0000-0000-0000-000000000000", |
|||
"lastModifierName": "", |
|||
"lastModificationTime": null, |
|||
"lastModifierId": null, |
|||
"creatorId": null, |
|||
"id": "3a0c196d-a6d0-37fe-5c32-4806bdc4530f" |
|||
--> |
|||
</el-table> |
|||
<div style="display: flex;margin-top: 5px;justify-content:space-between;"> |
|||
<div></div> |
|||
<div style="display: flex;"> |
|||
<el-button @click="dialogWin.PatientRegisterForChoose = false" style="width:90px;">取消</el-button> |
|||
<el-button type="primary" @click="btnOk" style="width:90px;">确定</el-button> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import moment from "moment"; |
|||
import { mapState, mapActions } from "vuex"; |
|||
import { getapi, postapi, putapi, deletapi } from "@/api/api"; |
|||
import Sortable from "sortablejs"; |
|||
import FileSaver from 'file-saver'; |
|||
import html2canvas from 'html2canvas'; |
|||
|
|||
import { |
|||
dddw, |
|||
objCopy, |
|||
arrayReduce, |
|||
arrayExistObj, |
|||
deepCopy, |
|||
} from "../../utlis/proFunc"; |
|||
|
|||
import ElProgressOCX from "../report/ElProgressOCX.vue"; |
|||
|
|||
export default { |
|||
components: { |
|||
ElProgressOCX, |
|||
}, |
|||
props:["params"], // params |
|||
data() { |
|||
return { |
|||
patientRegisterId:'', // 选中的体检人员ID |
|||
patientRegisters:[], //体检人员列表信息 |
|||
}; |
|||
}, |
|||
|
|||
created() { |
|||
|
|||
}, |
|||
|
|||
//挂载完成 |
|||
mounted() { |
|||
|
|||
}, |
|||
computed: { |
|||
...mapState([ |
|||
"window", |
|||
"dataTransOpts", |
|||
"dialogWin", |
|||
"dict", |
|||
"elProgress", |
|||
"patientRegister", |
|||
"customerOrg", |
|||
]), |
|||
}, |
|||
methods: { |
|||
moment,dddw,deepCopy, |
|||
|
|||
getPatientregisterList(){ |
|||
this.patientRegisterId = "" //先清除选择的体检人员ID |
|||
// params = { |
|||
// patientName:v, |
|||
// isFilterPreRegistration:'Y' //是否需要过滤预登记数据 Y=过滤预登记数据 N=不过滤 默认为N (备注:只有CompleteFlag参数的值不为0的情况才有效,null值也有效) |
|||
// } |
|||
postapi('/api/app/patientregister/getlistinfilter', this.params).then(res => { |
|||
if (res.code != -1) { |
|||
if(res.data.items.length == 0){ |
|||
this.dataTransOpts.tableS.patient_register.id = '' |
|||
setTimeout(() => { |
|||
this.dataTransOpts.refresh.patient_register.S++ |
|||
}, 20); |
|||
this.dialogWin.PatientRegisterForChoose = false |
|||
this.$message.warning('未找到相关信息') |
|||
}else if(res.data.items.length == 1){ |
|||
this.rowDblclick(res.data.items[0]) |
|||
}else{ |
|||
this.patientRegisters = res.data.items |
|||
} |
|||
} |
|||
}) |
|||
|
|||
}, |
|||
|
|||
|
|||
// 选中记录 |
|||
registerRowClick(row){ |
|||
this.patientRegisterId = row.id |
|||
}, |
|||
|
|||
// 双击 选中记录 并关闭窗口 |
|||
rowDblclick(row){ |
|||
this.registerRowClick(row) |
|||
this.btnOk() |
|||
}, |
|||
|
|||
btnOk(){ |
|||
if(!this.patientRegisterId){ |
|||
this.$message.warning("请选择体检人员!") |
|||
return |
|||
} |
|||
this.dataTransOpts.tableS.patient_register.id = this.patientRegisterId |
|||
setTimeout(() => { |
|||
this.dataTransOpts.refresh.patient_register.S++ |
|||
}, 20); |
|||
this.dialogWin.PatientRegisterForChoose = false |
|||
}, |
|||
|
|||
}, |
|||
|
|||
//监听事件 |
|||
watch: { |
|||
// 刷新体检人员登记列表 |
|||
"dataTransOpts.refresh.patient_register.M":{ |
|||
immediate: true, // 立即执行 |
|||
// deep: true, // 深度监听复杂类型内变化 |
|||
handler(newVal,oldVal){ |
|||
console.log(`watch: 刷新体检人员列表 newVal: ${newVal} oldVal:${oldVal}`) |
|||
this.getPatientregisterList() |
|||
} |
|||
}, |
|||
}, |
|||
}; |
|||
</script> |
|||
<style scoped> |
|||
@import "../../assets/css/global_input.css"; |
|||
@import "../../assets/css/global_table.css"; |
|||
@import "../../assets/css/global.css"; |
|||
|
|||
|
|||
.box { |
|||
display: flex; |
|||
} |
|||
|
|||
.listBtn { |
|||
margin-top: 5px; |
|||
text-align: center; |
|||
} |
|||
|
|||
.btnClass { |
|||
width: 100px; |
|||
} |
|||
|
|||
</style> |
|||
Write
Preview
Loading…
Cancel
Save
Reference in new issue