浏览代码

fix: 城市分布报错处理

Signed-off-by: tangshizhe <48740614+tangshizhe@users.noreply.github.com>
tangshizhe 1 年之前
父节点
当前提交
352680651c
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      src/web/staticres/common-module/report-analysis/js/report_analysis.js

+ 2 - 1
src/web/staticres/common-module/report-analysis/js/report_analysis.js

@@ -1505,7 +1505,8 @@ var vm = new Vue({
     },
     // 城市分布
     sortAreaCityScatter (areacitylist) {
-      const list = areacitylist || []
+      if(!areacitylist) return
+      const list = areacitylist
       const ZXS = ['北京', '天津', '上海', '重庆', '台湾', '澳门', '香港']
       const result  = list.reduce((max, item) => {
         const isMaxZXS = ZXS.includes(max.area)