|
|
@ -38,7 +38,8 @@ Component({ |
|
|
|
}, |
|
|
|
data: { |
|
|
|
ec: { |
|
|
|
onInit: initChart |
|
|
|
lazyLoad: true |
|
|
|
// onInit: initChart
|
|
|
|
}, |
|
|
|
tabList: [{ |
|
|
|
label: "问题突出类别", |
|
|
@ -55,13 +56,21 @@ Component({ |
|
|
|
} |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
tabChange(index) { |
|
|
|
tabChange({detail}) { |
|
|
|
this.setData({ |
|
|
|
tabValue: this.tabList[index].value |
|
|
|
tabValue: this.data.tabList[detail].value |
|
|
|
}) |
|
|
|
this.getData() |
|
|
|
}, |
|
|
|
getData() { |
|
|
|
this.selectComponent('#hotlineComplaints').init((canvas, width, height, dpr) => { |
|
|
|
chart = echarts.init(canvas, null, { |
|
|
|
width: width, |
|
|
|
height: height, |
|
|
|
devicePixelRatio: dpr // 像素比
|
|
|
|
}); |
|
|
|
canvas.setChart(chart); |
|
|
|
|
|
|
|
let params = { |
|
|
|
startTime: '', |
|
|
|
endTime: '' |
|
|
@ -105,7 +114,6 @@ Component({ |
|
|
|
color: '#fff', |
|
|
|
fontSize: 14 |
|
|
|
}, |
|
|
|
backgroundColor: "#04229a", |
|
|
|
formatter(params) { |
|
|
|
// console.log(params)
|
|
|
|
if (params.name === '') { |
|
|
@ -150,7 +158,8 @@ Component({ |
|
|
|
}; |
|
|
|
chart.setOption(option); |
|
|
|
}) |
|
|
|
|
|
|
|
return chart; |
|
|
|
}); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|