diff --git a/src/views/modules/partymember/icpartyorg-add-or-update.vue b/src/views/modules/partymember/icpartyorg-add-or-update.vue index 04bbde23..93c020d7 100644 --- a/src/views/modules/partymember/icpartyorg-add-or-update.vue +++ b/src/views/modules/partymember/icpartyorg-add-or-update.vue @@ -145,12 +145,6 @@ agencyOrgList:[] } }, - // mounted () { - // setTimeout(() => { - // console.log(':::::::::::::::::::::::') - // this.initMap() - // }, 800); - // }, methods: { init() { this.visible = true @@ -159,10 +153,10 @@ this.dataForm.staffId = localStorage.getItem('staffId') this.keyWords = '' //设置党组织类型 - - this.$nextTick(() => { + setTimeout(() => { this.$refs['dataForm'].resetFields() this.dataForm.latitude = '' + this.dataForm.agencyId = '' if (this.dataForm.id) { this.setPartyOrgType() this.getInfo() @@ -174,14 +168,17 @@ this.dataForm.orgPid = this.dataForm.orgId this.dataForm.orgPids = this.dataForm.orgPids ? this.dataForm.orgPids + ':' + this.dataForm.orgId : this.dataForm.orgId this.dataForm.partyOrgType = this.dataForm._partyOrgType - console.log(this.dataForm.partyOrgType, this.dataForm.orgPid, this.dataForm.orgPids) + this.setPartyOrgType_xzxj() this.getInfoAgencyLisy() } else { this.dataForm.mySelectOrg = '' } } - }) + }, 50); + // this.$nextTick(() => { + + // }) }, // 设置组织类型 新增党组织 setPartyOrgType_xzxj() { @@ -250,9 +247,22 @@ if(value == '5'){ // 支部 不选择行政组织 this.dataForm.agencyId = localStorage.getItem('agencyId') this.dataForm.agencyPids = '' + // 先清空数据 + this.orgList = [] + this.dataForm.mySelectOrg = '', // 我选中的当前党组织 + this.dataForm.orgPid = '', // 党组织的上级ID,没有上级时为0 + this.dataForm.orgPids = '' this.getOrgList() } else { - //根据组织类型获取行政组织 + // 先清空数据 + this.agencyOrgList = [] + this.dataForm.agencyId = '' + + // 先清空数据 + this.orgList = [] + this.dataForm.mySelectOrg = '', // 我选中的当前党组织 + this.dataForm.orgPid = '', // 党组织的上级ID,没有上级时为0 + this.dataForm.orgPids = '' this.getInfoAgencyLisy() } },