style:成功率统计
Showing
1 changed file
with
6 additions
and
1 deletions
... | @@ -78,6 +78,7 @@ export default { | ... | @@ -78,6 +78,7 @@ export default { |
78 | endTime: timeFormat(new Date(), true), | 78 | endTime: timeFormat(new Date(), true), |
79 | qxdm: "", | 79 | qxdm: "", |
80 | }, | 80 | }, |
81 | interval: 50 | ||
81 | }; | 82 | }; |
82 | }, | 83 | }, |
83 | mounted () { | 84 | mounted () { |
... | @@ -100,6 +101,10 @@ export default { | ... | @@ -100,6 +101,10 @@ export default { |
100 | this.form.qxdm | 101 | this.form.qxdm |
101 | ); | 102 | ); |
102 | this.chartData = res; | 103 | this.chartData = res; |
104 | console.log(this.chartData); | ||
105 | |||
106 | let maxData = Math.max.apply(Math, this.chartData.map(item => { return item.failure })) | ||
107 | this.interval = Math.ceil(maxData / 10) | ||
103 | //行政区代码过滤 | 108 | //行政区代码过滤 |
104 | res.length > 0 && | 109 | res.length > 0 && |
105 | res.forEach((item) => { | 110 | res.forEach((item) => { |
... | @@ -191,7 +196,7 @@ export default { | ... | @@ -191,7 +196,7 @@ export default { |
191 | color: "#fff", | 196 | color: "#fff", |
192 | fontSize: "16", | 197 | fontSize: "16", |
193 | }, | 198 | }, |
194 | interval: 50, | 199 | interval: this.interval, |
195 | axisLabel: { | 200 | axisLabel: { |
196 | formatter: "{value}", | 201 | formatter: "{value}", |
197 | textStyle: { | 202 | textStyle: { | ... | ... |
-
Please register or sign in to post a comment