Browse Source

bugs

feature
mk 2 years ago
parent
commit
9bbd5ab590
  1. 4
      src/js/dai/request.js
  2. 190
      src/views/components/resiForm.vue
  3. 3
      src/views/components/resiSearch.vue
  4. 44
      src/views/modules/base/resi.vue
  5. 2
      src/views/modules/communityParty/regionalParty/units.vue
  6. 2
      src/views/modules/shequzhili/xiangmu/cpts/project-info.vue

4
src/js/dai/request.js

@ -41,7 +41,7 @@ const request = curry(
if (res.data.code > 8000 && res.data.code < 10000) { if (res.data.code > 8000 && res.data.code < 10000) {
message({ message({
message: res.data.msg || "未知错误", message: res.data.msg,
type: 'error', type: 'error',
duration: 2 * 1000 duration: 2 * 1000
}) })
@ -68,7 +68,7 @@ const request = curry(
reslove( reslove(
Object.assign({}, returnIniData, { Object.assign({}, returnIniData, {
httpCode: "9999", //访问出现意外 httpCode: "9999", //访问出现意外
msg:err, msg:"网络错误",
}) })
); );
}; };

190
src/views/components/resiForm.vue

@ -1190,7 +1190,7 @@ export default {
centerFlag: 1,//10 centerFlag: 1,//10
joinBranchName: '',// joinBranchName: '',//
joinCommunityTime: '',//yyyy-MM-dd joinCommunityTime: '',//yyyy-MM-dd
longHolidayFlag: 1,//10 // longHolidayFlag: 1,//10
}, },
ensureHouseDto: {// ensureHouseDto: {//
housingNature: '',//code housingNature: '',//code
@ -1782,116 +1782,88 @@ export default {
async handleClick (tab, event) { async handleClick (tab, event) {
console.log(tab); console.log(tab);
console.log(event); console.log(event);
console.log(this.form.resiId); console.log(this.form.resiId );
const tabMapping = {
'教育': {
dtoKey: 'eduInfoDto',
fn: this.residentEduInfo
},
'兴趣爱好': {
dtoKey: 'hobbyInfoDto',
fn: this.residentHobbyInfo
},
'宗教信仰': {
dtoKey: 'religionDto',
fn: this.residentReligion
},
'健康': {
dtoKey: 'healthDto',
fn: this.getHealthInfoDetailById
},
'工作': {
dtoKey: 'workInfoDto',
fn: this.residentWorkInfo
},
'经济情况': {
dtoKey: 'economyDto',
fn: this.getEconomyDetailById
},
'居住': {
dtoKey: 'resideInfoDto',
fn: this.getResideInfoDetailById
},
'家庭': {
dtoKey: 'familyInfoDto',
fn: this.getFamilyInfoDetailById
},
'出生信息': {
dtoKey: 'birthRecordDTO',
fn: this.residentBirthRecord
},
'党员': {
dtoKey: 'parymemberInfoDto',
fn: this.residentPartyMemberInfo
},
'保障房信息': {
dtoKey: 'ensureHouseDto',
fn: this.residentEnsureHouse
},
'失业': {
dtoKey: 'unemployedDto',
fn: this.residentUnemployed
},
'退役军人': {
dtoKey: 'veteranDto',
fn: this.getVeteranDetailById
},
'统战': {
dtoKey: 'unitedFrontDto',
fn: this.residentUnitedFront
},
'志愿者信息': {
dtoKey: 'volunteerDto',
fn: this.getVolunteerDetailById
},
'特殊人群': {
dtoKey: 'specialDto',
fn: this.residentSpecial
},
'老年人': {
dtoKey: 'oldPeopleDto',
fn: this.getOldPeopleDetailById
},
'公益岗人员': {
dtoKey: 'postDto',
fn: this.getWelfareDetailById
},
};
let currentTab = tabMapping[tab._props.label];
if (tab._props.label == '教育') { if (currentTab) {
if (!this.form.resiId) {
this.newForm.eduInfoDto = this.form.eduInfoDto
} else {
await this.residentEduInfo(this.form.resiId)
}
} else if (tab._props.label == '兴趣爱好') {
if (!this.form.resiId) { if (!this.form.resiId) {
this.newForm.hobbyInfoDto = this.form.hobbyInfoDto this.newForm[currentTab.dtoKey] = this.form[currentTab.dtoKey];
} else {
await this.residentHobbyInfo(this.form.resiId)
}
} else if (tab._props.label == '宗教信仰') {
if (!this.form.resiId) {
this.newForm.religionDto = this.form.religionDto
} else {
await this.residentReligion(this.form.resiId)
}
} else if (tab._props.label == '健康') {
if (!this.form.resiId) {
this.newForm.healthDto = this.form.healthDto
} else {
await this.getHealthInfoDetailById(this.form.resiId)
}
} else if (tab._props.label == '工作') {
if (!this.form.resiId) {
this.newForm.workInfoDto = this.form.workInfoDto
} else {
await this.residentWorkInfo(this.form.resiId)
}
} else if (tab._props.label == '经济情况') {
if (!this.form.resiId) {
this.newForm.economyDto = this.form.economyDto
} else {
await this.getEconomyDetailById(this.form.resiId)
}
} else if (tab._props.label == '居住') {
if (!this.form.resiId) {
this.newForm.resideInfoDto = this.form.resideInfoDto
} else {
await this.getResideInfoDetailById(this.form.resiId)
}
} else if (tab._props.label == '家庭') {
if (!this.form.resiId) {
this.newForm.familyInfoDto = this.form.familyInfoDto
} else {
await this.getFamilyInfoDetailById(this.form.resiId)
}
} else if (tab._props.label == '出生信息') {
if (!this.form.resiId) {
this.newForm.birthRecordDTO = this.form.birthRecordDTO
} else {
await this.residentBirthRecord(this.form.resiId)
}
} else if (tab._props.label == '党员') {
if (!this.form.resiId) {
this.newForm.parymemberInfoDto = this.form.parymemberInfoDto
} else {
await this.residentPartyMemberInfo(this.form.resiId)
}
} else if (tab._props.label == '保障房信息') {
if (!this.form.resiId) {
this.newForm.ensureHouseDto = this.form.ensureHouseDto
} else {
await this.residentEnsureHouse(this.form.resiId)
}
} else if (tab._props.label == '失业') {
if (!this.form.resiId) {
this.newForm.unemployedDto = this.form.unemployedDto
} else {
await this.residentUnemployed(this.form.resiId)
}
} else if (tab._props.label == '退役军人') {
if (!this.form.resiId) {
this.newForm.veteranDto = this.form.veteranDto
} else {
await this.getVeteranDetailById(this.form.resiId)
}
} else if (tab._props.label == '统战') {
if (!this.form.resiId) {
this.newForm.unitedFrontDto = this.form.unitedFrontDto
} else {
await this.residentUnitedFront(this.form.resiId)
}
} else if (tab._props.label == '志愿者信息') {
if (!this.form.resiId) {
this.newForm.volunteerDto = this.form.volunteerDto
} else {
await this.getVolunteerDetailById(this.form.resiId)
}
} else if (tab._props.label == '特殊人群') {
if (!this.form.resiId) {
this.newForm.specialDto = this.form.specialDto
} else {
await this.residentSpecial(this.form.resiId)
}
} else if (tab._props.label == '老年人') {
if (!this.form.resiId) {
this.newForm.oldPeopleDto = this.form.oldPeopleDto
} else {
await this.getOldPeopleDetailById(this.form.resiId)
}
} else if (tab._props.label == '公益岗人员') {
if (!this.form.resiId) {
this.newForm.postDto = this.form.postDto
} else { } else {
// await currentTab.fn(this.form.resiId);
await this.getWelfareDetailById(this.form.resiId)
} }
} }
}, },
@ -2313,7 +2285,7 @@ export default {
centerFlag: null,//10 centerFlag: null,//10
joinBranchName: '',// joinBranchName: '',//
joinCommunityTime: '',//yyyy-MM-dd joinCommunityTime: '',//yyyy-MM-dd
longHolidayFlag: null,//10 // longHolidayFlag: null,//10
} }
this.newForm.parymemberInfoDto = this.form.parymemberInfoDto this.newForm.parymemberInfoDto = this.form.parymemberInfoDto
} }

3
src/views/components/resiSearch.vue

@ -87,7 +87,7 @@
<el-form-item > <el-form-item >
<span style="width:100px;text-align: right;padding-right:14px;display: inline-block; " >所属组织:</span> <span style="width:100px;text-align: right;padding-right:14px;display: inline-block; " >所属组织:</span>
<el-cascader class="u-item-width-normal" size="small" ref="myCascader" v-model="form.agencyId" :options="orgOptions" <el-cascader class="u-item-width-normal" size="small" ref="myCascader" v-model="form.agencyId" :options="orgOptions"
:props="orgOptionProps" :show-all-levels="false" @change="handleChangeAgency"></el-cascader> :props="orgOptionProps" :show-all-levels="false" @change="handleChangeAgency" clearable></el-cascader>
</el-form-item> </el-form-item>
<el-form-item prop="villageId" > <el-form-item prop="villageId" >
<div class="resi-cell"> <div class="resi-cell">
@ -126,7 +126,6 @@
</div> </div>
<el-row v-if="showSmartSearchForm" class="resi-row-more f-m0"> <el-row v-if="showSmartSearchForm" class="resi-row-more f-m0">
<el-col :span="24"> <el-col :span="24">
<span style="width:100px;display: inline-block;text-align: right;padding-right: 18px;">智能查询:</span>
<el-button v-for="btnItem in btnList" :key="btnItem.index" size="small" <el-button v-for="btnItem in btnList" :key="btnItem.index" size="small"
:class="selBtnIndex === btnItem.index ? 'diy-button--white' : 'diy-button--common'" :class="selBtnIndex === btnItem.index ? 'diy-button--white' : 'diy-button--common'"
@click="handelSelSmartBtn(btnItem.index)">{{ btnItem.name }}</el-button> @click="handelSelSmartBtn(btnItem.index)">{{ btnItem.name }}</el-button>

44
src/views/modules/base/resi.vue

@ -12,15 +12,13 @@
<el-col :span="24"> <el-col :span="24">
<el-button size="small" <el-button size="small"
type="primary" type="primary"
@click="handleSearchFrom">智能查询</el-button> @click="handleSearchFrom">查询</el-button>
<el-button style="margin-left: 10px" <el-button style="margin-left: 10px"
size="small" size="small"
plain plain
class="f-right5 diy-button--white" class="f-right5 diy-button--white"
@click="resetSearchForm">重置</el-button> @click="resetSearchForm">重置</el-button>
<el-button size="small"
type="primary"
@click="handleSearchFrom">查询</el-button>
<el-button type="text" <el-button type="text"
size="small" size="small"
style="margin-left: 10px" style="margin-left: 10px"
@ -598,7 +596,6 @@ export default {
}, },
queryConditions: [], queryConditions: [],
searchFlag: false
}; };
}, },
@ -690,7 +687,6 @@ export default {
let obj = this.$refs.myResiSearch.form; let obj = this.$refs.myResiSearch.form;
let categoryArr = this.$refs.myResiSearch.form.categoryKey; let categoryArr = this.$refs.myResiSearch.form.categoryKey;
let agencyId = this.$refs.myResiSearch.form.agencyId; let agencyId = this.$refs.myResiSearch.form.agencyId;
this.searchFlag = true
if ( if (
typeof obj.categoryKey == "object" && typeof obj.categoryKey == "object" &&
obj.categoryKey.length != 0 obj.categoryKey.length != 0
@ -799,11 +795,9 @@ export default {
transferClose () { transferClose () {
this.tranferShow = false; this.tranferShow = false;
this.getTableData();
}, },
deathClose () { deathClose () {
this.deathShow = false; this.deathShow = false;
this.getTableData();
}, },
handleDiyClose () { handleDiyClose () {
this.diyDialog = false; this.diyDialog = false;
@ -891,34 +885,13 @@ export default {
handleSizeChange (val) { handleSizeChange (val) {
console.log(`每页 ${val}`); console.log(`每页 ${val}`);
this.pageSize = val; this.pageSize = val;
this.getTableData(); this.handleSearchFrom()
}, },
handleCurrentChange (val) { handleCurrentChange (val) {
console.log(`当前页: ${val}`);
let obj = this.$refs.myResiSearch.form;
let categoryArr = this.$refs.myResiSearch.form.categoryKey;
let agencyId = this.$refs.myResiSearch.form.agencyId;
if (
typeof obj.categoryKey == "object" &&
obj.categoryKey.length != 0
) {
obj.categoryKey = obj.categoryKey.join(",");
} else {
obj.categoryKey = "";
}
if (typeof obj.agencyId == "object" && obj.agencyId.length != 0) {
obj.agencyId = obj.agencyId[obj.agencyId.length - 1]
} else {
obj.agencyId = "";
}
this.currentPage = val; this.currentPage = val;
if (this.searchFlag) { this.handleSearchFrom()
this.getTableData(obj);
} else {
this.getTableData();
}
this.$refs.myResiSearch.form.categoryKey = categoryArr;
this.$refs.myResiSearch.form.agencyId = agencyId;
}, },
handleFilterSpan (row, item) { handleFilterSpan (row, item) {
let _val = ""; let _val = "";
@ -933,7 +906,6 @@ export default {
}, },
resetSearchForm () { resetSearchForm () {
this.searchFlag = false
for (const n in this.$refs.myResiSearch.form) { for (const n in this.$refs.myResiSearch.form) {
this.$refs.myResiSearch.form[n] = ""; this.$refs.myResiSearch.form[n] = "";
@ -1448,7 +1420,7 @@ export default {
}); });
// console.log(this.$refs.baseForm.form); // console.log(this.$refs.baseForm.form);
this.btnLoading = false; this.btnLoading = false;
this.getTableData(); this.handleSearchFrom();
}, },
async submitEdit (arr) { async submitEdit (arr) {
this.btnLoading = true; this.btnLoading = true;
@ -1731,7 +1703,7 @@ export default {
return this.$message.error(res.msg); return this.$message.error(res.msg);
} else { } else {
this.$message.success("删除成功"); this.$message.success("删除成功");
this.getTableData(); this.handleSearchFrom();
} }
}) })
.catch((err) => { .catch((err) => {

2
src/views/modules/communityParty/regionalParty/units.vue

@ -75,7 +75,7 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-row type="flex" style="margin: 0px"> <el-row type="flex" style="margin: 0px">
<el-col span="24" align="right"> <el-col :span="24" align="right">
<el-button <el-button
style="margin-left: 10px;" style="margin-left: 10px;"
size="small" size="small"

2
src/views/modules/shequzhili/xiangmu/cpts/project-info.vue

@ -1070,7 +1070,7 @@ export default {
async handleWatchOrigin() { async handleWatchOrigin() {
this.topicShow = true; this.topicShow = true;
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.ref_detail_topic.initForm(this.eventId); this.$refs.ref_detail_topic.initForm(this.projectId);
}); });
}, },
diaDetailClose() { diaDetailClose() {

Loading…
Cancel
Save