Browse Source

bug fixed

duwendi 1 year ago
parent
commit
0132c22da0

+ 13 - 9
src/pages/index/components/arrears_total.vue

@@ -38,11 +38,11 @@
38 38
           :autoStop="false"
39 39
           :colorArr="['#ffd201', '#00eacb', '#01b4ff', '#5d78ff']"
40 40
           legendIcon="react"
41
-          :bottom="30"
41
+          :bottom="50"
42 42
           :xlabelFormat="xLabelFormat"
43 43
           :top="60"
44 44
           yAxisName="(元)"
45
-          :tooltip="tooltipFormat"
45
+          :tooltip="tooltipFormat1"
46 46
           :dataset="bardata1"
47 47
           :encode="[
48 48
             {x: 'mouth', y: 'lastYearAmount', seriesName: ''}]"
@@ -63,7 +63,7 @@
63 63
           :xlabelFormat="xLabelFormat"
64 64
           :top="60"
65 65
           yAxisName="(元)"
66
-          :tooltip="tooltipFormat"
66
+          :tooltip="tooltipFormat2"
67 67
           :dataset="bardata2"
68 68
           :encode="[
69 69
             {x: 'mouth', y: 'lastYearAmount', seriesName: ''}]"
@@ -124,21 +124,25 @@ export default {
124 124
 
125 125
   },
126 126
   methods: {
127
-    tooltipFormat(params) {
127
+    tooltipFormat1(params) {
128 128
       const type = params[0].seriesType;
129 129
       const data = params[0].data;
130 130
       return `<div class="line-tooltip">
131
-<div>${params[0].seriesName}: ${
132
-        params[0].data.lastYearAmount || "--"}个</div>
133
-<div>${params[1].seriesName}: ${
134
-        params[0].data.thisYearAmount || "--"}个</div>
131
+<div style="color: ${params[0].color}">${params[0].data.mouth}: ${
132
+        params[0].data.lastAmount || "--"}元</div>
133
+</div>`;
134
+    },
135
+    tooltipFormat2(params) {
136
+      return `<div class="line-tooltip">
137
+<div style="color: ${params[0].color}">${params[0].data.mouth}: ${
138
+        params[0].data.lastAmount || "--"}元</div>
135 139
 </div>`;
136 140
     },
137 141
     lineTooltipFormat(params) {
138 142
       return `<div class="line-tooltip">
139 143
         <div style="color: ${params[0].color}">${params[0].data.mouth} : ${
140 144
         params[0].data.lastAmount  || "--"
141
-      }</div>`;
145
+      }</div>`;
142 146
     },
143 147
     businessAnalysisStat1(){
144 148
       api.qfzfx1().then(res =>{

+ 1 - 1
src/pages/index/components/business_overview.vue

@@ -24,7 +24,7 @@
24 24
           :bottom="30"
25 25
           :xlabelFormat="xLabelFormat"
26 26
           :top="60"
27
-          yAxisName="()"
27
+          yAxisName="()"
28 28
           :tooltip="tooltipFormat"
29 29
           :dataset="modelData2"
30 30
           :encode="[