Browse Source

Merge branch 'master' of http://121.37.83.100:3000/sooka_onest/sooka_onest_forestfire_vue2_visualization

whao 2 years ago
parent
commit
bfbd4f602e
1 changed files with 17 additions and 16 deletions
  1. 17 16
      src/views/disaster.vue

+ 17 - 16
src/views/disaster.vue

@@ -481,6 +481,7 @@
 		this.listCurrentIndex = index
         let that = this
         selectFireLoseByid(id).then(res => {
+          this.graphicsList=[]
           //地图标记
           if (res.data.regionalFlagBOList != null && res.data.regionalFlagBOList.length > 0) {
             for (let i = 0; i < res.data.regionalFlagBOList.length; i++) {
@@ -529,22 +530,22 @@
         //获取左侧菜单列表
         getInit(this.pickYear.getYear() + 1900).then(res => {
           this.fireList = []
-          //地图标记
-          if (res.data.regionalFlagBOList != null && res.data.regionalFlagBOList.length > 0) {
-            for (let i = 0; i < res.data.regionalFlagBOList.length; i++) {
-              let latlng = {
-                lat: res.data.regionalFlagBOList[i].latitude,
-                lng: res.data.regionalFlagBOList[i].longitude
-              }
-              this.graphicsList.push(latlng)
-            }
-            setTimeout(() => {
-              that.$refs.supermap.clearG()
-              that.$refs.supermap.setGraphicsList(this.graphicsList, 'red')
-            }, 1000)
-          }else {
-            that.$refs.supermap.clearG()
-          }
+          // //地图标记
+          // if (res.data.regionalFlagBOList != null && res.data.regionalFlagBOList.length > 0) {
+          //   for (let i = 0; i < res.data.regionalFlagBOList.length; i++) {
+          //     let latlng = {
+          //       lat: res.data.regionalFlagBOList[i].latitude,
+          //       lng: res.data.regionalFlagBOList[i].longitude
+          //     }
+          //     this.graphicsList.push(latlng)
+          //   }
+          //   setTimeout(() => {
+          //     that.$refs.supermap.clearG()
+          //     that.$refs.supermap.setGraphicsList(this.graphicsList, 'red')
+          //   }, 1000)
+          // }else {
+          //   that.$refs.supermap.clearG()
+          // }
 
           //右侧列表
           if (res.data.visuForestFireLossTimeBOList != null && res.data.visuForestFireLossTimeBOList.length > 0) {