From 97759b4bdad04923036ae10c48593dd60471aaf9 Mon Sep 17 00:00:00 2001 From: pengjun <158915633@qq.com> Date: Sat, 4 May 2024 00:04:54 +0800 Subject: [PATCH] 000 --- .../doctorCheck/PatientRegisterBase.vue | 15 +++++++++--- .../patientRegister/PatientRegisterEdit.vue | 2 +- .../patientRegister/patientRegisterQuery.vue | 18 ++++++++++---- .../sumDoctorCheck/CheckDetails.vue | 6 ++--- .../sumDoctorCheck/SumAsbItemStatus.vue | 4 ++-- src/components/sumDoctorCheck/SumHistory.vue | 4 ++-- src/components/sumDoctorCheck/SumItems.vue | 6 ++--- src/components/sumDoctorCheck/SumSug.vue | 5 ++-- src/store/index.js | 3 ++- src/utlis/proApi.js | 6 ++--- src/views/doctorCheck/sumDoctorCheck.vue | 24 +++++++++++++------ 11 files changed, 62 insertions(+), 31 deletions(-) diff --git a/src/components/doctorCheck/PatientRegisterBase.vue b/src/components/doctorCheck/PatientRegisterBase.vue index ea96fbe..56c71cb 100644 --- a/src/components/doctorCheck/PatientRegisterBase.vue +++ b/src/components/doctorCheck/PatientRegisterBase.vue @@ -296,20 +296,29 @@ export default { switch (placeholder) { case '条码号': if (input.value) this.onQueryByPatientRegisterNo() + input.select() break; case '档案号': if (input.value) this.onQueryByPatientNo() + input.select() break; case '姓名': if (input.value) this.getlistinfilterByName(input.value) + input.select() break; } - input.select() } }); - input.addEventListener('click', (event) => { - input.select() + input.addEventListener('click', (event) => { + let placeholder = input.getAttribute('placeholder') + switch (placeholder) { + case '条码号': + case '档案号': + case '姓名': + input.select() + break; + } }); }); diff --git a/src/components/patientRegister/PatientRegisterEdit.vue b/src/components/patientRegister/PatientRegisterEdit.vue index 032c875..48c0721 100644 --- a/src/components/patientRegister/PatientRegisterEdit.vue +++ b/src/components/patientRegister/PatientRegisterEdit.vue @@ -848,7 +848,7 @@ export default { this.form.medicalCenterId = this.peisid; //体检中收 this.form.customerOrgId = this.preCustomerOrgId || this.dict.personOrgId //体检单位 this.form.customerOrgParentId = await this.getParentCustomerOrgId(this.form.customerOrgId) //体检父单位 - + this.dataTransOpts.refresh.register_check_asbitem.D++ //触发所选组合项目刷新 } else { // let res = await getapi(`/api/app/patient-register/${patientRegisterId}`) let res = await postapi('/api/app/patientregister/getinfoorpatient', { patientRegisterId }) diff --git a/src/components/patientRegister/patientRegisterQuery.vue b/src/components/patientRegister/patientRegisterQuery.vue index d7207b2..3bc6d2e 100644 --- a/src/components/patientRegister/patientRegisterQuery.vue +++ b/src/components/patientRegister/patientRegisterQuery.vue @@ -223,14 +223,24 @@ export default { case '预约手机号': case '身份证号': if(input.value) this.patientRegister.query.times++; + input.select() break; - } - input.select() + } } }); - input.addEventListener('click', (event) => { - input.select() + input.addEventListener('click', (event) => { + let placeholder = input.getAttribute('placeholder') + switch (placeholder) { + case '条码号': + case '档案号': + case '姓名': + case '预约手机号': + case '身份证号': + if(input.value) this.patientRegister.query.times++; + input.select() + break; + } }); }); }); diff --git a/src/components/sumDoctorCheck/CheckDetails.vue b/src/components/sumDoctorCheck/CheckDetails.vue index e7b18a0..2ebc8af 100644 --- a/src/components/sumDoctorCheck/CheckDetails.vue +++ b/src/components/sumDoctorCheck/CheckDetails.vue @@ -51,7 +51,7 @@ import { getapi, postapi, putapi, deletapi } from "@/api/api"; import { arrayExistObj, getColorStr } from '@/utlis/proFunc'; export default { components: {}, - props: ["patientRegisterId"], + props: ["patientRegisterId","tabChoosed"], data() { return { tableData: [], @@ -111,12 +111,12 @@ export default { //监听事件 watch: { - // 虚拟表 触发强制刷新 (sumDoctor.M 合并包含:综述、建议、对比、历史等,不包含总检诊断) + // 虚拟表 触发强制刷新 sumDoctor.M 合并包含:综述、建议、对比、历史等,不包含总检诊断) "dataTransOpts.refresh.sumDoctor.M": { // immediate:true, handler(newVal, oldVal) { console.log(`watch 总检--检查明细结果 newVal: ${newVal}, oldVal: ${oldVal} patientRegisterId: ${this.dataTransOpts.tableS.patient_register.id}`); - this.CheckDetails(this.dataTransOpts.tableS.patient_register.id); + if(newVal != oldVal && this.tabChoosed == '2') this.CheckDetails(this.dataTransOpts.tableS.patient_register.id); } }, diff --git a/src/components/sumDoctorCheck/SumAsbItemStatus.vue b/src/components/sumDoctorCheck/SumAsbItemStatus.vue index 25e1df8..40d212f 100644 --- a/src/components/sumDoctorCheck/SumAsbItemStatus.vue +++ b/src/components/sumDoctorCheck/SumAsbItemStatus.vue @@ -37,7 +37,7 @@ import { getapi, postapi, putapi, deletapi } from "@/api/api"; export default { components: {}, - props: ['patientRegisterId'], + props: ['patientRegisterId','tabChoosed'], data() { return { data: { @@ -99,7 +99,7 @@ export default { // immediate:true, handler(newVal, oldVal) { console.log(`watch 总检--检查状态汇总 newVal: ${newVal}, oldVal: ${oldVal} patientRegisterId: ${this.patientRegisterId}`); - this.getSumAsbItemStatus(this.patientRegisterId); + if(newVal != oldVal && this.tabChoosed == '1') this.getSumAsbItemStatus(this.patientRegisterId); } }, diff --git a/src/components/sumDoctorCheck/SumHistory.vue b/src/components/sumDoctorCheck/SumHistory.vue index c2e5d96..0985f44 100644 --- a/src/components/sumDoctorCheck/SumHistory.vue +++ b/src/components/sumDoctorCheck/SumHistory.vue @@ -33,7 +33,7 @@ import { getapi, postapi, putapi, deletapi } from "@/api/api"; import { arrayExistObj } from '@/utlis/proFunc'; export default { components: {}, - props: ["patientId"], + props: ["patientId","tabChoosed"], data() { return { tableData: [], //显示数据 @@ -96,7 +96,7 @@ export default { // immediate:true, handler(newVal, oldVal) { console.log(`watch 总检--历次综述建议 newVal: ${newVal}, oldVal: ${oldVal} patientId: ${this.patientId}`); - this.SumHistory(this.patientId) + if(newVal != oldVal && this.tabChoosed == '6') this.SumHistory(this.patientId) } }, diff --git a/src/components/sumDoctorCheck/SumItems.vue b/src/components/sumDoctorCheck/SumItems.vue index a51c772..87b28ab 100644 --- a/src/components/sumDoctorCheck/SumItems.vue +++ b/src/components/sumDoctorCheck/SumItems.vue @@ -77,7 +77,7 @@ import { getapi, postapi, putapi, deletapi } from "@/api/api"; import { arrayExistObj, getColorStr } from '@/utlis/proFunc'; export default { components: {}, - props: ["patientId"], + props: ["patientId","tabChoosed"], data() { return { RegisterCheckList: [], @@ -240,8 +240,8 @@ export default { "dataTransOpts.refresh.sumDoctor.M": { // immediate:true, handler(newVal, oldVal) { - console.log(`watch 总检--横向对比 newVal: ${newVal}, oldVal: ${oldVal} patientId: ${this.patientId}`); - this.registerCheckList(this.patientId) + console.log(`watch 总检--横向对比 newVal: ${newVal}, oldVal: ${oldVal} patientId: ${this.dataTransOpts.tableS.patient_register.id}`); + if(newVal != oldVal && this.tabChoosed == '5') this.registerCheckList(this.dataTransOpts.tableS.patient_register.id) } }, }, diff --git a/src/components/sumDoctorCheck/SumSug.vue b/src/components/sumDoctorCheck/SumSug.vue index a021b77..d0965eb 100644 --- a/src/components/sumDoctorCheck/SumSug.vue +++ b/src/components/sumDoctorCheck/SumSug.vue @@ -226,7 +226,7 @@ import { getapi, postapi, putapi, deletapi } from "@/api/api"; import { getPagePriv, checkPagePriv, deepCopy, arrayExistObj } from '../../utlis/proFunc'; export default { components: {}, - props: ["patientRegisterId"], + props: ["patientRegisterId","tabChoosed"], data() { return { pagePriv: { @@ -431,6 +431,7 @@ export default { summaryList.push({ id: `summary_${i}`, summaryTitle: ' ', details }) }); this.sumDoctorCheck.summaryList = deepCopy(summaryList) + // 自动高度有问题,需要这样处理一下 setTimeout(() => { this.sumDoctorCheck.summaryList = deepCopy(res.data); @@ -879,7 +880,7 @@ export default { // immediate:true, handler(newVal, oldVal) { console.log(`watch 总检--综述建议 newVal: ${newVal}, oldVal: ${oldVal} patientRegisterId: ${this.dataTransOpts.tableS.patient_register.id}`); - this.getHaveSumData(this.dataTransOpts.tableS.patient_register.id) + if(newVal != oldVal && this.tabChoosed == '1') this.getHaveSumData(this.dataTransOpts.tableS.patient_register.id) } }, }, diff --git a/src/store/index.js b/src/store/index.js index c23f62b..286c29e 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -315,7 +315,8 @@ export default new Vuex.Store({ role_menu_info: { S: 0, M: 0 }, // 角色对应的菜单 sum_diagnosis: { S: 0, M: 0 }, // 总检诊断 - sumDoctor: { S: 0, M: 0 }, // 虚拟表 触发强制刷新 (sumDoctor.M 合并包含:综述、建议、对比、历史等,不包含总检诊断) + sumDoctor: { S: 0, M: 0 }, // 总检--综述 触发强制刷新 (sumDoctor.M 合并包含:综述、建议、对比、历史等,不包含总检诊断) + }, //表当前数据(单条记录 S--single) tableS: { diff --git a/src/utlis/proApi.js b/src/utlis/proApi.js index eb0e57a..d7114b6 100644 --- a/src/utlis/proApi.js +++ b/src/utlis/proApi.js @@ -61,10 +61,10 @@ function photoParse(photo) { //console.log(sysConfig,photo) let lphoto = '' //data:image、UpLoad/、/pic/Photo.jpg if (!photo) return '/pic/Photo.jpg' - if (photo.indexOf("UpLoad/") > - 1) { - lphoto = sysConfig.apiurl + '/' + photo + '?' + new Date().getTime() - } else { + if (photo.toLowerCase().indexOf("http") > - 1) { lphoto = photo + } else { + lphoto = sysConfig.apiurl + '/' + photo + '?' + new Date().getTime() } //console.log(lphoto) return lphoto diff --git a/src/views/doctorCheck/sumDoctorCheck.vue b/src/views/doctorCheck/sumDoctorCheck.vue index 2077e37..9de0774 100644 --- a/src/views/doctorCheck/sumDoctorCheck.vue +++ b/src/views/doctorCheck/sumDoctorCheck.vue @@ -28,25 +28,27 @@
- +
- - + + + + --> - + - + + @@ -221,11 +223,19 @@ export default { console.log("dict", this.dict); }, - + + }, //监听事件() watch: { + "tabChoosed":{ + // immediate:true, + handler(newVal, oldVal) { + console.log(`watch 总检--历次综述建议 newVal: ${newVal}, oldVal: ${oldVal} `); + if(newVal != oldVal) this.dataTransOpts.refresh.sumDoctor.M++ + } + }, }, };