Browse Source

Merge branch 'visu_farming_0_1' of http://121.37.83.100:3000/sooka_onest/sooka_onest_forestfire_vue2_visualization into visu_farming_0_1

whao 2 years ago
parent
commit
716fb8d297

+ 14 - 0
src/api/bigdata/bigdata.js

@@ -97,3 +97,17 @@ export function getLItianDept() {
     method: 'get',
   })
 }
+
+//热力图
+export function getRlt(param) {
+  //暂时传当年,以后再说
+  if (param == null) {
+    let myDate = new Date();
+    param = {day: myDate.getFullYear()}
+  }
+  return request({
+    url: '/center-agriculture/data/getHeatMap',
+    method: 'post',
+    data : param
+  })
+}

+ 2 - 2
src/api/event.js

@@ -64,14 +64,14 @@ export function getImgUrl(data) {
 //获取附近事件
 export function getNearEvent(longitude,latitude) {
   return request({
-    url: '/center-agriculture/VisuForestEventCenterController/getNearEvent?longitude='+latitude+"&latitude="+latitude,
+    url: '/center-agriculture/fire/getNearEvent?longitude='+longitude+"&latitude="+latitude,
     method: 'get',
   })
 }
 //获取附近摄像头
 export function getNearCamera(longitude,latitude) {
   return request({
-    url: '/center-agriculture/VisuForestEventCenterController/getNearCamera?longitude='+latitude+"&latitude="+latitude,
+    url: '/center-agriculture/monitor/getNearCamera?longitude='+longitude+"&latitude="+latitude+"&type=2",
     method: 'get',
   })
 }

+ 7 - 21
src/api/forest.js

@@ -51,24 +51,15 @@ export function getExposureStage(param) {
 }
 
 // 获取事件详情
-// export function getEventDetail(param) {
-//   return request({
-//     url: '/center-agriculture/fire/getEventDetail',
-//     method: 'post',
-//     data: param
-//   })
-// }
-
-
-// 获取事件详情
 export function getEventDetail(param) {
   return request({
-    url: '/center-fire/VisuForestCloudMapController/getEventDetail',
+    url: '/center-agriculture/fire/getEventDetail',
     method: 'post',
     data: param
   })
 }
 
+
 // 获取日历颜色状态
 export function getEventByCalendar(param) {
   return request({
@@ -112,8 +103,7 @@ export function sendEventLog(param) {
 // 事件处理流程
 export function updateCentereventTEventcatalogueStatus(param) {
   return request({
-    // url: '/center-agriculture/fire/updateCentereventTEventcatalogueStatus',
-    url: '/center-fire/VisuForestCloudMapController/updateCentereventTEventcatalogueStatus',
+    url: '/center-agriculture/fire/updateCentereventTEventcatalogueStatus',
     method: 'post',
     data: param
   })
@@ -121,8 +111,7 @@ export function updateCentereventTEventcatalogueStatus(param) {
 // 事件处理流程-事件类型
 export function listSJfl(param) {
   return request({
-    // url: '/center-agriculture/fire/listSJfl',
-    url: '/center-fire/VisuForestCloudMapController/listSJfl',
+    url: '/center-agriculture/fire/listSJfl',
     method: 'post',
     data: param
   })
@@ -130,16 +119,14 @@ export function listSJfl(param) {
 // 事件处理流程-关联预案
 export function listYuAn() {
   return request({
-    // url: '/center-agriculture/fire/listYuAn',
-    url: '/center-fire/VisuForestCloudMapController/listYuAn',
+    url: '/center-agriculture/fire/listYuAn',
     method: 'post'
   })
 }
 // 事件处理流程-签收部门
 export function selectByeventCode(eventCode) {
   return request({
-    // url: '/center-agriculture/fire/selectByeventCode/'+eventCode,
-    url: '/center-fire/VisuForestCloudMapController/selectByeventCode/'+eventCode,
+    url: '/center-agriculture/fire/selectByeventCode/'+eventCode,
     method: 'post'
   })
 }
@@ -193,8 +180,7 @@ export function refusedTask(param) {
 // 事件调整关联预案
 export function updateYjYuAn(param) {
   return request({
-    // url: '/center-agriculture/fire/updateYjYuAn',
-    url: '/center-fire/VisuForestCloudMapController/updateYjYuAn',
+    url: '/center-agriculture/fire/updateYjYuAn',
     method: 'post',
     data:param
   })

File diff suppressed because it is too large
+ 755 - 888
src/components/eventLocation.vue


File diff suppressed because it is too large
+ 708 - 786
src/components/vBottomMenu.vue


+ 3 - 3
src/views/animal.vue

@@ -70,7 +70,7 @@
                 <img src="@/assets/images/visual/img-sample.png" class="event-list-img animal-img">
                 <div class="event-list-text">
                   <h3>{{ item.eventTitle }}</h3>
-                  <h4><span>摄像头</span><span>新上报</span><span>{{ item.reportTime }}</span>
+                  <h4><span>摄像头</span><span>新上报</span><span>{{ item.createTime }}</span>
                   </h4>
                 </div>
               </div>
@@ -295,7 +295,7 @@ export default {
               '<span>' +
               '                  <div class="d-l-con">' +
               '                  <div class="d-l-l-text">' +
-              '                  <h4>事件时间:' + res.data.visuForestVgdEventBOList[i].reportTime +
+              '                  <h4>事件时间:' + res.data.visuForestVgdEventBOList[i].createTime +
               '</h4>' +
               '                </div>' +
               '                </div>' +
@@ -365,7 +365,7 @@ export default {
               '<span>' +
               '                  <div class="d-l-con">' +
               '                  <div class="d-l-l-text">' +
-              '                  <h4>事件时间:' + res.data.visuForestVgdEventBOList[i].reportTime +
+              '                  <h4>事件时间:' + res.data.visuForestVgdEventBOList[i].createTime +
               '</h4>' +
               '                </div>' +
               '                </div>' +

+ 28 - 15
src/views/bigdata/bigdata.vue

@@ -52,9 +52,9 @@
           <div class="twins">
             <div class="count">
               <div class="count-z m-l-15">事件总数<span>{{total}}</span></div>
-              <div class="count-z m-l-15">上报<span> {{escalation}}</span></div>
               <div class="count-z m-l-15">签收<span> {{signIn}}</span></div>
               <div class="count-z m-l-15">办结<span> {{conclude}}</span></div>
+              <div class="count-z m-l-15">归档<span> {{file}}</span></div>
             </div>
             <chartEvent ref="chartEvent"></chartEvent>
           </div>
@@ -149,7 +149,7 @@
   import bigdataSupermap from '@/components/supermap' //超图
 
   import {cooperativesBigData,machineryInfoBigData,landInfoBigData
-    ,eventcatalogueBigData,deptBigData
+    ,eventcatalogueBigData,getRlt,deptBigData
     ,leidaBigData,protectInfoBigData,xubaoBigData
     ,zhongZiBigData,huaFeiBigData,YangZhiBigData
     ,getHuanTianDept,getHuanTianType,getLItianDept
@@ -184,6 +184,7 @@
       this.machineryInfoBigData();
       this.landInfoBigData();
       this.eventcatalogueBigData();
+      this.getRlt();
       this.leidaBigData();
       this.protectInfoBigData();
       this.xubaoBigData();
@@ -195,9 +196,9 @@
       this.getLItianDept();
     },
     mounted() {
-      setTimeout(() => {
-        this.$refs.bigdataSupermap.loadHeatMap()//事件分布
-      }, 5000)
+      // setTimeout(() => {
+      //   this.$refs.bigdataSupermap.loadHeatMap()//事件分布
+      // }, 5000)
     },
 		data() {
 			return {
@@ -221,7 +222,7 @@
 					},
 				],
 				total: 0, //事件总数
-        escalation:0,// 事件-上报
+        file:0,// 事件-归档
         signIn:0,// 事件-签收
         conclude:0,// 事件-办结
 
@@ -251,24 +252,36 @@
           this.$refs.chartFireControl.myEcharts(xData,seriesData);
         })
       },
+
+      /**事件类型、分布统计*/
       eventcatalogueBigData() {
         eventcatalogueBigData().then(res => {
-          for (let index in res.data) {
-            this.total+=parseInt(res.data[index].value);
-            if(res.data[index].dictValue == 'forest_event_status_1'){
-              this.escalation=res.data[index].value;
-            }else if(res.data[index].dictValue == 'forest_event_status_2'){
-              this.signIn=res.data[index].value;
-            }else if(res.data[index].dictValue == 'forest_event_status_5'){
-              this.conclude=res.data[index].value;
+          this.total = res.data.total;
+          for (let index in res.data.list) {
+            if(res.data.list[index].dictValue == 'forest_event_status_2'){
+              this.signIn=res.data.list[index].value;
+            }else if(res.data.list[index].dictValue == 'forest_event_status_5'){
+              this.conclude=res.data.list[index].value;
+            }else if(res.data.list[index].dictValue == 'forest_event_status_6'){
+              this.file=res.data.list[index].value;
             }
           }
-          this.$refs.chartEvent.myEcharts(res.data);
+          this.$refs.chartEvent.myEcharts(res.data.list);
         })
         deptBigData().then(res => {
           this.$refs.chartEvent.myEcharts2(res.data);
         })
       },
+
+
+      getRlt() {
+        getRlt().then(resp => {
+          setTimeout(() => {
+            //事件分布
+            this.$refs.bigdataSupermap.loadHeatMap(resp.data);
+          }, 5000)
+        })
+      },
       leidaBigData() {
         leidaBigData().then(res => {
           const seriesData = [0,0,0,0,0];

+ 2 - 0
src/views/bigdata/chart-farm.vue

@@ -57,6 +57,8 @@
 				        },
 				        axisLabel: {
 				            show: true,
+                  interval: 0,
+                  rotate: 20,
 				            margin: 14,
 				            fontSize: 10,
 				            textStyle: {

+ 6 - 10
src/views/datacenter.vue

@@ -341,19 +341,19 @@ export default {
         const resourcesMap = res.data;
         for(let key in resourcesMap){
           const map = {};
+          map.count=resourcesMap[key];
           if(key == 'buzhu'){map.name="补助次数";}
-          if(key == 'gengdi'){map.name="耕地面积";}
+          if(key == 'gengdi'){map.name="耕地面积";map.count=resourcesMap[key]+"㎡";}
           if(key == 'hezuoshe'){map.name="合作社数量";}//有经纬度
-          if(key == 'huafei'){map.name="化肥库存";}
+          if(key == 'huafei'){map.name="化肥库存";map.count=resourcesMap[key]+"吨";}
           if(key == 'nongji'){map.name="农机站数量";}//有经纬度
-          if(key == 'nongju'){map.name="农具库存";}
+          if(key == 'nongju'){map.name="农具库存";map.count=resourcesMap[key]+"个";}
           if(key == 'xubao'){map.name="畜保站数量";}//有经纬度
           if(key == 'yangzhi'){map.name="养殖及粪污处理点";}//有经纬度
           if(key == 'zhibao'){map.name="植保数量";}//有经纬度
-          if(key == 'zhongzhi'){map.name="种植产量";}
-          if(key == 'zhongzi'){map.name="种子库存";}
+          if(key == 'zhongzhi'){map.name="种植产量";map.count=resourcesMap[key]+"吨";}
+          if(key == 'zhongzi'){map.name="种子库存";map.count=resourcesMap[key]+"吨";}
           map.icon='sj-icon-'+key;
-          map.count=resourcesMap[key];
           map.key=key;
           that.resourcesList.push(map);
         }
@@ -381,8 +381,6 @@ export default {
               let markersMap = {
                 lng: res.data.list[i].longitude,
                 lat: res.data.list[i].latitude,
-                // lng: 124.391266,
-                // lat: 43.318594,
                 icon: 'marker',
                 bindPopupHtml: '' +
                   '<div class="map-tip">' +
@@ -436,8 +434,6 @@ export default {
               let markersMap = {
                 lng: res.data[i].longitude,
                 lat: res.data[i].latitude,
-                // lng: 124.391266,
-                // lat: 43.318594,
                 icon: 'marker',
                 bindPopupHtml: '' +
                   '<div class="map-tip">' +

File diff suppressed because it is too large
+ 570 - 570
src/views/eventdetailsdialog.vue


+ 8 - 8
src/views/forest.vue

@@ -18,7 +18,7 @@
             <div class="i-list-con h-14">
               <div class="d-l-con no_hover">
                 <div class="d-l-l-text w-100p">
-                  <h4 class="line-h-1 w-100p">{{ forestInfo }}</h4>
+                  <h4 class="line-h-1 w-100p" v-html="forestInfo">{{ forestInfo }}</h4>
                 </div>
               </div>
             </div>
@@ -278,11 +278,11 @@
                   </el-input>
                 </div>
                 <div class="d-l-con padding-box nowrap" v-for="(item,index) in eventList"
-                     @click="dropLocation(item.latitude,item.longitude)">
+                     @click="dropLocation(item.latitude,item.longitude)" data-html2canvas-ignore>
                   <div class="bgt-img">
                     <img v-if="item.picturePath!=null&&item.picturePath!=''&& isAssetTypeAnImage(item.picturePath)"
                          :src="item.picturePath"
-                         style="width: 93px;height: 64px"/>
+                         style="width: 93px;height: 64px"  loading="lazy"/>
                     <img v-else src="../assets/images/integrated/event-img-sub.png" style="width: 93px;height: 64px"/>
                   </div>
                   <div class="bgt-info">
@@ -332,7 +332,7 @@
                     <div class="bgt-info-name">{{ item.reportor }} {{ item.eventName }}</div>
                     <div class="bgt-info-place">
                       <ul>
-                        <li>{{ item.reportTime }}</li>
+                        <li>{{ item.createTime }}</li>
                       </ul>
                     </div>
                   </div>
@@ -405,7 +405,7 @@ import {
   getEventList,
   getEventByEventType,
   getEventByReportorOrder,
-  getExposureStage
+  // getExposureStage
 } from '@/api/forest'
 import supermap from '@/components/supermap' //超图
 import supermapNotProcessed from '@/components/supermap' //超图
@@ -457,7 +457,7 @@ export default {
     this.getEventList(this.getCurrentDataStr())
     this.getEventByEventType(this.getCurrentDataStr())
     this.getEventByReportorOrder(this.getCurrentDataStr())
-    this.getExposureStage(this.getCurrentDataStr())
+    // this.getExposureStage(this.getCurrentDataStr())
     /** ----------------------------------weosocket开始------------------------------------- */
     // this.initWebSocket()
     /** ----------------------------------weosocket结束------------------------------------- */
@@ -603,7 +603,7 @@ export default {
             '<span>' +
             '                  <div class="d-l-con">' +
             '                  <div class="d-l-l-text">' +
-            '                  <h4>事件时间:' + this.eventList[i].reportTime + '</h4>' +
+            '                  <h4>事件时间:' + this.eventList[i].createTime + '</h4>' +
             '                </div>' +
             '                </div>' +
             '                </span>'
@@ -963,7 +963,7 @@ export default {
               '<span>' +
               '                  <div class="d-l-con">' +
               '                  <div class="d-l-l-text">' +
-              '                  <h4>事件时间:' + this.eventList[i].reportTime + '</h4>' +
+              '                  <h4>事件时间:' + this.eventList[i].createTime + '</h4>' +
               '                </div>' +
               '                </div>' +
               '                </span>'

+ 11 - 8
src/views/monitor.vue

@@ -279,12 +279,21 @@ export default {
         },
         grid: {
           top: '5%',
-          left: '2%',
+          left: '5%',
           // right: "4%",
-          bottom: '-15%',
+          bottom: '0%',
           width: '75%',
           containLabel: true
         },
+        dataZoom: [{
+          show:true,
+          type: 'slider',
+          yAxisIndex:0,
+          left:10,
+          start: 0,
+          end: this.sourceData.length > 10 ? 40 : 100,
+          width:15
+        }],
         xAxis: {
           show: false,
           type: 'value'
@@ -402,9 +411,6 @@ export default {
               keepBindPopup: false,
               isAggregation: false
             }
-            if (res.data.visuForestCloudCameraBOList.length > 50) {
-              markersMap.isAggregation = true
-            }
             if (res.data.visuForestCloudCameraBOList[i].channelCode != null) {
               markersMap.parameter = res.data.visuForestCloudCameraBOList[i].cameraCode
             } else {
@@ -483,9 +489,6 @@ export default {
               keepBindPopup: false,
               isAggregation: false
             }
-            if (res.data.length > 50) {
-              markersMap.isAggregation = true
-            }
             if (res.data[i].channelCode != null) {
               markersMap.parameter = res.data[i].cameraCode
             } else {