- 参考文章:http://www.duanlonglong.com/qdjy/1226.html
top_right_options: {
padding: [0],
grid: {
top: 20,
bottom: 35,
},
xAxis: {
type: 'category',
splitLine: {
show: false,
},
axisLabel: {
textStyle: { color: '#75baea' },
},
data: ['房屋\n故障', '园区工\n程故障', '园区建\n筑故障', '工业机\n械故障', '园区电\n路故障', '消防\n故障', '器材\n故障'],
},
yAxis: {
type: 'value',
},
series: [
{
barWidth: '25%',
itemStyle: {
normal: {
color() {
return null;
},
label: {
formatter: '{c}',
show: true,
position: 'top',
textStyle: {
fontWeight: 'bolder',
fontSize: '10',
color: '#fff',
},
},
},
},
data: [650, 810, 400, 400, 600, 600, 400],
type: 'bar',
},
{
type: 'pictorialBar',
data: [650, 810, 400, 400, 600, 600, 400],
symbol: 'image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAByCAYAAABeOoENAAAACXBIWXMAAAsTAAALEwEAmpwYAAAF8WlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNS42LWMxNDggNzkuMTY0MDM2LCAyMDE5LzA4LzEzLTAxOjA2OjU3ICAgICAgICAiPiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPiA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOnhtcE1NPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvbW0vIiB4bWxuczpzdEV2dD0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL3NUeXBlL1Jlc291cmNlRXZlbn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