|
@@ -380,10 +380,15 @@ export default {
|
|
|
this.echartsOption1 = {
|
|
|
color: ['#3AA1FF'],
|
|
|
tooltip: { trigger: 'axis', axisPointer: { type: 'line' }}, // 默认为直线,可选为:'line' | 'shadow'
|
|
|
- grid: { left: '0', right: '0', top: '3%', bottom: '0', containLabel: true },
|
|
|
+ grid: { left: '0', right: '0', top: '5%', bottom: '0', containLabel: true },
|
|
|
xAxis: [{ type: 'category', data: this.chart1Data.xaxis, axisTick: { alignWithLabel: true }}],
|
|
|
yAxis: [{ type: 'value', axisLine: { show: false }, splitLine: { lineStyle: { type: 'dashed' }}}],
|
|
|
- series: [{ name: '缺陷数量', type: 'bar', barWidth: '20px', data: this.chart1Data.yaxis[0] && this.chart1Data.yaxis[0].data || [] }]
|
|
|
+ series: [
|
|
|
+ {
|
|
|
+ name: '缺陷数量', type: 'bar', barWidth: '20px', data: this.chart1Data.yaxis[0] && this.chart1Data.yaxis[0].data || [],
|
|
|
+ itemStyle: { normal: { label: { show: true, formatter: '{b} : {c}', position: 'top' }}}
|
|
|
+ }
|
|
|
+ ]
|
|
|
}
|
|
|
} else {
|
|
|
const newArr = this.chart1Data.xaxis.map((item, index) => {
|