配置项如下
option = {
title: {
text: '工单整体趋势图'
},
tooltip : {
trigger: 'axis'
},
legend: {
data:['PV','UV']
},
toolbox: {
feature: {
saveAsImage: {}
}
},
grid: {
left: '3%',
right: '4%',
bottom: '3%',
containLabel: true
},
xAxis : [
{
type : 'category',
boundaryGap : false,
data : ['周一','周二','周三','周四','周五']
}
],
yAxis : [
{
type : 'value'
}
],
series : [
{
name:'PV',
type:'line',
stack: '总量',
areaStyle: {normal: {}},
data:[120, 132, 101, 134, 90, 230, 210]
},
{
name:'UV',
type:'line',
stack: '总量',
areaStyle: {normal: {}},
data:[220, 182, 191, 234, 290, 330, 310]
},
]
};