var option ={
title: {
text:''},
tooltip: {
trigger:'axis'},
legend: {
data:['销售量']
},
grid: {
left:'3%',
right:'4%',
bottom:'3%',
containLabel:true},
toolbox: {
feature: {
saveAsImage: {}
}
},
xAxis: {
type:'category',
boundaryGap:false,
data: ['周一','周二','周三','周四','周五','周六','周日']
},
yAxis: {
type:'value'},
series: [ //统一设置圈圈与线的颜色
{
name:'销售量',
type:'line',
stack:'销售量',
itemStyle : {
normal : {
color:'#00FF00', //圈圈的颜色
lineStyle:{
color:'#00FF00'//线的颜色
}
}
},
data:[220, 132, 601, 314, 890, 230, 510]
}
]
};
echart.setOption(option);
});