diff --git a/src/views/components/addResi.vue b/src/views/components/addResi.vue index 3ca535131..6864b6f30 100644 --- a/src/views/components/addResi.vue +++ b/src/views/components/addResi.vue @@ -577,12 +577,12 @@ export default { ] }, { - id: 'deathDto', + id: 'baseInfoDto', children: [ { label: "死亡时间", itemType: "datepicker1", - formName: "deathTime", + formName: "deathDate", check:'fourFont' }, ] @@ -1346,6 +1346,11 @@ export default { this.form.baseInfoDto.categoryInfo.partyFlag = 2; } if (index != 3 && index) { + if(value === 'deathFlag'){ + this.form.baseInfoDto.deathFlag = event?1:0 + }else{ + this.form.baseInfoDto.categoryInfo[value] = event ? 1 : 0; + } this.form.baseInfoDto.categoryInfo[value] = event ? 1 : 0; } else if (index == 3) { if (event) { @@ -1366,7 +1371,7 @@ export default { 'disabilityFlag': { formId: 'healthDto', formType: 'healthDto', title: '残疾信息' }, 'seriousIllnessFlag': { formId: 'seriousIllnessDto', formType: 'seriousIllnessDto', title: '大病信息' }, 'chronicDiseaseFlag': { formId: 'chronicDiseaseDto', formType: 'chronicDiseaseDto', title: '慢病信息' }, - 'deathFlag': { formId: 'deathDto', formType: 'deathDto', title: '死亡' }, + 'deathFlag': { formId: 'baseInfoDto', formType: 'baseInfoDto', title: '死亡' }, 'oldPeopleFlag': { formId: 'oldPeopleDto', formType: 'oldPeopleDto', title: '老年人信息' }, 'subsistenceAllowanceFlag': { formId: 'subsistenceAllowanceDto', formType: 'subsistenceAllowanceDto', title: '低保人员信息' }, 'veteranFlag': { formId: 'veteranDto', formType: 'veteranDto', title: '退役军人信息' }, diff --git a/src/views/components/editResi.vue b/src/views/components/editResi.vue index 87a03b93a..cbee5dd61 100644 --- a/src/views/components/editResi.vue +++ b/src/views/components/editResi.vue @@ -889,7 +889,9 @@ export default { nation: null, //民族 localResidenceFlag: 0, //是否本地户籍 nativePlace: null, //籍贯, - remark: null, //备注 + remark: null, //备注, + deathFlag:0,//死亡 + deathDate:null,//死亡日期 categoryInfo: { partyFlag: 0, subsistenceAllowanceFlag: 0, @@ -1092,14 +1094,14 @@ export default { ], }, { - id: "deathDto", + id: "baseInfoDto", children: [ { label: "死亡时间", itemType: "datepicker1", - formName: "deathTime", + formName: "deathDate", check:'fourFont', - pformName: "deathDto", + pformName: "baseInfoDto", }, ], }, @@ -1514,7 +1516,7 @@ export default { formType: "chronicDiseaseDto", title: "慢病信息", }, - deathFlag: { formId: "deathDto", formType: "deathDto", title: "死亡" }, + deathFlag: { formId: "baseInfoDto", formType: "baseInfoDto", title: "死亡信息" }, oldPeopleFlag: { formId: "oldPeopleDto", formType: "oldPeopleDto", @@ -2172,7 +2174,11 @@ export default { this.form.baseInfoDto.categoryInfo.partyFlag = 2; } if (index != 3 && index) { - this.form.baseInfoDto.categoryInfo[value] = event ? 1 : 0; + if(value === 'deathFlag'){ + this.form.baseInfoDto.deathFlag = event?1:0 + }else{ + this.form.baseInfoDto.categoryInfo[value] = event ? 1 : 0; + } } else if (index == 3) { if (event) { @@ -2193,7 +2199,7 @@ export default { 'disabilityFlag': { formId: 'healthDto', formType: 'healthDto', title: '残疾信息' }, 'seriousIllnessFlag': { formId: 'seriousIllnessDto', formType: 'seriousIllnessDto', title: '大病信息' }, 'chronicDiseaseFlag': { formId: 'chronicDiseaseDto', formType: 'chronicDiseaseDto', title: '慢病信息' }, - 'deathFlag': { formId: 'deathDto', formType: 'deathDto', title: '死亡' }, + 'deathFlag': { formId: 'baseInfoDto', formType: 'baseInfoDto', title: '死亡' }, 'oldPeopleFlag': { formId: 'oldPeopleDto', formType: 'oldPeopleDto', title: '老年人信息' }, 'subsistenceAllowanceFlag': { formId: 'subsistenceAllowanceDto', formType: 'subsistenceAllowanceDto', title: '低保人员信息' }, 'veteranFlag': { formId: 'veteranDto', formType: 'veteranDto', title: '退役军人信息' }, @@ -2226,15 +2232,29 @@ export default { }); } }); - delete this.form[this.incidence[value].formType]; + if(value === 'deathFlag'){ + this.form.baseInfoDto.deathFlag = 0; + this.form.baseInfoDto.deathDate = null; + }else{ + delete this.form[this.incidence[value].formType]; + } } }, submitExpandAdd(form, formType) { - this.form[formType] = form[formType]; + if(formType === 'baseInfoDto' ){ + this.form.baseInfoDto.deathDate = form[formType].deathDate; + this.form.baseInfoDto.deathFlag = 1; + }else{ + this.form[formType] = form[formType]; + } this.dialogVisible = false; }, hideExpand(formType) { - delete this.form[formType]; + if(formType!= 'baseInfoDto'){ + delete this.form[formType]; + }else{ + this.form['baseInfoDto'].deathFlag = 0; + } this.dialogVisible = false; }, // 提交扩展信息 diff --git a/src/views/components/resiExpand/editExpand.vue b/src/views/components/resiExpand/editExpand.vue index 7a0b2bfcb..a9e705273 100644 --- a/src/views/components/resiExpand/editExpand.vue +++ b/src/views/components/resiExpand/editExpand.vue @@ -182,6 +182,10 @@ export default { volunteerDto: { volunteerCategory: [] }, + // 死亡时间 + baseInfoDto:{ + deathDate:null + } }, casProps: { value: 'id', @@ -227,7 +231,8 @@ export default { }, showForm() { this.$nextTick(() => { - // console.log(this.form,'拓展组件form'); + console.log(this.form,'拓展组件form'); + console.log(this.formList,'拓展组件formList'); const promises = this.formList.forEach((item) => { item.form.map(async (group) => { return group.children.reduce(async (accPromise, item) => { diff --git a/src/views/components/resiExpand/index.vue b/src/views/components/resiExpand/index.vue index 49d949c54..0b401c6d7 100644 --- a/src/views/components/resiExpand/index.vue +++ b/src/views/components/resiExpand/index.vue @@ -121,10 +121,6 @@ export default { chronicDiseaseDto: { chronicDiseaseCodes: [] }, - // 死亡信息 - deathDto: { - deathTime: null - }, // 老年人 oldPeopleDto: { oldPeopleCategories:[], @@ -170,7 +166,9 @@ export default { volunteerDto: { volunteerCategory: [] }, - + baseInfoDto:{ + deathDate:null + } }, casProps: { value: 'id', @@ -249,8 +247,6 @@ export default { console.error('Error fetching options:', error); }); this.getOrgTree() - console.log(this.form, '子组件form'); - console.log(this.formList, '子组件formList'); }) }, async getDictDataForm(url, params) { @@ -278,7 +274,7 @@ export default { if (this.formType === 'add') { this.form.id = this.form.partyOrgId; } - // this.$emit('submitExpand', this.form, this.formType) + this.$emit('submitExpand', this.form, this.formType) }, handlePartyOrgCascadarChange(selectedNode) { this.form.parymemberInfoDto.partyOrgId = selectedNode[selectedNode.length - 1]; diff --git a/src/views/components/resiSearch.vue b/src/views/components/resiSearch.vue index 5a3cc6f04..713380788 100644 --- a/src/views/components/resiSearch.vue +++ b/src/views/components/resiSearch.vue @@ -290,6 +290,16 @@ export default { "label": "失智老人", "value": "DEMENTED_FLAG", "children": null + }, + { + "label": "独居老人", + "value": "LIVE_ALONE_FLAG", + "children": null + }, + { + "label": "普通老年人", + "value": "OLD_PEOPLE_FLAG", + "children": null }, ] }, diff --git a/src/views/modules/portrayal/jumin/cpts/staffTag.vue b/src/views/modules/portrayal/jumin/cpts/staffTag.vue index f8bba504c..b82c7eb7e 100644 --- a/src/views/modules/portrayal/jumin/cpts/staffTag.vue +++ b/src/views/modules/portrayal/jumin/cpts/staffTag.vue @@ -169,8 +169,17 @@ export default { const updateValue = (flag, dataIndex) => { const { tableData } = this.formData; const valueArray = tableData[dataIndex].value; + if(flag === 'deathFlag'){ + if(this.userInfo.baseInfoDto.deathFlag !== 1){ + this.formData.tableData[dataIndex].value = valueArray.filter(item => item !== flag); + }else{ + valueArray.push(flag) + } + console.log(valueArray,'seee'); + return + } if (this.userInfo.baseInfoDto.categoryInfo[flag] === 1) { - valueArray.push(flag); + valueArray.push(flag,'seeee'); } else { this.formData.tableData[dataIndex].value = valueArray.filter(item => item !== flag); } @@ -181,7 +190,6 @@ export default { this.formData.tableData[0].value = this.userInfo.baseInfoDto.categoryInfo.partyFlag; //添加回填需要在这里加上key与对应的index(在formData.tableData中对应的下标) updateValue('disabilityFlag', 1); - updateValue('deathFlag', 1); updateValue('seriousIllnessFlag', 1); updateValue('chronicDiseaseFlag', 1); updateValue('emptyNesterFlag', 2); @@ -197,6 +205,7 @@ export default { updateValue('buildingChiefFlag', 4); updateValue('unitChiefFlag', 4); updateValue('publicWelfareFlag', 4); + updateValue('deathFlag', 1); }, handeleClickRadio(val) { if (val === 1) { diff --git a/src/views/modules/portrayal/jumin/index.vue b/src/views/modules/portrayal/jumin/index.vue index 133ec9172..4ff177c54 100644 --- a/src/views/modules/portrayal/jumin/index.vue +++ b/src/views/modules/portrayal/jumin/index.vue @@ -26,7 +26,7 @@ > {{ item.name }} { console.log(err);