refactor: 明细表数值格式优化

This commit is contained in:
junjun 2022-04-19 15:56:21 +08:00
parent 61aa773a3f
commit 0e3cd4bd2d

View File

@ -64,10 +64,10 @@ export function baseTableInfo(s2, container, chart, action, tableData) {
} else {
if (f.formatterCfg) {
const v = valueFormatter(value, f.formatterCfg)
return v === 'NaN' ? value : v
return v.includes('NaN') ? value : v
} else {
const v = valueFormatter(value, formatterItem)
return v === 'NaN' ? value : v
return v.includes('NaN') ? value : v
}
}
}
@ -91,10 +91,10 @@ export function baseTableInfo(s2, container, chart, action, tableData) {
} else {
if (f.formatterCfg) {
const v = valueFormatter(value, f.formatterCfg)
return v === 'NaN' ? value : v
return v.includes('NaN') ? value : v
} else {
const v = valueFormatter(value, formatterItem)
return v === 'NaN' ? value : v
return v.includes('NaN') ? value : v
}
}
}