diff --git a/src/views/modules/goverhotline/index.vue b/src/views/modules/goverhotline/index.vue index 18805eac1..a35b72247 100644 --- a/src/views/modules/goverhotline/index.vue +++ b/src/views/modules/goverhotline/index.vue @@ -41,31 +41,50 @@

二、工单情况分析

(一)地域统计分析

-

- {{ report.geoStatis }} -

-

各社区问题数量及占比

-
-
-
+
+

+ {{ report.geoStatis }} +

+

各社区问题数量及占比

+
+
+
+
+
+ 暂无数据 +
+

(二)科室热线分布分析

-

- {{ report.departHotline }} -

-

科室热线分布情况

-
-
+ +
+

+ {{ report.geoStatis }} +

+

科室热线分布情况

+
+
+
+
+ 暂无数据 +
+

(三)热点诉求及区域分析

-

- {{ report.hotDemand }} -

-

热线诉求热点问题前十

-
-
+ +
+

+ {{ report.hotDemand }} +

+

热线诉求热点问题前十

+
+
+
+
+
+ 暂无数据
@@ -152,6 +171,10 @@ export default { departChart: {}, hotlineChart: {}, + communityCountShow:false, + departCountShow:false, + subCategoryCountShow:false, + categoryChartOption: { tooltip: { @@ -497,25 +520,29 @@ export default { than.handelClickChart(params.name); }); - this.communityChart= echarts.init(document.getElementById("communityChart")); - this.communityChart.setOption(this.communityOption); - this.communityChart.on("click", function (params) { - than.handelClickChart(params.name); - }); - - - this.departChart= echarts.init(document.getElementById("departChart")); - this.departChart.setOption(this.departOption); - this.departChart.on("click", function (params) { - than.handelClickChart(params.name); - }); - - this.hotlineChart= echarts.init(document.getElementById("hotlineChart")); - this.hotlineChart.setOption(this.hotlineChartOption); - this.hotlineChart.on("click", function (params) { - than.handelClickChart(params.name); + if(this.communityCountShow){ + this.communityChart= echarts.init(document.getElementById("communityChart")); + this.communityChart.setOption(this.communityOption); + this.communityChart.on("click", function (params) { + than.handelClickChart(params.name); + }); + } + + if(this.departCountShow){ + this.departChart= echarts.init(document.getElementById("departChart")); + this.departChart.setOption(this.departOption); + this.departChart.on("click", function (params) { + than.handelClickChart(params.name); }); + } + if(this.subCategoryCountShow){ + this.hotlineChart= echarts.init(document.getElementById("hotlineChart")); + this.hotlineChart.setOption(this.hotlineChartOption); + this.hotlineChart.on("click", function (params) { + than.handelClickChart(params.name); + }); + } window.addEventListener("resize", this.handleWindowResize); @@ -658,6 +685,18 @@ export default { return item; }) : []; + + if (this.report && this.report. communityCount && Object.keys(this.report. communityCount).length > 0) { + this.communityCountShow = true; + } + + if (this.report && this.report.departCount && Object.keys(this.report.departCount).length > 0) { + this.departCountShow = true; + } + + if (this.report && this.report.subCategoryCount && Object.keys(this.report.subCategoryCount).length > 0) { + this.subCategoryCountShow = true; + } }, }, @@ -712,6 +751,15 @@ export default { margin-bottom: 20px; /* 设置标题与下方内容的间距 */ } +.no-data { + display: flex; + justify-content: center; + align-items: center; + height: 200px; /* 调整高度以适应你的需要 */ + color: #888; /* 灰色字体颜色 */ + font-size: 20px; /* 字体大小 */ +} + \ No newline at end of file