From 95b0e4762dbd5417a3ff5b65d360c238c9f647c2 Mon Sep 17 00:00:00 2001 From: tianq Date: Wed, 19 Apr 2023 13:19:01 +0800 Subject: [PATCH] =?UTF-8?q?y=E8=BD=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/modules/census/census-accountList.vue | 8 +++++++- .../modules/census/census-orgStatusList.vue | 17 +++++++++++------ 2 files changed, 18 insertions(+), 7 deletions(-) diff --git a/src/views/modules/census/census-accountList.vue b/src/views/modules/census/census-accountList.vue index 50c9d68cc..0062d99f4 100644 --- a/src/views/modules/census/census-accountList.vue +++ b/src/views/modules/census/census-accountList.vue @@ -539,6 +539,7 @@ export default { // 获取饼状图 async iniPieChart(chartData) { this.$refs.pieChart.clear(); + // 获取pieChart配置 this.pieOption = { grid: { @@ -588,7 +589,9 @@ export default { lineStyle: { color: '#F3F7FD' } - } + }, + min:0, + max:1000, }, series: [ { @@ -602,6 +605,9 @@ export default { } ] }; + if (chartData.data.length>0) { + this.pieOption.yAxis.max=null + } this.$refs.pieChart.setOption(this.pieOption); }, handelClickMyPei(param) { diff --git a/src/views/modules/census/census-orgStatusList.vue b/src/views/modules/census/census-orgStatusList.vue index dabe90fc4..f6757a57b 100644 --- a/src/views/modules/census/census-orgStatusList.vue +++ b/src/views/modules/census/census-orgStatusList.vue @@ -115,7 +115,7 @@ - + @@ -218,7 +218,7 @@ export default { TableHeight: '', pieData: {}, agencyId: '', - level:'', + level: '' }; }, components: { @@ -227,7 +227,7 @@ export default { computed: { maxTableHeight() { this.TableHeight = this.$store.state.inIframe ? this.clientHeight - 431 + this.iframeHeigh : this.clientHeight - 431; - console.log("this.TableHeight",this.TableHeight) + console.log('this.TableHeight', this.TableHeight); return this.TableHeight; }, @@ -443,6 +443,7 @@ export default { // 获取饼状图 async iniPieChart(chartData) { this.$refs.pieChart.clear(); + // 获取pieChart配置 this.pieOption = { grid: { @@ -492,7 +493,9 @@ export default { lineStyle: { color: '#F3F7FD' } - } + }, + min: 0, + max: 1000 }, series: [ { @@ -501,11 +504,14 @@ export default { type: 'bar', itemStyle: { color: 'rgb(33, 149, 254)', - borderRadius: [4, 4, 0, 0], + borderRadius: [4, 4, 0, 0] } } ] }; + if (chartData.data.length>0) { + this.pieOption.yAxis.max=null + } this.$refs.pieChart.setOption(this.pieOption); }, handelClickMyPei(param) { @@ -604,5 +610,4 @@ export default { border-radius: 6px; color: #fff; } -