NEZ-2057 fix:hexagon valueMapping 使用变量未正确转化

This commit is contained in:
zhangyu
2022-07-22 17:11:37 +08:00
parent f30ad4cbbd
commit ef1699f1de

View File

@@ -127,6 +127,7 @@ export default {
...item,
x: colIndex,
y: rowIndex,
metrics: item.label,
label: item.legend
}
})
@@ -250,10 +251,10 @@ export default {
const textColor = point.mapping ? point.mapping.color.text : this.invertColor(color)
if (this.chartInfo.param.text === 'all') {
str += point.alias
valueStr = point.mapping && point.mapping.display ? self.handleDisplay(point.mapping.display, { ...point.labels, value: point.showValue }) : point.showValue
valueStr = point.mapping && point.mapping.display ? self.handleDisplay(point.mapping.display, { ...point.metrics, value: point.showValue }) : point.showValue
}
if (this.chartInfo.param.text === 'value' || !this.chartInfo.param.text) {
valueStr = point.mapping && point.mapping.display ? self.handleDisplay(point.mapping.display, { ...point.labels, value: point.showValue }) : point.showValue
valueStr = point.mapping && point.mapping.display ? self.handleDisplay(point.mapping.display, { ...point.metrics, value: point.showValue }) : point.showValue
}
if (this.chartInfo.param.text === 'legend') {
str += point.alias