formatter: function(params) {
var result = ''
params.forEach(function (item) {
console.log(item)
result += item.axisValue + "</br>" + item.marker + item.data
})
return result
}
效果:
formatter: function(params) {
var result = ''
var dotHtml = '<span style="display:inline-block;margin-right:5px;border-radius:10px;width:10px;height:10px;background-color:#1197b8"></span>'
params.forEach(function (item) {
result += item.axisValue + "</br>" + dotHtml + item.data
})
return result}
效果: