fix(地图): 数据为0在提示中无法展示出来

This commit is contained in:
fit2cloud-chenyw 2023-01-05 15:30:50 +08:00
parent 4cd381f9c3
commit f9e0aa188d

View File

@ -73,7 +73,7 @@ export function baseMapOption(chart_option, chart, themeStyle, curAreaCode, seri
tooltip.formatter = params => {
const a = params.seriesName
const b = params.name
const c = params.value ? params.value : ''
const c = params.value ?? ''
return text.replace(new RegExp('{a}', 'g'), a).replace(new RegExp('{b}', 'g'), b).replace(new RegExp('{c}', 'g'), c)
}
chart_option.tooltip = tooltip