From 21ddc9ec1b1b76d2ce20e512328e65acaf1af2bf Mon Sep 17 00:00:00 2001
From: Surpriseplus <845948745@qq.com>
Date: 星期一, 16 一月 2023 10:35:15 +0800
Subject: [PATCH] 廊坊代码更新

---
 src/components/echart32.vue |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/src/components/echart32.vue b/src/components/echart32.vue
index 8a177cf..f57d2df 100644
--- a/src/components/echart32.vue
+++ b/src/components/echart32.vue
@@ -10,7 +10,7 @@
   components: {},
   data() {
     //杩欓噷瀛樻斁鏁版嵁
-    return { myChart };
+    return { myChart:null };
   },
   mounted() {
     this.lineChart();
@@ -39,6 +39,7 @@
       let option = {
         title: {
           text: '鍚勯」鐩绠�',
+           top:15,
           textStyle: {
             color: '#fff',
           },
@@ -147,7 +148,7 @@
       const zoomSize = 6;
       this.myChart = this.$echarts.init(document.getElementById('echart32'));
       this.myChart.on('click', function (params) {
-        console.log(dataAxis[Math.max(params.dataIndex - zoomSize / 2, 0)]);
+    
         this.myChart.dispatchAction({
           type: 'dataZoom',
           startValue: dataAxis[Math.max(params.dataIndex - zoomSize / 2, 0)],
@@ -171,9 +172,11 @@
 //@import url(); 寮曞叆鍏叡css绫�
 .echart32_box {
   padding: 20px;
-}
-#echart32 {
   width: 100%;
   height: 100%;
 }
+#echart32 {
+  width: calc(100% - 40px);
+  height: calc(100% - 40px);
+}
 </style>

--
Gitblit v1.9.3