formatTooltip: function (dataIndex,e) {
var value = this.getRawValue(dataIndex);
var coordSys = this.coordinateSystem;
//get index by position of mouse.
var index = getIndexToDisplay(value.length,getAngle(e.offsetX,e.offsetY,coordSys.cx,coordSys.cy));
var indicatorAxes = coordSys.getIndicatorAxes();
return indicatorAxes[index].name+ ' : ' + value[index]; //wangjx
//region code, display all data of this series.
/*return (this._data.getName(dataIndex) == '' ? this.name : this._data.getName(dataIndex)) + '<br/>'
+ zrUtil.map(indicatorAxes, function (axis, idx) {
return axis.name + ' : ' + value[idx];
}).join('<br />');*/
},
//雷达图单行显示
polar : [
{ center: ['42%', '50%'],
radius:85,
indicator : [
{ text: '荒废度', max: 100},
{ text: '沟通能力', max: 100},
{ text: '执行能力', max: 100},
{ text: '学习能力', max: 100},
{ text: '信誉度', max: 100},
]
}
]
//center: radius:85,用来换行和大小
转载于:https://www.cnblogs.com/wurui123/p/9778988.html