Browse Source

sumseo

master
pengjun 2 years ago
parent
commit
e9396b8507
  1. 33
      src/components/doctorCheck/PatientRegisterBase.vue
  2. 146
      src/components/sumDoctorCheck/SumSug.vue

33
src/components/doctorCheck/PatientRegisterBase.vue

@ -160,6 +160,7 @@ export default {
this.dataTransOpts.refresh.register_check.M++ this.dataTransOpts.refresh.register_check.M++
// //
// console.log('afterFind',rd)
this.dataTransOpts.refresh.sumDoctor.M++ this.dataTransOpts.refresh.sumDoctor.M++
// this.dataTransOpts.refresh.sum_diagnosis.M++ // this.dataTransOpts.refresh.sum_diagnosis.M++
@ -181,13 +182,12 @@ export default {
postapi('/api/app/patientregister/GetAlreadyRegisterPatientRegisterByNo', body) postapi('/api/app/patientregister/GetAlreadyRegisterPatientRegisterByNo', body)
.then((res) => { .then((res) => {
if (res.code > -1) { if (res.code > -1) {
this.dataTransOpts.tableS.patient_register = deepCopy(res.data)
console.log('res.data',res.data)
console.log('this.dataTransOpts.tableS.patient_register',this.dataTransOpts.tableS.patient_register)
this.dataTransOpts.tableS.patient_register = res.data
// console.log('res.data',res.data)
// console.log('this.dataTransOpts.tableS.patient_register',this.dataTransOpts.tableS.patient_register)
} }
})
.finally(() => {
this.afterFind(this.dataTransOpts.tableS.patient_register) this.afterFind(this.dataTransOpts.tableS.patient_register)
}); });
}, },
@ -203,11 +203,11 @@ export default {
this.dataTransOpts.tableS.patient_register = { id: '', patientNo } this.dataTransOpts.tableS.patient_register = { id: '', patientNo }
postapi('/api/app/patientregister/GetAlreadyRegisterPatientRegisterByNo', body) postapi('/api/app/patientregister/GetAlreadyRegisterPatientRegisterByNo', body)
.then((res) => { .then((res) => {
if (res.code != -1) {
if (res.data) this.dataTransOpts.tableS.patient_register = deepCopy(res.data)
if (res.code > -1) {
this.dataTransOpts.tableS.patient_register = res.data
} }
}) })
.finally(() => {
.finally(() =>{
this.afterFind(this.dataTransOpts.tableS.patient_register) this.afterFind(this.dataTransOpts.tableS.patient_register)
}); });
}, },
@ -223,13 +223,14 @@ export default {
// //
postapi('/api/app/patientregister/getlistinfilter', body) postapi('/api/app/patientregister/getlistinfilter', body)
.then(res => { .then(res => {
if (res.code != -1) {
if (res.code > -1) {
if (res.data.items.length == 1) { if (res.data.items.length == 1) {
this.dataTransOpts.tableS.patient_register = res.data.items[0] this.dataTransOpts.tableS.patient_register = res.data.items[0]
// this.dataTransOpts.tableS.patient_register.id = res.data.items[0].id // this.dataTransOpts.tableS.patient_register.id = res.data.items[0].id
// this.dataTransOpts.tableS.patient_register.patientRegisterNo = res.data.items[0].patientRegisterNo // this.dataTransOpts.tableS.patient_register.patientRegisterNo = res.data.items[0].patientRegisterNo
this.dataTransOpts.refresh.patient_register.S++ this.dataTransOpts.refresh.patient_register.S++
// this.getPatientRegister(res.data.items[0].id) // this.getPatientRegister(res.data.items[0].id)
} else if (res.data.items.length > 1) { } else if (res.data.items.length > 1) {
this.PatientRegisterList = res.data.items this.PatientRegisterList = res.data.items
this.dialogWin.PatientRegisterForChoose = true // this.dialogWin.PatientRegisterForChoose = true //
@ -239,6 +240,7 @@ export default {
} }
} }
}) })
// setTimeout(() => { // setTimeout(() => {
// // // //
// this.dataTransOpts.refresh.register_check.M++ // this.dataTransOpts.refresh.register_check.M++
@ -251,22 +253,19 @@ export default {
//patientRegisterNo //patientRegisterNo
getPatientRegister(patientRegisterNo) { getPatientRegister(patientRegisterNo) {
if (!patientRegisterNo) {
this.afterFind({ id: '', patientRegisterNo: '' })
return
}
// this.afterFind({ id: '', patientRegisterNo: '' })
if (!patientRegisterNo) return
let body = { patientRegisterNo } let body = { patientRegisterNo }
postapi('/api/app/patientregister/GetAlreadyRegisterPatientRegisterByNo', body) postapi('/api/app/patientregister/GetAlreadyRegisterPatientRegisterByNo', body)
.then((res) => { .then((res) => {
if (res.code != -1) {
if (res.data) this.dataTransOpts.tableS.patient_register = deepCopy(res.data)
if (res.code > -1) {
this.dataTransOpts.tableS.patient_register = res.data
} }
}) })
.finally(() => {
.finally(() =>{
this.afterFind(this.dataTransOpts.tableS.patient_register) this.afterFind(this.dataTransOpts.tableS.patient_register)
}); });
}, },

146
src/components/sumDoctorCheck/SumSug.vue

@ -5,7 +5,7 @@
<div style="width:50%;"> <div style="width:50%;">
<el-table id="tableSummary" row-key="id" :data="sumDoctorCheck.summaryList" width="100%" :height="sumHeight" <el-table id="tableSummary" row-key="id" :data="sumDoctorCheck.summaryList" width="100%" :height="sumHeight"
border size="small"> border size="small">
<el-table-column type="index" width="20" align="center" />
<el-table-column type="index" width="30" align="center" />
<el-table-column prop="summaryTitle" label="综述"> <el-table-column prop="summaryTitle" label="综述">
<template slot-scope="scope"> <template slot-scope="scope">
<div> <div>
@ -47,7 +47,7 @@
<div style="width:50%;"> <div style="width:50%;">
<el-table id="tableSuggestion" row-key="id" :data="sumDoctorCheck.suggestionList" width="100%" :height="sumHeight" <el-table id="tableSuggestion" row-key="id" :data="sumDoctorCheck.suggestionList" width="100%" :height="sumHeight"
border size="small" ref="tableSuggestion"> border size="small" ref="tableSuggestion">
<el-table-column type="index" width="20" align="center">
<el-table-column type="index" width="30" align="center">
</el-table-column> </el-table-column>
<el-table-column prop="suggestionTitle" label="建议"> <el-table-column prop="suggestionTitle" label="建议">
<template slot="header"> <template slot="header">
@ -72,17 +72,17 @@
</div> </div>
<div v-show="!scope.row.collapse"> <div v-show="!scope.row.collapse">
<div style="display: flex;margin-top: 2px;"> <div style="display: flex;margin-top: 2px;">
<div style="width:60px;">诊断</div>
<div style="width:60px;">诊断</div>
<el-input placeholder="请选择单位" :value="`${scope.row.diagnosisNames}`" size="small" disabled>
<el-button slot="append" icon="el-icon-search" @click="btnChooseDiagnosis(scope.$index)"
style="font-size: 20px;" :disabled="sumBtnDisabled()"></el-button>
</el-input>
<!--
<el-select v-model="scope.row.diagnosisIds" multiple placeholder="请选择" style="width: 100%;" <el-select v-model="scope.row.diagnosisIds" multiple placeholder="请选择" style="width: 100%;"
:disabled="sumBtnDisabled()" @change="changeDiagnosis" filterable class="no-animation"> :disabled="sumBtnDisabled()" @change="changeDiagnosis" filterable class="no-animation">
<el-option v-for="item in diagnosises" :key="item.id" :value="item.id" :label="item.displayName" <el-option v-for="item in diagnosises" :key="item.id" :value="item.id" :label="item.displayName"
:disabled="disabledDiagnosis(item.id, scope.$index)" /> :disabled="disabledDiagnosis(item.id, scope.$index)" />
</el-select> </el-select>
<!--
<select v-model="scope.row.diagnosisIds" placeholder="请选择" style="width: 100%;" multiple :disabled="sumBtnDisabled()" @change="changeDiagnosis">
<el-option v-for="item in diagnosises" :key="item.id" :value="item.id" :label="item.displayName"
:disabled="disabledDiagnosis(item.id, scope.$index)" />
</select>
--> -->
</div> </div>
<div style="display: flex;margin-top: 2px;"> <div style="display: flex;margin-top: 2px;">
@ -202,20 +202,33 @@
<div style="overflow-y:auto; width:100%;display: flex;flex-wrap: wrap;align-content: flex-start;"> <div style="overflow-y:auto; width:100%;display: flex;flex-wrap: wrap;align-content: flex-start;">
<div v-for="item in symbols" :key="item.id" style="margin: 1px; 2px;cursor:pointer;" <div v-for="item in symbols" :key="item.id" style="margin: 1px; 2px;cursor:pointer;"
@click="insertSymbols(item.displayName)"> @click="insertSymbols(item.displayName)">
<el-tag style="padding: 0 3px;height: 24px;line-height: 24px;font-size: 15px;">
<el-tag style="padding: 0 3px;height: 24px;line-height: 24px;font-size: 15px;color: #303133;background-color: white;">
{{ item.displayName }} {{ item.displayName }}
</el-tag> </el-tag>
</div> </div>
</div> </div>
<div style="padding: 5px 0;">录入结果</div> <div style="padding: 5px 0;">录入结果</div>
<el-input id="resultBox" style="width: 100%;" type="textarea" :autosize="{ minRows: 4, maxRows: 4 }"
<el-input id="resultBox" class="commonFont" style="width: 100%;" type="textarea" :autosize="{ minRows: 4, maxRows: 4 }"
v-model="curResult" /> v-model="curResult" />
</div> </div>
<span slot="footer" class="dialog-footer"> <span slot="footer" class="dialog-footer">
<el-button type="primary" @click="btnOkResult"> </el-button>
<el-button type="primary" @click="btnOkResult">确定</el-button>
<el-button @click="dialogWinSymbols = false">关闭</el-button> <el-button @click="dialogWinSymbols = false">关闭</el-button>
</span> </span>
</el-dialog> </el-dialog>
<el-dialog title="选择诊断" :visible.sync="dialogDiagnosises" width="800px" :close-on-click-modal="false">
<div style="height: 320px;">
<el-select v-model="choosedDiagnosisIds" multiple placeholder="请选择" style="width: 100%;"
@change="changeDiagnosis" filterable class="no-animation">
<el-option v-for="item in diagnosisesFilter" :key="item.id" :value="item.id" :label="item.displayName" />
</el-select>
</div>
<span slot="footer" class="dialog-footer">
<el-button type="primary" @click="btnOkDiagnosis">确定</el-button>
<el-button @click="dialogDiagnosises = false">关闭</el-button>
</span>
</el-dialog>
</div> </div>
</div> </div>
</template> </template>
@ -226,7 +239,7 @@ import { getapi, postapi, putapi, deletapi } from "@/api/api";
import { getPagePriv, checkPagePriv, deepCopy, arrayExistObj } from '../../utlis/proFunc'; import { getPagePriv, checkPagePriv, deepCopy, arrayExistObj } from '../../utlis/proFunc';
export default { export default {
components: {}, components: {},
props: ["patientRegisterId","tabChoosed"],
props: ["patientRegisterId", "tabChoosed"],
data() { data() {
return { return {
pagePriv: { pagePriv: {
@ -235,7 +248,10 @@ export default {
}, },
sumDetails: [], sumDetails: [],
suggestionCurRow: 0, // suggestionCurRow: 0, //
dialogDiagnosises: false, //
diagnosises: [], // diagnosises: [], //
diagnosisesFilter: [], //
choosedDiagnosisIds: [], //
collapse: false, // / collapse: false, // /
dialogWinSymbols: false, dialogWinSymbols: false,
@ -257,6 +273,7 @@ export default {
// //
let userPriv = window.sessionStorage.getItem('userPriv') let userPriv = window.sessionStorage.getItem('userPriv')
if (userPriv) this.pagePriv.privs = deepCopy(getPagePriv(this.pagePriv.routeUrlorPageName)) if (userPriv) this.pagePriv.privs = deepCopy(getPagePriv(this.pagePriv.routeUrlorPageName))
}, },
// //
@ -369,12 +386,36 @@ export default {
}) })
}, },
//
btnChooseDiagnosis(index) {
this.suggestionCurRow = index
this.choosedDiagnosisIds = this.sumDoctorCheck.suggestionList[index].diagnosisIds
let diagnosisIds = []
this.sumDoctorCheck.suggestionList.forEach((e, i) => {
if (i != index) {
if (e.diagnosisIds) diagnosisIds = diagnosisIds.concat(e.diagnosisIds)
}
});
this.diagnosisesFilter = this.diagnosises.filter(e => {
return diagnosisIds.indexOf(e.id) == -1
})
this.dialogDiagnosises = true
},
btnOkDiagnosis() {
this.changeDiagnosis(this.choosedDiagnosisIds)
this.dialogDiagnosises = false
},
// //
getHaveSumData(patientRegisterId) { getHaveSumData(patientRegisterId) {
this.sumDoctorCheck.summaryList = []; this.sumDoctorCheck.summaryList = [];
this.sumDoctorCheck.suggestionList = []; this.sumDoctorCheck.suggestionList = [];
if (!patientRegisterId) return if (!patientRegisterId) return
// console.log('getHaveSumData', this.dataTransOpts.tableS.patient_register.completeFlag)
if (this.dataTransOpts.tableS.patient_register.completeFlag == '3') { if (this.dataTransOpts.tableS.patient_register.completeFlag == '3') {
this.summaryList(patientRegisterId, 'Y') this.summaryList(patientRegisterId, 'Y')
this.suggestionList(patientRegisterId, 'Y') this.suggestionList(patientRegisterId, 'Y')
@ -403,9 +444,6 @@ export default {
}) })
}, },
// //
summaryList(RegisterId, isGetExistData) { summaryList(RegisterId, isGetExistData) {
if (!RegisterId) { if (!RegisterId) {
@ -465,6 +503,7 @@ export default {
isGetExistData, isGetExistData,
} }
// console.log(`/api/app/sumsuggestionheader/getsumsuggestionlist?PatientRegisterId=${RegisterId}`) // console.log(`/api/app/sumsuggestionheader/getsumsuggestionlist?PatientRegisterId=${RegisterId}`)
postapi('/api/app/sumsuggestionheader/getsumsuggestionlist', body) postapi('/api/app/sumsuggestionheader/getsumsuggestionlist', body)
.then((res) => { .then((res) => {
console.log("suggestionList", res.data); console.log("suggestionList", res.data);
@ -492,12 +531,10 @@ export default {
}); });
} }
}); });
this.sumDoctorCheck.suggestionList = res.data;
this.sumDoctorCheck.suggestionList = res.data;
} }
})
.catch((err) => {
this.$message({ type: "error", message: `操作失败,原因:${err}` });
}); });
}, },
// //
@ -517,37 +554,25 @@ export default {
return ret return ret
}, },
//
disabledDiagnosis(diagnosisId, index) {
let ret = false
let diagnosisIds = []
this.sumDoctorCheck.suggestionList.forEach((e, i) => {
if (i != index) {
if (e.diagnosisIds) diagnosisIds = diagnosisIds.concat(e.diagnosisIds)
}
});
if (diagnosisIds.indexOf(diagnosisId) > -1) ret = true
return ret
},
// //
changeDiagnosis(v) { changeDiagnosis(v) {
console.log('changeDiagnosis', v)
// console.log('changeDiagnosis', v)
let suggestionTitle = [] let suggestionTitle = []
if (v.length == 0) { if (v.length == 0) {
this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['suggestionTitle'] = '' this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['suggestionTitle'] = ''
return return
} }
// //
let lv = `${v}`
let suggestionList = deepCopy(this.sumDoctorCheck.suggestionList)
suggestionList.forEach(e => {
e.diagnosisIds = `${e.diagnosisIds}`
});
let lfind = arrayExistObj(suggestionList, 'diagnosisIds', lv)
if (lfind == -1) return
this.suggestionCurRow = lfind
let sumSuggestionHeaderId = this.sumDoctorCheck.suggestionList[lfind].id
// let lv = `${v}`
// let suggestionList = deepCopy(this.sumDoctorCheck.suggestionList)
// suggestionList.forEach(e => {
// e.diagnosisIds = `${e.diagnosisIds}`
// });
// let lfind = arrayExistObj(suggestionList, 'diagnosisIds', lv)
// if (lfind == -1) return
// this.suggestionCurRow = lfind
let sumSuggestionHeaderId = this.sumDoctorCheck.suggestionList[this.suggestionCurRow].id
v.forEach(e => { v.forEach(e => {
let ld = arrayExistObj(this.diagnosises, 'id', e) let ld = arrayExistObj(this.diagnosises, 'id', e)
if (ld > -1) { if (ld > -1) {
@ -555,11 +580,13 @@ export default {
// //
let medicalInterpretations = this.diagnosises[ld]['medicalInterpretations'] let medicalInterpretations = this.diagnosises[ld]['medicalInterpretations']
if (medicalInterpretations) { if (medicalInterpretations) {
if (!this.sumDoctorCheck.suggestionList[lfind]['medicalInterpretations']) this.sumDoctorCheck.suggestionList[lfind]['medicalInterpretations'] = []
if (!this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['medicalInterpretations']) {
this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['medicalInterpretations'] = []
}
medicalInterpretations.forEach(e2 => { medicalInterpretations.forEach(e2 => {
let lf = arrayExistObj(this.sumDoctorCheck.suggestionList[lfind]['medicalInterpretations'], "suggestionContent", e2.suggestionContent)
let lf = arrayExistObj(this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['medicalInterpretations'], "suggestionContent", e2.suggestionContent)
if (lf == -1) { if (lf == -1) {
this.sumDoctorCheck.suggestionList[lfind]['medicalInterpretations'].push({
this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['medicalInterpretations'].push({
sumSuggestionHeaderId, sumSuggestionHeaderId,
suggestionContent: e2.suggestionContent, suggestionContent: e2.suggestionContent,
displayOrder: Math.random(), displayOrder: Math.random(),
@ -571,11 +598,13 @@ export default {
// //
let commonReasons = this.diagnosises[ld]['commonReasons'] let commonReasons = this.diagnosises[ld]['commonReasons']
if (commonReasons) { if (commonReasons) {
if (!this.sumDoctorCheck.suggestionList[lfind]['commonReasons']) this.sumDoctorCheck.suggestionList[lfind]['commonReasons'] = []
if (!this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['commonReasons']) {
this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['commonReasons'] = []
}
commonReasons.forEach(e2 => { commonReasons.forEach(e2 => {
let lf = arrayExistObj(this.sumDoctorCheck.suggestionList[lfind]['commonReasons'], "suggestionContent", e2.suggestionContent)
let lf = arrayExistObj(this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['commonReasons'], "suggestionContent", e2.suggestionContent)
if (lf == -1) { if (lf == -1) {
this.sumDoctorCheck.suggestionList[lfind]['commonReasons'].push({
this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['commonReasons'].push({
sumSuggestionHeaderId, sumSuggestionHeaderId,
suggestionContent: e2.suggestionContent, suggestionContent: e2.suggestionContent,
displayOrder: Math.random(), displayOrder: Math.random(),
@ -587,11 +616,13 @@ export default {
// //
let healthGuidances = this.diagnosises[ld]['healthGuidances'] let healthGuidances = this.diagnosises[ld]['healthGuidances']
if (healthGuidances) { if (healthGuidances) {
if (!this.sumDoctorCheck.suggestionList[lfind]['healthGuidances']) this.sumDoctorCheck.suggestionList[lfind]['healthGuidances'] = []
if (!this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['healthGuidances']) {
this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['healthGuidances'] = []
}
healthGuidances.forEach(e2 => { healthGuidances.forEach(e2 => {
let lf = arrayExistObj(this.sumDoctorCheck.suggestionList[lfind]['healthGuidances'], "suggestionContent", e2.suggestionContent)
let lf = arrayExistObj(this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['healthGuidances'], "suggestionContent", e2.suggestionContent)
if (lf == -1) { if (lf == -1) {
this.sumDoctorCheck.suggestionList[lfind]['healthGuidances'].push({
this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['healthGuidances'].push({
sumSuggestionHeaderId, sumSuggestionHeaderId,
suggestionContent: e2.suggestionContent, suggestionContent: e2.suggestionContent,
displayOrder: Math.random(), displayOrder: Math.random(),
@ -601,7 +632,9 @@ export default {
} }
} }
}); });
this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['diagnosisIds'] = v
this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['suggestionTitle'] = `${suggestionTitle}` this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['suggestionTitle'] = `${suggestionTitle}`
this.sumDoctorCheck.suggestionList[this.suggestionCurRow]['diagnosisNames'] = `${suggestionTitle}`
this.$nextTick(() => { this.$nextTick(() => {
this.$refs['tableSuggestion'].doLayout() this.$refs['tableSuggestion'].doLayout()
}) })
@ -878,7 +911,7 @@ export default {
// immediate:true, // immediate:true,
handler(newVal, oldVal) { handler(newVal, oldVal) {
console.log(`watch 总检--综述建议 newVal: ${newVal}, oldVal: ${oldVal} patientRegisterId: ${this.dataTransOpts.tableS.patient_register.id}`); console.log(`watch 总检--综述建议 newVal: ${newVal}, oldVal: ${oldVal} patientRegisterId: ${this.dataTransOpts.tableS.patient_register.id}`);
if(newVal != oldVal && this.tabChoosed == '1') this.getHaveSumData(this.dataTransOpts.tableS.patient_register.id)
if (newVal != oldVal && this.tabChoosed == '1') this.getHaveSumData(this.dataTransOpts.tableS.patient_register.id)
} }
}, },
}, },
@ -887,13 +920,17 @@ export default {
<style scoped> <style scoped>
@import '../../assets/css/global_table.css'; @import '../../assets/css/global_table.css';
::v-deep .el-icon-search:before {
color: #00F;
}
.no-animation { .no-animation {
animation: none !important; animation: none !important;
-webkit-animation: none !important; -webkit-animation: none !important;
} }
::v-deep .el-select { ::v-deep .el-select {
&.el-select-dropdown {
&.el-select-dropdown {
animation: none !important; animation: none !important;
-webkit-animation: none !important; -webkit-animation: none !important;
} }
@ -933,5 +970,8 @@ export default {
height: 23px; height: 23px;
padding: 1px 15px 1px 2px; padding: 1px 15px 1px 2px;
} }
::v-deep .commonFont .el-textarea__inner{
font-family: "Microsoft YaHei";
}
</style> </style>
Loading…
Cancel
Save