CN-820 fix: 修复地图报错问题

This commit is contained in:
chenj
2022-12-01 16:56:30 +08:00
parent 0f600b44ac
commit e3422757a2

View File

@@ -99,13 +99,12 @@ export default {
}
if (params.type === 'serverIp' || params.type === 'clientIp') params.type = 'ip'
getData(api.npm.overview.map, params).then(res => {
this.showError = false
if (res && res.length > 0) {
const subParams = {
...params,
params: res.map(r => `'${r.country}'`).join(',')
}
this.showError = false
// 计算分数
const tcpRequest = get(api.npm.overview.mapTcp, subParams)
const httpRequest = get(api.npm.overview.mapHttp, subParams)
@@ -141,6 +140,7 @@ export default {
})
this.loadMarkerData(imageSeries, mapData)
})
}
}).catch(e => {
this.showError = true
this.errorMsg = e.message