提交 2bdfc289 编写于 作者: yi.li's avatar yi.li

居民详情编辑修改,选择居民的诊断检索修改

上级 81d652ec
...@@ -455,8 +455,8 @@ export const goToSearch = params => { ...@@ -455,8 +455,8 @@ export const goToSearch = params => {
export const getIcdList = params => { export const getIcdList = params => {
return fetch({ return fetch({
headers, headers,
// url: getBaseUrl(`healths/icd/list`), url: getBaseUrl(`healths/icd/list`),
url: 'http://sosoapi.yunqueyi.com/sosoapi-web/pass/mock/46/healths/icd/list', // url: 'http://sosoapi.yunqueyi.com/sosoapi-web/pass/mock/46/healths/icd/list',
method: 'get', method: 'get',
params: params, params: params,
description: '选择或搜索诊断', description: '选择或搜索诊断',
......
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item prop="diseaseId"> <el-form-item prop="diseaseId">
<el-select <!--<el-select
v-model="searchData.diseaseId" v-model="searchData.diseaseId"
multiple multiple
collapse-tags collapse-tags
...@@ -67,6 +67,24 @@ ...@@ -67,6 +67,24 @@
:key="index" :key="index"
:label="item.diseaseName" :label="item.diseaseName"
:value="item.diseaseId"> :value="item.diseaseId">
</el-option>-->
<!--</el-select>-->
<el-select
v-model="searchData.icdCodeList"
multiple
filterable
remote
reserve-keyword
placeholder="请选择或搜索诊断"
:remote-method="getDiseaseData"
:loading="loading"
class="set-width"
>
<el-option
v-for="item in icdOptions"
:key="item.icdCode"
:label="item.diseaseName"
:value="item.icdCode">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -229,7 +247,7 @@ ...@@ -229,7 +247,7 @@
<script> <script>
import { mapState, mapActions } from 'vuex' import { mapState, mapActions } from 'vuex'
import { getConstants, getPatientInfoList, getDiseasesList, getLabelList } from '@/utils/patients/patientsapi' import { getConstants, getPatientInfoList, getDiseasesList, getLabelList, getIcdList } from '@/utils/patients/patientsapi'
import { getPlanList } from '@/utils/followup/followapis' import { getPlanList } from '@/utils/followup/followapis'
export default { export default {
components: {}, components: {},
...@@ -248,7 +266,8 @@ ...@@ -248,7 +266,8 @@
diseaseId: [], diseaseId: [],
labelId: [], labelId: [],
fuPlanIdList: [], fuPlanIdList: [],
searchCondition: '' searchCondition: '',
icdCodeList: [],
}, },
paginationSet: { paginationSet: {
pageNum: 1, pageNum: 1,
...@@ -272,6 +291,8 @@ ...@@ -272,6 +291,8 @@
newSelects: [], //新选中的人 newSelects: [], //新选中的人
oldPatientList: [], oldPatientList: [],
showReloadModal: false, showReloadModal: false,
loading: false,
icdOptions: [],
getRowKeys(row) { getRowKeys(row) {
return row.patientId; return row.patientId;
}, },
...@@ -292,6 +313,8 @@ ...@@ -292,6 +313,8 @@
isShowSelectPatient(val){ isShowSelectPatient(val){
if(val){ if(val){
this.getPatientsList() this.getPatientsList()
//获取搜索诊断
this.getDiseaseData();
// 获取常量 性别、年龄 // 获取常量 性别、年龄
getConstants({ getConstants({
numList: 'P057,P006' numList: 'P057,P006'
...@@ -342,6 +365,29 @@ ...@@ -342,6 +365,29 @@
return row.disableNum return row.disableNum
} }
}, },
getDiseaseData(query) {
if (query !== '') {
let params = {
icdName: query ? query : '',
pageSize: 200,
pageNum: 1,
};
this.loading = true;
getIcdList(params).then(data => {
this.loading = false;
if(data.code == "000000") {
this.icdOptions = data.data;
}
}).catch((error) => {
this.$message({
message: error,
type: 'error'
});
});
}else {
this.icdOptions = [];
}
},
getPatientsList(){ getPatientsList(){
const data = { const data = {
pageSize: this.paginationSet.pageSize, pageSize: this.paginationSet.pageSize,
...@@ -355,6 +401,7 @@ ...@@ -355,6 +401,7 @@
addType: this.selectPatientType, //随访是1,分组是2,患教是3 addType: this.selectPatientType, //随访是1,分组是2,患教是3
fuPlanIdList: this.searchData.fuPlanIdList || [], fuPlanIdList: this.searchData.fuPlanIdList || [],
sourceId: this.sourceId, //若是随访的话,传planId;若是分组的话,传labeledId; sourceId: this.sourceId, //若是随访的话,传planId;若是分组的话,传labeledId;
icdCodeList: this.searchData.icdCodeList
} }
getPatientInfoList(data).then(res=>{ getPatientInfoList(data).then(res=>{
if(res.data.patientList){ if(res.data.patientList){
...@@ -486,7 +533,8 @@ ...@@ -486,7 +533,8 @@
diseaseId: [], diseaseId: [],
labelId: [], labelId: [],
fuPlanIdList: [], fuPlanIdList: [],
searchCondition: '' searchCondition: '',
icdCodeList: [],
} }
this.$emit('closeSelectPatient',false) this.$emit('closeSelectPatient',false)
}, },
...@@ -499,7 +547,8 @@ ...@@ -499,7 +547,8 @@
diseaseId: [], diseaseId: [],
labelId: [], labelId: [],
fuPlanIdList: [], fuPlanIdList: [],
searchCondition: '' searchCondition: '',
icdCodeList: [],
} }
this.$emit('sureSelectPatient',false,this.newSelects,this.oldPatientList) this.$emit('sureSelectPatient',false,this.newSelects,this.oldPatientList)
} else { } else {
......
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
</el-select> --> </el-select> -->
<el-button icon="el-icon-plus" @click="handleAddDiagnose">添加诊断</el-button> <el-button icon="el-icon-plus" @click="handleAddDiagnose">添加诊断</el-button>
<ul class="final-diagnose-list" v-if="selectedDiagList && selectedDiagList.length > 0"> <ul class="final-diagnose-list" v-if="selectedDiagList && selectedDiagList.length > 0">
<li v-for="diagnose in selectedDiagList" v-html="diagnose.name+'; '"></li> <li v-for="diagnose in selectedDiagList" v-html="diagnose.diseaseName+'; '"></li>
</ul> </ul>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -384,7 +384,8 @@ ...@@ -384,7 +384,8 @@
this.patientInfoForm = val; this.patientInfoForm = val;
this.baseInfoEdit = this.patientInfoForm.baseInfoEdit; this.baseInfoEdit = this.patientInfoForm.baseInfoEdit;
let customLabels = this.patientInfoForm.customLabels; let customLabels = this.patientInfoForm.customLabels;
let diseases = this.patientInfoForm.diseases; // let diseases = this.patientInfoForm.diseases;
let icdList = this.patientInfoForm.icdList;
if(customLabels && customLabels.length > 0){ if(customLabels && customLabels.length > 0){
customLabels.forEach((kkk)=>{ customLabels.forEach((kkk)=>{
this.labelIdList.push(Number(kkk.labelId)) this.labelIdList.push(Number(kkk.labelId))
...@@ -392,12 +393,17 @@ ...@@ -392,12 +393,17 @@
}else { }else {
this.labelIdList = []; this.labelIdList = [];
} }
if(diseases && diseases.length > 0) { // if(diseases && diseases.length > 0) {
diseases.forEach((dis)=>{ // diseases.forEach((dis)=>{
this.diseaseIdList.push(Number(dis.diseaseId)) // this.diseaseIdList.push(Number(dis.diseaseId))
}) // })
// }else {
// this.diseaseIdList = [];
// }
if(icdList && icdList.length > 0) {
this.$store.dispatch('patientsDiagnose/changeDiagnoseList', icdList)
}else { }else {
this.diseaseIdList = []; this.$store.dispatch('patientsDiagnose/changeDiagnoseList', [])
} }
if(this.patientInfoForm.idNo) { if(this.patientInfoForm.idNo) {
this.hasIdNo = true; this.hasIdNo = true;
...@@ -487,7 +493,8 @@ ...@@ -487,7 +493,8 @@
cityId: null, cityId: null,
countyId: null, countyId: null,
townId: null, townId: null,
} };
this.$store.dispatch('patientsDiagnose/changeDiagnoseList', [])
}, },
// 点击 添加诊断 // 点击 添加诊断
handleAddDiagnose() { handleAddDiagnose() {
......
...@@ -185,7 +185,8 @@ ...@@ -185,7 +185,8 @@
if(this.patientInfo){ if(this.patientInfo){
this.doctorId = this.patientInfo.doctorId; this.doctorId = this.patientInfo.doctorId;
let customLabels = this.patientInfo.customLabels; let customLabels = this.patientInfo.customLabels;
let diseases = this.patientInfo.diseases; // let diseases = this.patientInfo.diseases;
let icdList = this.patientInfo.icdList;
let groupLabelNames = []; let groupLabelNames = [];
let groupDiseaseNames = []; let groupDiseaseNames = [];
//对出生日期的处理 //对出生日期的处理
...@@ -206,9 +207,18 @@ ...@@ -206,9 +207,18 @@
} else { } else {
this.showLabelName = ''; this.showLabelName = '';
} }
// 对诊断疾病的处理 // 对诊断疾病的处理(老版诊断)
if(diseases) { // if(diseases) {
diseases.forEach(item => { // diseases.forEach(item => {
// groupDiseaseNames.push(item.diseaseName)
// });
// this.showDiseaseName = groupDiseaseNames.join(';');
// } else {
// this.showDiseaseName = '';
// }
// 对诊断疾病的处理(新版诊断)
if(icdList) {
icdList.forEach(item => {
groupDiseaseNames.push(item.diseaseName) groupDiseaseNames.push(item.diseaseName)
}); });
this.showDiseaseName = groupDiseaseNames.join(';'); this.showDiseaseName = groupDiseaseNames.join(';');
......
...@@ -49,11 +49,12 @@ ...@@ -49,11 +49,12 @@
placeholder="请选择或搜索诊断" placeholder="请选择或搜索诊断"
:remote-method="getDiseaseData" :remote-method="getDiseaseData"
:loading="loading" :loading="loading"
size="small"
> >
<el-option <el-option
v-for="item in options" v-for="item in options"
:key="item.icdCode" :key="item.icdCode"
:label="item.icdName" :label="item.diseaseName"
:value="item.icdCode"> :value="item.icdCode">
</el-option> </el-option>
</el-select> </el-select>
...@@ -225,14 +226,14 @@ ...@@ -225,14 +226,14 @@
if (query !== '') { if (query !== '') {
let params = { let params = {
icdName: query ? query : '', icdName: query ? query : '',
pageSize: 1, pageSize: 200,
pageNum: 200, pageNum: 1,
}; };
this.loading = true; this.loading = true;
getIcdList(params).then(data => { getIcdList(params).then(data => {
this.loading = false; this.loading = false;
if(data.code == "000000") { if(data.code == "000000") {
this.options = data.data.icdList; this.options = data.data;
} }
}).catch((error) => { }).catch((error) => {
this.$message({ this.$message({
...@@ -306,7 +307,7 @@ ...@@ -306,7 +307,7 @@
//转化疾病 //转化疾病
if (item.patientTypeModels) { if (item.patientTypeModels) {
item.patientTypeModels.forEach(item => { item.patientTypeModels.forEach(item => {
diseaseNames.push(item.name) diseaseNames.push(item.diseaseName)
}) })
item.showDiseaseNames = diseaseNames.join('、'); item.showDiseaseNames = diseaseNames.join('、');
} else { } else {
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册