option = {
tooltip : {
trigger: 'axis',
axisPointer : { // 坐标轴指示器,坐标轴触发有效
type : 'shadow' // 默认为直线,可选为:'line' | 'shadow'
}
},
legend:{data:['1','2','3','4','5']},
grid: {
left: '3%',
right: '4%',
bottom: '3%',
containLabel: true
},
xAxis : [
{
type : 'category',
data : ['Mon', 'Tue', 'Wed', 'Thu', 'Fri'],
axisTick: {
alignWithLabel: true
}
}
],
yAxis : [
{
type : 'value'
}
],
series : [
{
name:'1',
type:'bar',
barGap:'-100%',
data:[5, 0, 0, 0, 0]
},
{
name:'2',
type:'bar',
barGap:'-100%',
data:[0, 2, 0, 0, 0]
}, {
name:'3',
type:'bar',
barGap:'-100%',
data:[0, 0, 3, 0, 0]
}, {
name:'4',
type:'bar',
barGap:'-100%',
data:[0, 0, 0, 4, 0]
}, {
name:'5',
type:'bar',
barGap:'-100%',
data:[0, 0, 0, 0, 5]
}, ]
};
2017年10月26日 06点10分
5
直接在echarts3官方demo里测试就行
2017年10月26日 06点10分
大佬,有其它的办法么?
2018年08月01日 10点08分