Selaa lähdekoodia

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

whao 3 vuotta sitten
vanhempi
commit
989f4ec441
1 muutettua tiedostoa jossa 61 lisäystä ja 4 poistoa
  1. 61 4
      src/views/event.vue

+ 61 - 4
src/views/event.vue

@@ -694,8 +694,7 @@
           this.deptId = ''
           this.eventType = ''
           this.deptName = ''
-          this.eventShow = false
-          this.getList();
+          this.eventInfoVisible_notProcessed = false
           cancelEventShow();
         })
       },
@@ -707,8 +706,7 @@
         updateCentereventTForestfireStatus(this.id, this.eventStatus).then(response => {
           this.$modal.msgSuccess(response.msg)
           this.eventStatus=''
-          this.eventShow = false
-          this.getList();
+          this.eventInfoVisible_Processed = false
           cancelEventShow();
         })
 
@@ -981,6 +979,65 @@
 
           }
           this.eventChart()
+
+          that.markersList = [];
+          that.eventList = [];
+          if(res.data.eventListAll!=null&&res.data.eventListAll.length>0){
+            for (let i = 0; i < res.data.eventListAll.length; i++) {
+              let markersMap = {
+                lng: 124.59,
+                lat: 43.02,
+                icon: 'marker',
+                bindPopupHtml: '',
+                click: '',
+                parameter: '',
+                keepBindPopup: false,
+                isAggregation: false
+              }
+              if(res.data.eventListAll.length>500){
+                markersMap.isAggregation = true
+              }
+              if(res.data.eventListAll[i].eventStatus=="event_event_status_1"||res.data.eventListAll[i].eventStatus=="event_event_status_2"||res.data.eventListAll[i].eventStatus=="event_event_status_6"){
+                markersMap.click = "showEventInfo_Processed"
+              }else if(res.data.eventListAll[i].eventStatus=="event_event_status_4"){
+                markersMap.click = "showEventInfo_notProcessed"
+              }
+              markersMap.parameter = res.data.eventListAll[i].id
+              markersMap.lng = res.data.eventListAll[i].longitude
+              markersMap.lat =res.data.eventListAll[i].latitude
+              markersMap.bindPopupHtml = '<div class="map-tip">' +
+                '<span>' +
+                '                  <div class="d-l-con">' +
+                '                  <div class="d-l-l-text">' +
+                '                  <h4>经纬度:' +res.data.eventListAll[i].longitude + ',' +res.data.eventListAll[i]
+                  .latitude + '</h4>' +
+                '                </div>' +
+                '                </div>' +
+                '                </span>' +
+                '<span>' +
+                '                  <div class="d-l-con">' +
+                '                  <div class="d-l-l-text">' +
+                '                  <h4>事件名称:' +res.data.eventListAll[i].eventTitle + '</h4>' +
+                '                </div>' +
+                '                </div>' +
+                '                </span>' +
+                '<span>' +
+                '                  <div class="d-l-con">' +
+                '                  <div class="d-l-l-text">' +
+                '                  <h4>事件时间:' +res.data.eventListAll[i].reportTime + '</h4>' +
+                '                </div>' +
+                '                </div>' +
+                '                </span>' +
+                '</div>';
+              that.markersList.push(markersMap)
+            }
+            that.eventList=res.data.eventListAll;
+            setTimeout(() => {
+              that.$refs.supermap.clearM(false)
+              that.$refs.supermap.clearM(true)
+              that.$refs.supermap.setMarkers(that.markersList)
+            },1000)
+          }
         })
       },
       todayEventCountSetMarkers(eventStatus) {