diff --git a/src/components/patientRegister/PatientRegisterList.vue b/src/components/patientRegister/PatientRegisterList.vue index aafdb71..78b860e 100644 --- a/src/components/patientRegister/PatientRegisterList.vue +++ b/src/components/patientRegister/PatientRegisterList.vue @@ -381,6 +381,8 @@ export default { this.$nextTick(() => { this.scrollFull() }) + + }, computed: { ...mapState([ diff --git a/src/components/sumDoctorCheck/SumSug.vue b/src/components/sumDoctorCheck/SumSug.vue index bfa36a7..21df0f6 100644 --- a/src/components/sumDoctorCheck/SumSug.vue +++ b/src/components/sumDoctorCheck/SumSug.vue @@ -235,7 +235,7 @@
+ :filter-method="filterMethod" popper-class="diagnosisSelect" :popper-append-to-body="false">
@@ -266,7 +266,10 @@ export default { dialogDiagnosises: false, // 诊断选择窗口 diagnosises: [], // 诊断 diagnosisesFilter: [], // 可选的诊断 - choosedDiagnosisIds: [], // 已选的诊断集合 + choosedDiagnosisIds: [], // 已选的诊断 id 集合 + disabledDiagnosisIds: [], // 不可选的诊断 id 集合 + diagnosisesChoosed:[], // 已选的诊断集合 + collapse: false, // 折叠/展开全部建议 dispTermReason: 'N', // 显示医学解释与常见原因 @@ -409,23 +412,50 @@ export default { btnChooseDiagnosis(index) { this.suggestionCurRow = index this.choosedDiagnosisIds = this.sumDoctorCheck.suggestionList[index].diagnosisIds - let diagnosisIds = [] + + this.disabledDiagnosisIds = [] this.sumDoctorCheck.suggestionList.forEach((e, i) => { if (i != index) { - if (e.diagnosisIds) diagnosisIds = diagnosisIds.concat(e.diagnosisIds) + if (e.diagnosisIds) this.disabledDiagnosisIds = this.disabledDiagnosisIds.concat(e.diagnosisIds) } }); - this.diagnosisesFilter = this.diagnosises.filter(e => { - return diagnosisIds.indexOf(e.id) == -1 - }) + + this.diagnosisesFilter = [] + this.diagnosisesChoosed = [] + + this.diagnosises.forEach(e => { + if(this.disabledDiagnosisIds.indexOf(e.id) == -1){ + if(this.choosedDiagnosisIds.indexOf(e.id) == -1){ + if(this.diagnosisesFilter.length < 20) this.diagnosisesFilter.push(e) + }else{ + this.diagnosisesChoosed.push(e) + } + } + }); + this.diagnosisesFilter = this.diagnosisesFilter.concat(this.diagnosisesChoosed) this.dialogDiagnosises = true + }, + //快速选择组合项目时,调整可按拼间简码及简称查找 + filterMethod(keyWords) { + if (keyWords) { + let diagnosisesFilter = [] + this.diagnosises.forEach(e => { + if(this.disabledDiagnosisIds.indexOf(e.id) == -1){ + if(this.choosedDiagnosisIds.indexOf(e.id) == -1){ + if(e.displayName.toLowerCase().indexOf(keyWords.toLowerCase()) > - 1 || e.simpleCode.toLowerCase().indexOf(keyWords.toLowerCase()) > - 1){ + if(diagnosisesFilter.length < 20) diagnosisesFilter.push(e) + } + } + } + }) + this.diagnosisesFilter = diagnosisesFilter.concat(this.diagnosisesChoosed) + } }, btnOkDiagnosis() { this.changeDiagnosis(this.choosedDiagnosisIds) this.dialogDiagnosises = false - }, // 获取人员是否已总检过 diff --git a/src/views/doctorCheck/doctorCheck.vue b/src/views/doctorCheck/doctorCheck.vue index 86936c9..dce0cbb 100644 --- a/src/views/doctorCheck/doctorCheck.vue +++ b/src/views/doctorCheck/doctorCheck.vue @@ -133,15 +133,20 @@ export default { mounted() { this.dictInit(); - document.addEventListener("contextmenu", (e) => { - if (this.$peisAPI) { - e.preventDefault(); - this.$peisAPI.contextMenuForPeis() - } - }) - + // window.addEventListener("contextmenu", (e) => { + // if (this.$peisAPI) { + // e.preventDefault(); + // this.$peisAPI.contextMenuForPeis() + // } + // }) }, + // deactivated() { + // window.removeEventListener('contextmenu', (e) => { + // console.log('window.removeEventListener') + // }); + // }, + computed: { ...mapState(["window", "dataTransOpts", "dict", "patientRegister", "customerOrg", "doctorCheck", "sumDoctorCheck"]), }, diff --git a/src/views/doctorCheck/sumDoctorCheck.vue b/src/views/doctorCheck/sumDoctorCheck.vue index 6ca468f..273cc36 100644 --- a/src/views/doctorCheck/sumDoctorCheck.vue +++ b/src/views/doctorCheck/sumDoctorCheck.vue @@ -107,12 +107,13 @@ export default { mounted() { this.dictInit(); - document.addEventListener("contextmenu", (e) => { - if (this.$peisAPI) { - e.preventDefault(); - this.$peisAPI.contextMenuForPeis() - } - }) + // document.addEventListener("contextmenu", (e) => { + // if (this.$peisAPI) { + // e.preventDefault(); + // this.$peisAPI.contextMenuForPeis() + // } + // }) + }, computed: { diff --git a/src/views/login/Login.vue b/src/views/login/Login.vue index 074ea92..bf4f4fd 100644 --- a/src/views/login/Login.vue +++ b/src/views/login/Login.vue @@ -199,11 +199,12 @@ export default { if (res.code > -1) { - window.sessionStorage.setItem("peisid", res.data.peisid); //设置当前人员所属体检中心 + window.sessionStorage.setItem("peisid", res.data.peisid); //设置当前人员所属体检中心 writetoken(res.data.expires_in); window.sessionStorage.setItem("token", res.data.access_token); window.sessionStorage.setItem("refresh_token", res.data.refresh_token); window.sessionStorage.setItem("tokentype", res.data.token_type); + window.sessionStorage.setItem("userId", res.data.userId); //当前人员ID window.sessionStorage.setItem("user", this.form.Username); this.$router.push({ path: "/home" });