From 08c8df88fcc6d3cc2ba8bf2a63abc42b87510821 Mon Sep 17 00:00:00 2001
From: 13176889840 <13176889840@163.com>
Date: Mon, 13 Jun 2022 15:14:06 +0800
Subject: [PATCH 18/30] dd
---
.../icpartymemberpayrecorddetail.vue | 24 +++++++++++++++----
.../partymember/icpartymemberpoint.vue | 19 ++++++++++++---
.../modules/visual/communityParty/party.vue | 3 ++-
3 files changed, 38 insertions(+), 8 deletions(-)
diff --git a/src/views/modules/partymember/icpartymemberpayrecorddetail.vue b/src/views/modules/partymember/icpartymemberpayrecorddetail.vue
index 6ac74f3d..c785eae2 100644
--- a/src/views/modules/partymember/icpartymemberpayrecorddetail.vue
+++ b/src/views/modules/partymember/icpartymemberpayrecorddetail.vue
@@ -4,13 +4,28 @@
-
+ clearable /> -->
+
@@ -44,13 +59,14 @@
-
+
@@ -237,7 +253,7 @@
},
// 获取党组织列表
getOrgList() {
- return this.$http.get('/resi/partymember/icPartyOrg/getTreelist', {params: {agencyId: localStorage.getItem('agencyId')}}).then(({data: res}) => {
+ return this.$http.get('/resi/partymember/icPartyOrg/getSearchTreelist', {params: {agencyId: localStorage.getItem('agencyId')}}).then(({data: res}) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
diff --git a/src/views/modules/partymember/icpartymemberpoint.vue b/src/views/modules/partymember/icpartymemberpoint.vue
index 6180d89c..310d1e32 100644
--- a/src/views/modules/partymember/icpartymemberpoint.vue
+++ b/src/views/modules/partymember/icpartymemberpoint.vue
@@ -10,8 +10,9 @@
>
@@ -241,17 +244,27 @@ export default {
this.currentPage = val
this.getDataList()
},
+ deepArrTOnull(arr) {
+ let a = []
+ a = arr.map(item => {
+ return {
+ ...item,
+ children: (item.children.length > 0 && this.deepArrTOnull(item.children) )|| null
+ }
+ })
+ return a
+ },
// 获取党组织列表
getOrgList() {
return this.$http
- .get('/resi/partymember/icPartyOrg/getTreelist', {
+ .get('/resi/partymember/icPartyOrg/getSearchTreelist', {
params: { agencyId: localStorage.getItem('agencyId') }
})
.then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
- this.orgList = res.data
+ this.orgList = this.deepArrTOnull(res.data)
})
.catch(() => {})
},
diff --git a/src/views/modules/visual/communityParty/party.vue b/src/views/modules/visual/communityParty/party.vue
index 3309ae0b..49a84ac4 100644
--- a/src/views/modules/visual/communityParty/party.vue
+++ b/src/views/modules/visual/communityParty/party.vue
@@ -753,7 +753,8 @@ export default {
async getPartyOggList(node, resolve) {
// const url = "/gov/org/customeragency/staffinagencylist";
// const url = '/gov/org/customeragency/agencygridtree'
- const url = '/resi/partymember/icPartyOrg/getTreelist'
+ // const url = '/resi/partymember/icPartyOrg/getTreelist'
+ const url ='/resi/partymember/icPartyOrg/getSearchTreelist'
let params = {
agencyId: this.$store.state.user.agencyId,
};
From 8a8d504db3e0468d40525cf668f9fc0551f3bdf8 Mon Sep 17 00:00:00 2001
From: 13176889840 <13176889840@163.com>
Date: Mon, 13 Jun 2022 16:43:22 +0800
Subject: [PATCH 19/30] dd
---
src/views/modules/communityParty/members/crateForm.vue | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/views/modules/communityParty/members/crateForm.vue b/src/views/modules/communityParty/members/crateForm.vue
index 9b0a5f0b..8f8ac56d 100644
--- a/src/views/modules/communityParty/members/crateForm.vue
+++ b/src/views/modules/communityParty/members/crateForm.vue
@@ -188,7 +188,8 @@ export default {
partymenberid: '',
partyProps: {
label: 'partyOrgName',
- value: 'id'
+ value: 'id',
+ emitPath: false
},
zwList: [
{
From b23130d5cb2241722ae2eb2d71dbc10959aefec0 Mon Sep 17 00:00:00 2001
From: zhaoyongnian <541231643@qq.com>
Date: Mon, 13 Jun 2022 16:47:17 +0800
Subject: [PATCH 20/30] bug
---
.../partymember/icpartyorg-add-or-update.vue | 100 +++++++++++-------
.../modules/partymember/icpartyorgtree.vue | 10 +-
2 files changed, 66 insertions(+), 44 deletions(-)
diff --git a/src/views/modules/partymember/icpartyorg-add-or-update.vue b/src/views/modules/partymember/icpartyorg-add-or-update.vue
index 1a2676e7..7453fdaa 100644
--- a/src/views/modules/partymember/icpartyorg-add-or-update.vue
+++ b/src/views/modules/partymember/icpartyorg-add-or-update.vue
@@ -8,7 +8,7 @@
@keyup.enter.native="dataFormSubmitHandle()"
:label-width="$i18n.locale === 'en-US' ? '120px' : '100px'">
-
+
-
+
+
+
+
@@ -129,7 +133,8 @@
staffId:'',
orgPidName: '',
agencyName:'',
- pid: ''
+ pid: '',
+ sjdzzName: '' // 新增下级上级党组织名字
},
orgListVisible: false,
agencyListVisible:false,
@@ -151,27 +156,40 @@
this.agencyId = localStorage.getItem('agencyId')
this.dataForm.customerId = localStorage.getItem('customerId')
this.dataForm.staffId = localStorage.getItem('staffId')
+ //设置党组织类型
+
this.$nextTick(() => {
this.$refs['dataForm'].resetFields()
this.dataForm.latitude = ''
- //设置党组织类型
- this.setPartyOrgType()
- this.getOrgList().then(() => {
- if (this.dataForm.id) {
- this.getInfo()
- } else {
- this.initMap()
- if(this.dataForm.orgId) {
- this.dataForm.mySelectOrg = this.dataForm.orgId
- this.dataForm.orgPid = this.dataForm.orgId
- this.dataForm.orgPids = this.dataForm.orgPids ? this.dataForm.orgPids + ':' + this.dataForm.orgId : this.dataForm.orgId
- console.log(this.dataForm.orgPid)
- console.log(this.dataForm.orgPids)
- } else {
- this.dataForm.mySelectOrg = ''
+ if (this.dataForm.id) {
+ this.getInfo()
+ } else {
+ this.initMap()
+ if(this.dataForm.orgId) {
+ this.dataForm.mySelectOrg = this.dataForm.orgId
+ 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
+ if (this.dataForm.partyOrgType === '0') { // 党组织类型 0省委,1市委,2区委,3党工委,4党委,5支部
+ this.dataForm.partyOrgType = '1'
+ } else if (this.dataForm.partyOrgType === '1') {
+ this.dataForm.partyOrgType = '2'
+ } else if (this.dataForm.partyOrgType === '2') {
+ this.dataForm.partyOrgType = '3'
+ } else if (this.dataForm.partyOrgType === '3') {
+ this.dataForm.partyOrgType = '4'
+ } else if (this.dataForm.partyOrgType === '4') {
+ this.dataForm.partyOrgType = '5'
}
+ console.log(this.dataForm.orgPid)
+ console.log(this.dataForm.orgPids)
+ // this.getOrgList()
+ } else {
+ this.dataForm.mySelectOrg = ''
}
- })
+ }
+
+ this.setPartyOrgType()
})
},
//设置组织类型
@@ -216,30 +234,37 @@
]
}
},
+ // 选中行政组织
+ changeAgencyOrg () {
+ console.log(this.dataForm.agencyId)
+ this.getOrgList()
+ },
// 选中组织类型 组织类型为支部时不需要选择行政组织
changePartyOrgType(value){
if(value != '5'){ // 支部
this.dataForm.agencyId = ''
this.dataForm.agencyPids = ''
}
- this.$http.get('/gov/org/customeragency/getOrgTreeByUserAndType', {params: {agencyId: this.agencyId, orgType:value}}).then(({data: res}) => {
- if (res.code !== 0) {
- return this.$message.error(res.internalMsg ? res.internalMsg : res.msg ? res.msg : '查询失败')
- }
- this.agencyOrgList = this.removeEmptyChildren(res.data)
- }).catch(() => {})
+ //根据组织类型获取行政组织
+ this.getInfoAgencyLisy()
+ // this.$http.get('/gov/org/customeragency/getOrgTreeByUserAndType', {params: {agencyId: this.agencyId, orgType:value}}).then(({data: res}) => {
+ // if (res.code !== 0) {
+ // return this.$message.error(res.internalMsg ? res.internalMsg : res.msg ? res.msg : '查询失败')
+ // }
+ // this.agencyOrgList = this.removeEmptyChildren(res.data)
+ // }).catch(() => {})
},
// 获取党组织列表
getOrgList() {
- return this.$http.get('/resi/partymember/icPartyOrg/getTreelist', {params: {agencyId: this.agencyId, orgPid: this.dataForm.id ? this.dataForm.pid : ''}}).then(({data: res}) => {
+ this.$http.get('/resi/partymember/icPartyOrg/getParentOrgList', {params: {agencyId: this.dataForm.agencyId, partyOrgType: this.dataForm.partyOrgType}}).then(({data: res}) => {
if (res.code !== 0) {
return this.$message.error(res.internalMsg ? res.internalMsg : res.msg ? res.msg : '查询失败')
}
this.orgList = this.removeEmptyChildren(res.data)
- this.orgList.unshift({
- partyOrgName: '一级组织',
- id: '0'
- });
+ // this.orgList.unshift({
+ // partyOrgName: '一级组织',
+ // id: '0'
+ // });
}).catch(() => {
})
},
@@ -282,23 +307,20 @@
this.dataForm.mySelectOrg = this.dataForm.orgPid
// 行政组织
this.dataForm.agencyId = this.dataForm.agencyId
+ //根据组织类型获取行政组织
+ this.getInfoAgencyLisy()
+ this.getOrgList()
+ console.log(':::::', JSON.stringify(this.dataForm))
this.initMap()
}).catch(() => {
})
-
- //根据组织类型获取行政组织
- this.getInfoAgencyLisy()
},
getInfoAgencyLisy(){
- this.$http.get('/gov/org/customeragency/getOrgTreeByUserAndType',
- {params:
- {agencyId: this.agencyId,
- orgType:this.dataForm.partyOrgType}
- }).then(({data: res}) => {
+ this.$http.get('/gov/org/customeragency/getOrgTreeByUserAndType', {params: {agencyId: this.agencyId, orgType: this.dataForm.partyOrgType}}).then(({data: res}) => {
if (res.code !== 0) {
return this.$message.error(res.internalMsg ? res.internalMsg : res.msg ? res.msg : '查询失败')
}
- this.agencyOrgList = res.data
+ this.agencyOrgList = this.removeEmptyChildren(res.data)
}).catch(() => {
})
},
diff --git a/src/views/modules/partymember/icpartyorgtree.vue b/src/views/modules/partymember/icpartyorgtree.vue
index ff1acebd..6c8db18d 100644
--- a/src/views/modules/partymember/icpartyorgtree.vue
+++ b/src/views/modules/partymember/icpartyorgtree.vue
@@ -24,12 +24,12 @@
size="small"
class="div-table-button--detail">{{'查看党员'}}
新增下级
修改
@@ -106,8 +106,7 @@
this.tableLoading = false
},
// 新增 / 修改
- addOrUpdateHandle (id, orgId, orgPids, pid) {
- console.log('pid:::::', pid)
+ addOrUpdateHandle (id, orgId, orgPids, pid, partyOrgType, partyOrgName) {
this.addOrUpdateVisible = true
this.$nextTick(() => {
this.$refs.addOrUpdate.dataForm.id = id
@@ -115,7 +114,8 @@
this.$refs.addOrUpdate.dataForm.orgId = orgId // 党组织
this.$refs.addOrUpdate.dataForm.orgPids = orgPids
this.$refs.addOrUpdate.dataForm.pid = pid
-
+ this.$refs.addOrUpdate.dataForm._partyOrgType = partyOrgType
+ this.$refs.addOrUpdate.dataForm.sjdzzName = partyOrgName
this.$refs.addOrUpdate.init()
})
},
From a6aecec4971fb236c0a0b65fd3d74918fb8f5a18 Mon Sep 17 00:00:00 2001
From: 13176889840 <13176889840@163.com>
Date: Tue, 14 Jun 2022 10:52:59 +0800
Subject: [PATCH 21/30] =?UTF-8?q?=E6=98=BE=E7=A4=BA=E5=9B=BE=E8=A1=A8?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../visual/communityParty/community.vue | 13 ++++---
.../modules/visual/communityParty/party.vue | 36 ++++++++++++++-----
.../visual/components/screen-map/index.vue | 6 ++--
3 files changed, 40 insertions(+), 15 deletions(-)
diff --git a/src/views/modules/visual/communityParty/community.vue b/src/views/modules/visual/communityParty/community.vue
index 50c7c96c..6ae4a114 100644
--- a/src/views/modules/visual/communityParty/community.vue
+++ b/src/views/modules/visual/communityParty/community.vue
@@ -363,10 +363,12 @@ export default {
console.log('params------c', params)
if (params.seriesIndex == 0 || params.seriesIndex == 2) {
this.unitType = ''
- this.getUnitList(this.agencyId)
- return
- }
- this.clickEduPie(params.dataIndex)
+ // this.getUnitList(this.agencyId)
+ this.$refs.eduChart.clear()
+ this.noInit = false
+ this.clickEduPie(0)
+ // return
+ } else this.clickEduPie(params.dataIndex)
}
this.$refs.eduChart.handleClick(fun)
// this.noInit = true
@@ -772,9 +774,11 @@ export default {
this.orgId = _arr[0]
this.orgLevel = orgType
this.unitType = ''
+ this.$refs.eduChart.clear()
this.getList(_arr[0])
await this.getCateType(_arr[0])
await this.loadOrgData()
+
this.agencyInfo = { ...this.orgData }
console.log('agencyInfo-----', this.agencyInfo)
this.getUnitList(_arr[0])
@@ -841,6 +845,7 @@ export default {
}
if (!data.level) {
this.agencyInfo.level = 'street'
+ this.agencyInfo.agencyLevel = 'street'
}
},
diff --git a/src/views/modules/visual/communityParty/party.vue b/src/views/modules/visual/communityParty/party.vue
index 49a84ac4..1530f4f5 100644
--- a/src/views/modules/visual/communityParty/party.vue
+++ b/src/views/modules/visual/communityParty/party.vue
@@ -311,12 +311,20 @@ export default {
this.pieAgeOptions = pieOption(this.pieAgeChartS)
this.clickAgePie(0)
let fun = params => {
+ // if (params.seriesIndex == 0 || params.seriesIndex == 2) {
+ // this.ageCode = ''
+ // this.getAgeList()
+ // return
+ // }
if (params.seriesIndex == 0 || params.seriesIndex == 2) {
this.ageCode = ''
- this.getAgeList()
- return
- }
- this.clickAgePie(params.dataIndex)
+ // this.getUnitList(this.agencyId)
+ this.$refs.ageChart.clear()
+ this.noInit = false
+ this.clickAgePie(0)
+ // return
+ } else this.clickAgePie(params.dataIndex)
+ // this.clickAgePie(params.dataIndex)
}
this.$refs.ageChart.handleClick(fun)
// option && this.$refs.pieChart.setOption(option);
@@ -364,12 +372,20 @@ export default {
// this.pieEduOptions.series[1].width = 400
this.clickEduPie(0)
let fun = params => {
+ // if (params.seriesIndex == 0 || params.seriesIndex == 2) {
+ // this.eduCode = ''
+ // this.getEduList()
+ // return
+ // }
+ this.clickEduPie(params.dataIndex)
if (params.seriesIndex == 0 || params.seriesIndex == 2) {
this.eduCode = ''
- this.getEduList()
- return
- }
- this.clickEduPie(params.dataIndex)
+ // this.getUnitList(this.agencyId)
+ this.$refs.eduChart.clear()
+ this.noEduInit = false
+ this.clickEduPie(0)
+ // return
+ } else this.clickEduPie(params.dataIndex)
}
this.$refs.eduChart.handleClick(fun)
// this.noInit = true
@@ -841,6 +857,8 @@ export default {
this.orgType = orgType
this.noInit = false
this.noEduInit = false
+ this.$refs.ageChart.clear()
+ this.$refs.eduChart.clear()
this.getAgeCount(_arr[0], orgType)
this.getEduCount(_arr[0], orgType)
this.getAgeList(_arr[0], orgType)
@@ -850,6 +868,8 @@ export default {
console.log('val-vvvpppppp', val)
this.noInit = false
this.noEduInit = false
+ this.$refs.ageChart.clear()
+ this.$refs.eduChart.clear()
if (val.length > 0) {
const i = val.length - 1
this.agencyId = val[i]
diff --git a/src/views/modules/visual/components/screen-map/index.vue b/src/views/modules/visual/components/screen-map/index.vue
index bfa9f23e..34ae5744 100644
--- a/src/views/modules/visual/components/screen-map/index.vue
+++ b/src/views/modules/visual/components/screen-map/index.vue
@@ -569,11 +569,11 @@ const vueGis = {
//根据组织层级设置缩放级别
setZoom (level) {
if (level === 'district') {
- this.zoom = 11
- } else if (level === 'street') {
this.zoom = 12
- } else if (level === 'community') {
+ } else if (level === 'street') {
this.zoom = 13
+ } else if (level === 'community') {
+ this.zoom = 14
}
},
From ea7cee49272469f9c2f7936185daa72723ce78d9 Mon Sep 17 00:00:00 2001
From: 13176889840 <13176889840@163.com>
Date: Tue, 14 Jun 2022 13:25:40 +0800
Subject: [PATCH 22/30] dd
---
.../visual/communityParty/community.vue | 7 +-
.../modules/visual/communityParty/party.vue | 129 +-----------------
2 files changed, 7 insertions(+), 129 deletions(-)
diff --git a/src/views/modules/visual/communityParty/community.vue b/src/views/modules/visual/communityParty/community.vue
index 6ae4a114..fcd81bc4 100644
--- a/src/views/modules/visual/communityParty/community.vue
+++ b/src/views/modules/visual/communityParty/community.vue
@@ -363,7 +363,7 @@ export default {
console.log('params------c', params)
if (params.seriesIndex == 0 || params.seriesIndex == 2) {
this.unitType = ''
- // this.getUnitList(this.agencyId)
+ this.getUnitList(this.agencyId)
this.$refs.eduChart.clear()
this.noInit = false
this.clickEduPie(0)
@@ -621,7 +621,7 @@ export default {
return {
...item,
color: "#00E5ED",
- fillColor: "rgba(0, 229, 237, 0.16)"
+ fillColor: "rgba(0, 229, 237, 0)"
}
})
@@ -836,7 +836,8 @@ export default {
url,
params,
(data, rspMsg) => {
- this.agencyInfo = data
+ // this.agencyInfo = data
+ this.agencyInfo = { ...data, agencyLevel: data.level}
if (!data.latitude) {
this.agencyInfo.latitude = 36.072227
}
diff --git a/src/views/modules/visual/communityParty/party.vue b/src/views/modules/visual/communityParty/party.vue
index 1530f4f5..016d7e59 100644
--- a/src/views/modules/visual/communityParty/party.vue
+++ b/src/views/modules/visual/communityParty/party.vue
@@ -319,6 +319,7 @@ export default {
if (params.seriesIndex == 0 || params.seriesIndex == 2) {
this.ageCode = ''
// this.getUnitList(this.agencyId)
+ this.getAgeList()
this.$refs.ageChart.clear()
this.noInit = false
this.clickAgePie(0)
@@ -380,7 +381,7 @@ export default {
this.clickEduPie(params.dataIndex)
if (params.seriesIndex == 0 || params.seriesIndex == 2) {
this.eduCode = ''
- // this.getUnitList(this.agencyId)
+ this.getEduList()
this.$refs.eduChart.clear()
this.noEduInit = false
this.clickEduPie(0)
@@ -392,131 +393,7 @@ export default {
// option && this.$refs.pieChart.setOption(option);
},
- initChartType() {
- const eId = document.getElementById('echartType')
- let _charts = echarts.init(eId)
-
- let option = {
- tooltip: {
- trigger: 'item'
- },
- legend: {
- show: true,
- orient: 'vertical',
- top: '20%',
- right: 0,
- textStyle: {
- width: 90,
- color: '#fff',
- rich: {
- a: {
- width: 90
- }
- }
- },
- formatter: name => {
- for (let a = 0; a < this.eduItem.length; a++) {
- // this.data 这个数据中有名称和次数
- if (this.eduItem[a].name === name) {
- //两个名称进行对比,取出对应的次数
- let params1 = name + "\n"; //然后return你需要的legend格式即可
- console.log(params1);
- let tmp = params1.split("\n");
- let res = "" + params1;
- for (let i in tmp) {
- res = res.replace(tmp[i], "");
- }
- return res + params1;
- }
- }
- }
- },
- title: {
- text: '12000', //图形标题,配置在中间对应效果图的80%
- subtext: '总数',
- left: 196,
- top: "center",
- textAlign: 'center',
- textStyle: {
- color: "#fff",
- fontSize: 28,
- align: "center"
- },
- subtextStyle: {
- fontSize: 16,
- color: '#fff',
- align: 'center'
- }
- },
- series: [
- {
- // name: 'Access From',
- type: 'pie',
- // center: ['50%', '50%'],
- radius: ['40%', '60%'],
- avoidLabelOverlap: true,
- // top: top + '%',
- // height: '80%',
- // left: 0,
- width: 400,
- label: {
- position: 'outside',
- alignTo: 'edge',
- formatter: '{a|{c}}\n{r|}\n{name|{b}}',
- minMargin: 5,
- edgeDistance: 20,
- lineHeight: 15,
- color: '#fff',
- fontSize: 15,
- rich: {
- name: {
- padding: [0, 6, 0, 6]
- },
- a: {
- fontSize: 15,
- color: '#fff',
- padding: [0, 6, 0, 6]
- },
- r: {
- backgroundColor: 'auto',
- borderRadius: 6,
- width: 6,
- height: 6,
- // padding: [3, 3, 0, -12]
- }
- }
- },
- emphasis: {
- label: {
- show: true,
- fontSize: '14',
- fontWeight: 'bold'
- }
- },
- labelLine: {
- show: true,
- length: 20,
- length2: 0,
- maxSurfaceAngle: 80
- },
- labelLayout: function (params) {
- const isLeft = params.labelRect.x < _charts.getWidth() / 2;
- const points = params.labelLinePoints;
- // Update the end point.
- points[2][0] = isLeft
- ? params.labelRect.x
- : params.labelRect.x + params.labelRect.width;
- return {
- labelLinePoints: points
- };
- },
- data: this.eduItem
- }
- ]
- }
- option && _charts.setOption(option);
-
- },
+
clickAgePie (seriesIndex) {
let _code = ''
let isClick = false
From 3fb4c763c3b8e3976a7bf96933cf9f226b5699e3 Mon Sep 17 00:00:00 2001
From: zhaoyongnian <541231643@qq.com>
Date: Tue, 14 Jun 2022 14:51:11 +0800
Subject: [PATCH 23/30] bug
---
.../partymember/icpartyorg-add-or-update.vue | 73 ++++++++++---------
.../modules/partymember/icpartyorgtree.vue | 23 +++++-
src/views/modules/partymember/lookMember.vue | 51 ++++++-------
3 files changed, 85 insertions(+), 62 deletions(-)
diff --git a/src/views/modules/partymember/icpartyorg-add-or-update.vue b/src/views/modules/partymember/icpartyorg-add-or-update.vue
index 7453fdaa..a539e952 100644
--- a/src/views/modules/partymember/icpartyorg-add-or-update.vue
+++ b/src/views/modules/partymember/icpartyorg-add-or-update.vue
@@ -140,6 +140,7 @@
agencyListVisible:false,
orgList: [],
agencyId: '',
+ level: '',
partyOrgTypeList: [],
agencyOrgList:[]
}
@@ -162,41 +163,44 @@
this.$refs['dataForm'].resetFields()
this.dataForm.latitude = ''
if (this.dataForm.id) {
+ this.setPartyOrgType()
this.getInfo()
} else {
+ this.setPartyOrgType()
this.initMap()
if(this.dataForm.orgId) {
this.dataForm.mySelectOrg = this.dataForm.orgId
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
- if (this.dataForm.partyOrgType === '0') { // 党组织类型 0省委,1市委,2区委,3党工委,4党委,5支部
- this.dataForm.partyOrgType = '1'
- } else if (this.dataForm.partyOrgType === '1') {
- this.dataForm.partyOrgType = '2'
- } else if (this.dataForm.partyOrgType === '2') {
- this.dataForm.partyOrgType = '3'
- } else if (this.dataForm.partyOrgType === '3') {
- this.dataForm.partyOrgType = '4'
- } else if (this.dataForm.partyOrgType === '4') {
- this.dataForm.partyOrgType = '5'
- }
- console.log(this.dataForm.orgPid)
- console.log(this.dataForm.orgPids)
- // this.getOrgList()
+ console.log(this.dataForm.partyOrgType, this.dataForm.orgPid, this.dataForm.orgPids)
+ this.setPartyOrgType_xzxj()
+ this.getInfoAgencyLisy()
} else {
this.dataForm.mySelectOrg = ''
}
}
-
- this.setPartyOrgType()
})
},
+ // 设置组织类型 新增党组织
+ setPartyOrgType_xzxj() {
+ if (this.dataForm.partyOrgType === '0') { // 党组织类型 0省委,1市委,2区委,3党工委,4党委,5支部
+ this.dataForm.partyOrgType = '1'
+ } else if (this.dataForm.partyOrgType === '1') {
+ this.dataForm.partyOrgType = '2'
+ } else if (this.dataForm.partyOrgType === '2') {
+ this.dataForm.partyOrgType = '3'
+ } else if (this.dataForm.partyOrgType === '3') {
+ this.dataForm.partyOrgType = '4'
+ } else if (this.dataForm.partyOrgType === '4') {
+ this.dataForm.partyOrgType = '5'
+ }
+ },
//设置组织类型
setPartyOrgType() {
// 社区级:community,街道级:street,区县级: district,市级: city 省级:province
// 党组织类型 0省委,1市委,2区委,3党工委,4党委,5支部
- this.level = localStorage.getItem('level')
+ this.level = localStorage.getItem('level') ? localStorage.getItem('level') : ''
if (this.level == 'province') {
this.partyOrgTypeList = [
{value: '0', name: '省委'},
@@ -236,35 +240,34 @@
},
// 选中行政组织
changeAgencyOrg () {
- console.log(this.dataForm.agencyId)
- this.getOrgList()
+ if(!this.dataForm.orgId){ // 有orgId 证明是从新增下级过来的,新增下级操作 上级党组织不需要查询
+ this.getOrgList()
+ }
},
// 选中组织类型 组织类型为支部时不需要选择行政组织
changePartyOrgType(value){
- if(value != '5'){ // 支部
- this.dataForm.agencyId = ''
+ if(value == '5'){ // 支部 不选择行政组织
+ this.dataForm.agencyId = localStorage.getItem('agencyId')
this.dataForm.agencyPids = ''
+ this.getOrgList()
+ } else {
+ //根据组织类型获取行政组织
+ this.getInfoAgencyLisy()
}
- //根据组织类型获取行政组织
- this.getInfoAgencyLisy()
- // this.$http.get('/gov/org/customeragency/getOrgTreeByUserAndType', {params: {agencyId: this.agencyId, orgType:value}}).then(({data: res}) => {
- // if (res.code !== 0) {
- // return this.$message.error(res.internalMsg ? res.internalMsg : res.msg ? res.msg : '查询失败')
- // }
- // this.agencyOrgList = this.removeEmptyChildren(res.data)
- // }).catch(() => {})
},
- // 获取党组织列表
+ // 获取上级党组织列表
getOrgList() {
+ if (!this.dataForm.id) { // 修改不做处理
+ this.orgList = []
+ this.dataForm.mySelectOrg = '', // 我选中的当前党组织
+ this.dataForm.orgPid = '', // 党组织的上级ID,没有上级时为0
+ this.dataForm.orgPids = ''
+ }
this.$http.get('/resi/partymember/icPartyOrg/getParentOrgList', {params: {agencyId: this.dataForm.agencyId, partyOrgType: this.dataForm.partyOrgType}}).then(({data: res}) => {
if (res.code !== 0) {
return this.$message.error(res.internalMsg ? res.internalMsg : res.msg ? res.msg : '查询失败')
}
this.orgList = this.removeEmptyChildren(res.data)
- // this.orgList.unshift({
- // partyOrgName: '一级组织',
- // id: '0'
- // });
}).catch(() => {
})
},
@@ -309,8 +312,8 @@
this.dataForm.agencyId = this.dataForm.agencyId
//根据组织类型获取行政组织
this.getInfoAgencyLisy()
+ // 获取上级党组织
this.getOrgList()
- console.log(':::::', JSON.stringify(this.dataForm))
this.initMap()
}).catch(() => {
})
diff --git a/src/views/modules/partymember/icpartyorgtree.vue b/src/views/modules/partymember/icpartyorgtree.vue
index 6c8db18d..b7935dd0 100644
--- a/src/views/modules/partymember/icpartyorgtree.vue
+++ b/src/views/modules/partymember/icpartyorgtree.vue
@@ -14,7 +14,8 @@
row-key="id"
border
:tree-props="{children: 'children', hasChildren: 'hasChildren'}"
- :header-cell-style="{background:'#2195FE',color:'#FFFFFF'}">
+ :header-cell-style="{background:'#2195FE',color:'#FFFFFF'}"
+ :height="tableHeight">
@@ -62,13 +63,16 @@
import AddOrUpdate from './icpartyorg-add-or-update'
import TableTreeColumn from '@/components/table-tree-column'
import lookMember from './lookMember'
+ import { mapGetters } from 'vuex'
export default {
data () {
return {
+ searchH: 0,
dataForm: {
id: '',
customerId: '',
- orgPids: ''
+ orgPids: '',
+ agencyId: ''
},
tableLoading: false,
tableData: [],
@@ -83,9 +87,24 @@
TableTreeColumn,
lookMember
},
+ computed: {
+ ...mapGetters(['clientHeight', 'iframeHeight']),
+ tableHeight() {
+ const h = this.clientHeight - this.searchH - 230 + this.iframeHeigh
+ const _h = this.clientHeight - 230 - this.searchH
+ return this.$store.state.inIframe ? h : _h
+ }
+ },
+ mounted() {
+ this.$nextTick(() => {
+ this.searchH = this.$refs.searchCard.$el.offsetHeight
+ console.log('tableHeight', this.tableHeight)
+ })
+ },
async created () {
this.agencyId = localStorage.getItem('agencyId')
this.dataForm.customerId = localStorage.getItem('customerId')
+ this.dataForm.agencyId = localStorage.getItem('agencyId')
this.getTableData()
// this.pageLoading = true
},
diff --git a/src/views/modules/partymember/lookMember.vue b/src/views/modules/partymember/lookMember.vue
index 92259bd3..7a4b52d5 100644
--- a/src/views/modules/partymember/lookMember.vue
+++ b/src/views/modules/partymember/lookMember.vue
@@ -34,17 +34,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+ 查询
+ 重置
+
-
+
+
+