diff --git a/src/views/modules/visual/communityParty/crateForm.vue b/src/views/modules/visual/communityParty/crateForm.vue new file mode 100644 index 000000000..ff37c1c27 --- /dev/null +++ b/src/views/modules/visual/communityParty/crateForm.vue @@ -0,0 +1,425 @@ + + + + + + + \ No newline at end of file diff --git a/src/views/modules/visual/communityParty/party.vue b/src/views/modules/visual/communityParty/party.vue index 826333519..637d14fe3 100644 --- a/src/views/modules/visual/communityParty/party.vue +++ b/src/views/modules/visual/communityParty/party.vue @@ -2,7 +2,8 @@
- +
党员信息统计   - + }" + :show-all-levels="false" + clearable + @change="handlePartyCascader"> -
+
@@ -33,14 +34,17 @@
+ @myChartMethod="pieInitOk" + ref="ageChart">
-
-
+
+
{{ item.name }}
@@ -48,34 +52,33 @@
{{ item.radio }}
- +
- +
- 导出 + 导出
- +
@@ -87,50 +90,71 @@ + @myChartMethod="pieInitOks" + ref="eduChart">
-
+
-
-
+
+
{{item.name}}
- +
- 导出 + 导出
- +
- + + +
@@ -140,6 +164,7 @@ import screenTable from "../components/screen-table/index"; import cptCard from "@/views/modules/visual/cpts/card"; import nextTick from "dai-js/tools/nextTick"; import screenEchartsFrame from "../components/screen-echarts-frame"; +import crateForm from './crateForm.vue'; import { pieOption } from './options' import * as echarts from 'echarts'; @@ -148,10 +173,15 @@ export default { components: { cptCard, screenTable, - screenEchartsFrame + screenEchartsFrame, + crateForm }, - data() { + data () { return { + memberDialog: false, + disabled: true, + memberDetailInfo: {}, + optionsG: [], headerList: [ { title: "序号", coulmn: 'index' }, { title: "姓名", coulmn: 'name' }, @@ -272,7 +302,7 @@ export default { pieEduOptions: null }; }, - async mounted() { + async mounted () { await nextTick(100); // await this.getAgencyList() await this.getPartyOggList() @@ -280,16 +310,41 @@ export default { // this.getEduCount(this.$store.state.user.agencyId, 'agency') // this.getAgeList(this.$store.state.user.agencyId, 'agency') // this.getEduList(this.$store.state.user.agencyId, 'agency') - this.getAgeCount() + this.getAgeCount() this.getEduCount() this.getAgeList() this.getEduList() // this.initAgeCharts() // this.initEduCharts() - + // this.initChartType() }, + async created () { + this.getGridList('query') + }, methods: { + handleSearch () { + this.memberDialog = false + }, + handlerCancle () { + this.memberDialog = false + }, + async getGridList (type, agencyId) { + const { user } = await this.$store.state + // addorupdate query + await this.$http + .get('/resi/partymember/icPartyOrg/getSearchTreelist', { params: { agencyId: agencyId || user.agencyId } }) + .then(({ data: res }) => { + if (res.code !== 0) { + return this.$message.error(res.msg) + } else { + this.optionsG = this.deepArrTOnull(res.data) + } + }) + .catch(() => { + return this.$message.error('网络错误') + }) + }, pieInitOk (dom) { console.log('pie准备好了', dom) this.pieAgeChartS = dom @@ -302,11 +357,11 @@ export default { // this.pieInitState = true }, - initAgeCharts() { + initAgeCharts () { // const eId = document.getElementById('echartOrg') // let _charts = echarts.init(eId) let option = { - + } this.pieAgeOptions = pieOption(this.pieAgeChartS) this.clickAgePie(0) @@ -332,11 +387,11 @@ export default { // option && this.$refs.pieChart.setOption(option); }, - initEduCharts() { + initEduCharts () { // const eId = document.getElementById('echartOrg') // let _charts = echarts.init(eId) let option = { - + } let legend = { show: true, @@ -394,7 +449,7 @@ export default { // option && this.$refs.pieChart.setOption(option); }, - + clickAgePie (seriesIndex) { let _code = '' let isClick = false @@ -402,7 +457,7 @@ export default { this.ageItem.forEach((element, index) => { if (index === seriesIndex) { _code = element.code - + if (!this.noInit) isClick = false else { element.isClick = !element.isClick @@ -514,10 +569,10 @@ export default { } this.noEduInit = true - + }, - async getAgeCount(orgId, orgType) { + async getAgeCount (orgId, orgType) { // const url = "/epmetuser/icresiuser/partymemberagestatistics"; const url = '/resi/partymember/icPartyMember/partymemberagestatistics' let params = { @@ -567,7 +622,7 @@ export default { } else { } }, - async getEduCount(orgId, orgType) { + async getEduCount (orgId, orgType) { // const url = "/epmetuser/icresiuser/partymembereducationstatistics"; const url = '/resi/partymember/icPartyMember/partymembereducationstatistics' let params = { @@ -591,8 +646,8 @@ export default { } else { } }, - async getAgeList(orgId, orgType, _code) { - + async getAgeList (orgId, orgType, _code) { + this.visibleAgeLoading = true // const url = "/epmetuser/icresiuser/partymemberagelist"; const url = '/resi/partymember/icPartyMember/partymemberagelist' @@ -618,7 +673,7 @@ export default { // if (_code == 0 || _code) this.noInit = true this.visibleAgeLoading = false }, - async getEduList(orgId, orgType, _code) { + async getEduList (orgId, orgType, _code) { this.visibleLoading = true // const url = "/epmetuser/icresiuser/partymembereducationlist"; const url = '/resi/partymember/icPartyMember/partymembereducationlist' @@ -644,34 +699,34 @@ export default { } this.visibleLoading = false }, - async getPartyOggList(node, resolve) { + 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/getSearchTreelist' + const url = '/resi/partymember/icPartyOrg/getSearchTreelist' let params = { agencyId: this.$store.state.user.agencyId, }; const { data, code, msg } = await requestGet(url, params); console.log('data-orgparty----o', data) if (code === 0) { - + this.partyOrgList = this.deepArrTOnull(data) } else { } }, - deepArrTOnull(arr) { + deepArrTOnull (arr) { let a = [] a = arr.map(item => { return { ...item, - children: (item.children.length > 0 && this.deepArrTOnull(item.children) )|| null + children: (item.children.length > 0 && this.deepArrTOnull(item.children)) || null } }) return a }, - async getAgencyList(node, resolve) { + async getAgencyList (node, resolve) { // const url = "/gov/org/customeragency/staffinagencylist"; const url = '/gov/org/customeragency/agencygridtree' // let params = { @@ -690,25 +745,26 @@ export default { } else { } }, - getTreeData(data){ + getTreeData (data) { if (!Array.isArray(data)) return [] let arr = data.map(item => { let _item = {} if (item.subAgencyList) { if (item.subAgencyList.length === 0) { - _item = { + _item = { label: item.agencyName, value: item.agencyId + '-' + item.level, level: item.level, - children: undefined + children: undefined } - } else _item = { + } else _item = { label: item.agencyName, value: item.agencyId + '-' + item.level, level: item.level, - children: this.getTreeData(item.subAgencyList)} + children: this.getTreeData(item.subAgencyList) + } } else { - _item = { + _item = { label: item.agencyName, value: item.agencyId + '-' + item.level, level: item.level, @@ -718,19 +774,37 @@ export default { }) return arr }, - handleClickRow(val) { - console.log('click-row----', val) - if (!val.icResiUser) { - return this.$message.warning('该党员居民信息未完善') - } + handleClickRow (val) { + this.getDetail(val.userId) + this.memberDialog = true + }, + jumpDetail (val) { + this.memberDialog = false this.$router.push({ - path: `/main-shuju/visual-basicinfo-people/${val.icResiUser}`, + path: `/main-shuju/visual-basicinfo-people/${val}`, }); }, - handleCascader(val) { + getDetail (id) { + let params = { + id, + } + this.$http + .post(`/resi/partymember/icPartyMember/${id}`) + .then(({ data: res }) => { + if (res.code !== 0) { + return this.$message.error(res.msg) + } else { + this.memberDetailInfo = { ...res.data } + } + }) + .catch((err) => { + return this.$message.error('网络错误') + }) + }, + handleCascader (val) { console.log('val-vvv', val) const _arr = val[val.length - 1].split('-') - const orgType = _arr[1] !== 'grid' ? 'agency': 'grid' + const orgType = _arr[1] !== 'grid' ? 'agency' : 'grid' this.agencyId = _arr[0] this.orgType = orgType this.noInit = false @@ -742,7 +816,7 @@ export default { this.getAgeList(_arr[0], orgType) this.getEduList(_arr[0], orgType) }, - handlePartyCascader(val) { + handlePartyCascader (val) { console.log('val-vvvpppppp', val) this.noInit = false this.noEduInit = false @@ -762,17 +836,17 @@ export default { this.getAgeList('') this.getEduList('') } - + }, - getCheckedNodes(val) { + getCheckedNodes (val) { console.log('val-nnn', val) }, - lazyLoad(node, resolve) { + lazyLoad (node, resolve) { setTimeout(() => { this.getAgeList(node, resolve) }, 500) }, - pageSizeChangeHandleAge(val) { + pageSizeChangeHandleAge (val) { this.agePageNo = 1 this.agePageSize = val this.getAgeList(this.agencyId, this.orgType, this.ageCode) @@ -781,22 +855,22 @@ export default { this.agePageNo = val this.getAgeList(this.agencyId, this.orgType, this.ageCode) }, - pageSizeChangeHandleNew(val) { + pageSizeChangeHandleNew (val) { this.pageNo = 1; this.pageSize = val; this.getEduList(this.agencyId, this.orgType, this.eduCode) }, - pageCurrentChangeHandleNew(val) { + pageCurrentChangeHandleNew (val) { this.pageNo = val; this.getEduList(this.agencyId, this.orgType, this.eduCode) }, - async handleExport(type) { + async handleExport (type) { const urls = { age: '/epmetuser/icresiuser/partymemberagelist/export', edu: '/epmetuser/icresiuser/partymembereducationlist/export' } const _arr = this.selectAgency[this.selectAgency.length - 1].split('-') - const orgType = _arr[1] !== 'grid' ? 'agency': 'grid' + const orgType = _arr[1] !== 'grid' ? 'agency' : 'grid' let params = { orgId: _arr[0], orgType: orgType, @@ -878,8 +952,8 @@ export default { color: #fff; line-height: 24px; text-align: center; - background: #06186D; - border: 1px solid #1A64CC; + background: #06186d; + border: 1px solid #1a64cc; border-radius: 2px; } .el-input__prefix { @@ -891,15 +965,13 @@ export default { line-height: 24px; } } - } } - .title-label { + .title-label { font-size: 22px; font-family: PingFang SC; font-weight: 800; ::v-deep .el-input { - width: 180px; .el-input__inner { font-size: 18px; @@ -909,7 +981,7 @@ export default { border: 1px solid #1a64cc; } .el-icon-arrow-down::before { - content: "\e790"; + content: "\e790"; } } } @@ -937,7 +1009,7 @@ export default { color: #fff; } .card-left-title::after { - content: ''; + content: ""; position: absolute; top: 50%; left: 20px; @@ -945,7 +1017,7 @@ export default { height: 12px; box-sizing: border-box; margin-top: -6px; - background: #2865FA; + background: #2865fa; border-radius: 50%; } .echart-wr { @@ -988,7 +1060,10 @@ export default { .echarts-tips-wd50 { width: 320px; } -.tips-list, .tips-item, .tips-lists, .tips-items-num { +.tips-list, +.tips-item, +.tips-lists, +.tips-items-num { display: flex; align-items: center; } @@ -1008,12 +1083,12 @@ export default { height: 10px; box-sizing: border-box; margin-right: 8px; - background: #1B51FF; + background: #1b51ff; border-radius: 2px; } .tips-item-text { font-size: 16px; - color: #D2E7FF; + color: #d2e7ff; } } } @@ -1034,19 +1109,24 @@ export default { box-sizing: border-box; padding-left: 6px; font-size: 16px; - color: #EFF0F1; - background: url('../../../../assets/img/shuju/measure/huang@2x.png') no-repeat left bottom; + color: #eff0f1; + background: url("../../../../assets/img/shuju/measure/huang@2x.png") + no-repeat left bottom; &1 { - background: url('../../../../assets/img/shuju/measure/lv@2x.png') no-repeat left bottom; + background: url("../../../../assets/img/shuju/measure/lv@2x.png") + no-repeat left bottom; } &2 { - background: url('../../../../assets/img/shuju/measure/zi@2x.png') no-repeat left bottom; + background: url("../../../../assets/img/shuju/measure/zi@2x.png") + no-repeat left bottom; } &3 { - background: url('../../../../assets/img/shuju/measure/lan@2x.png') no-repeat left bottom; + background: url("../../../../assets/img/shuju/measure/lan@2x.png") + no-repeat left bottom; } &4 { - background: url('../../../../assets/img/shuju/measure/lanlv@2x.png') no-repeat left bottom; + background: url("../../../../assets/img/shuju/measure/lanlv@2x.png") + no-repeat left bottom; } } .tips-items-num { @@ -1074,8 +1154,7 @@ export default { padding-right: 30px; text-align: right; ::v-deep .el-button--warning { - - background: linear-gradient(90deg, #0863EA, #3B9FFC); + background: linear-gradient(90deg, #0863ea, #3b9ffc); border: 0; } }