option = { grid: { left: '5%', right: '6%', bottom: '5%', top: '20%', containLabel: true }, legend: { icon: 'rect', right: 'center', top: '6%', itemWidth: 12, itemHeight: 12, textStyle: { color: '#333' } }, tooltip: { trigger: 'axis', show: true }, xAxis: { type: 'category', data: ['周一', '周二', '周三', '周四', '周五', '周六', '周日'], axisLabel: { //坐标轴字体颜色 textStyle: { color: '#8C8C8C' } }, axisLine: { lineStyle: { color: '#e5e5e5' } }, axisTick: { //y轴刻度线 show: false }, splitLine: { //网格 show: false } }, yAxis: { type: 'value', boundaryGap: ['0%', '20%'], axisLabel: { //坐标轴字体颜色 textStyle: { color: '#333333' } }, axisLine: { show: false }, axisTick: { //y轴刻度线 show: false }, splitLine: { //网格 show: true, lineStyle: { color: '#dadde4', type: 'dashed' } } }, series: [ { type: 'bar', name: '已使用', stack: 'sum', color: '#1470F3', barMaxWidth: '20%', //柱子宽度 itemStyle: { normal: { borderColor: '#fff', borderWidth: 2, barBorderRadius: [0, 0, 5, 5] } }, data: [220, 182, 191, 234, 290, 330, 310] }, { type: 'bar', name: '未使用', stack: 'sum', color: '#00BFBC', barMaxWidth: '20%', //柱子宽度 itemStyle: { normal: { borderColor: '#fff', borderWidth: 2 } }, data: [220, 182, 191, 234, 290, 330, 310] } ] };