浏览代码

数据中心

彭宇 2 年之前
父节点
当前提交
e90e844a8e
共有 1 个文件被更改,包括 18 次插入14 次删除
  1. 18 14
      src/components/vBottomMenu.vue

+ 18 - 14
src/components/vBottomMenu.vue

@@ -715,11 +715,11 @@ export default {
         this.eventLogList = res.data.eventlog
         this.visuForestCloudYuAnBo = res.data.visuForestCloudYuAnBo//应急预案
         if (res.data.catalogue != null && res.data.catalogue.length > 0) {
-          this.address = res.data.catalogue[0].address
-          this.eventType = res.data.catalogue[0].eventType
-          this.eventId = res.data.catalogue[0].id
-          this.longitude = res.data.catalogue[0].longitude
-          this.latitude = res.data.catalogue[0].latitude
+          this.address = res.data.catalogue.address
+          this.eventType = res.data.catalogue.eventType
+          this.eventId = res.data.catalogue.id
+          this.longitude = res.data.catalogue.longitude
+          this.latitude = res.data.catalogue.latitude
           let markersMap = {
             lng: 124.59,
             lat: 43.02,
@@ -732,28 +732,32 @@ export default {
             radius: 0
           }
 
-          if (res.data.catalogue[0].eventStatusValue == 'forest_event_status_1' && res.data.catalogue[0].urgeCount == 0) {
+          if (res.data.catalogue.eventStatusValue == 'forest_event_status_1' && res.data
+            .catalogue.urgeCount == 0) {
             markersMap.icon = 'sj-icon-map-xinshangbao'
           }
-          if (res.data.catalogue[0].eventStatusValue == 'forest_event_status_1' && res.data.catalogue[0].urgeCount > 0) {
+          if (res.data.catalogue.eventStatusValue == 'forest_event_status_1' && res.data
+            .catalogue.urgeCount > 0) {
             markersMap.icon = 'sj-icon-map-cuiban'
-          } else if (res.data.catalogue[0].eventStatusValue == 'forest_event_status_2') {
+          } else if (res.data.catalogue.eventStatusValue == 'forest_event_status_2') {
             markersMap.icon = 'sj-icon-map-qianshou'
-          } else if (res.data.catalogue[0].eventStatusValue == 'forest_event_status_5') {
+          } else if (res.data.catalogue.eventStatusValue == 'forest_event_status_5') {
             markersMap.icon = 'sj-icon-map-banjie'
-          } else if (res.data.catalogue[0].eventStatusValue == 'forest_event_status_6') {
+          } else if (res.data.catalogue.eventStatusValue == 'forest_event_status_6') {
             markersMap.icon = 'sj-icon-map-guidang'
           }
-          markersMap.lng = res.data.catalogue[0].longitude
-          markersMap.lat = res.data.catalogue[0].latitude
-          if (res.data.eventdetail != null && res.data.eventdetail.length > 0 && res.data.eventdetail[0].fireRadius != null && res.data.eventdetail[0].fireRadius != '' && res.data.eventdetail[0].fireRadius > 0) {
+          markersMap.lng = res.data.catalogue.longitude
+          markersMap.lat = res.data.catalogue.latitude
+          if (res.data.eventdetail != null && res.data.eventdetail.length > 0 && res.data
+            .eventdetail[0].fireRadius != null && res.data.eventdetail[0].fireRadius != '' && res
+            .data.eventdetail[0].fireRadius > 0) {
             markersMap.radius = res.data.eventdetail[0].fireRadius
           }
           setTimeout(() => {
             // that.$refs.supermapTaskDialog.dynamicPlotting()//弹出动态绘制窗口,防止截图位置改变
             that.$refs.supermapTaskDialog.clearM(false)
             that.$refs.supermapTaskDialog.setMarkersRadius([markersMap])
-            that.$refs.supermapTaskDialog.dropLocation10(res.data.catalogue[0].latitude, res.data.catalogue[0].longitude)
+            that.$refs.supermapTaskDialog.dropLocation10(res.data.catalogue.latitude, res.data.catalogue.longitude)
           }, 1000)
         }
       })