瀏覽代碼

林业页面提交

wang_xy 2 年之前
父節點
當前提交
9cb81c2cce

+ 23 - 0
src/api/animal.js

@@ -14,3 +14,26 @@ export function selectForestAnimalListByType(type) {
     method: 'get',
   })
 }
+
+/**
+ * 野生动物分布统计
+ * @param type
+ */
+export function selectAnimalCountByType() {
+  return request({
+    url: '/center-fire/VisuForestAnimalController/selectAnimalCountByType',
+    method: 'post',
+    data:{}
+  })
+}
+/**
+ * 野生动物台账
+ * @param type
+ */
+export function getAnimalRemotelist(type) {
+  return request({
+    url: '/center-fire/VisuForestAnimalController/getAnimalRemotelist',
+    method: 'post',
+    data:{type:type}
+  })
+}

+ 5 - 2
src/api/event.js

@@ -1,10 +1,13 @@
 import request from '@/utils/request'
 
 //获取附近事件
-export function getNearEvent(longitude,latitude) {
+export function getNearEvent(longitude,latitude,day,loading) {
   return request({
-    url: '/center-fire/VisuForestEventCenterController/getNearEvent?longitude='+longitude+"&latitude="+latitude,
+    url: '/center-fire/VisuForestEventCenterController/getNearEvent?longitude='+longitude+"&latitude="+latitude+"&day="+day,
     method: 'get',
+    headers: {
+      loading: loading
+    },
   })
 }
 //获取附近摄像头

+ 0 - 1
src/api/forest.js

@@ -38,7 +38,6 @@ export function getWeather(param) {
   })
 }
 
-
 // 右侧获取事件列表
 export function getEventList(param,loading) {
   return request({

+ 9 - 0
src/api/leader.js

@@ -22,6 +22,15 @@ export function getLeaderTrack(trackById) {
     method: 'get',
   })
 }
+
+// 点击左侧人员获取人员的巡林计划
+export function getRemotelist() {
+  return request({
+    url: '/center-fire/VisuForestLeaderController/getRemotelist',
+    method: 'get',
+  })
+}
+
 // 巡林计划
 export function getPlanList(trackById) {
   return request({

+ 35 - 0
src/api/trees.js

@@ -0,0 +1,35 @@
+import request from '@/utils/request'
+
+/**
+ * 珍惜古树分布统计
+ * @param type
+ */
+export function selectCenterdataTForestTreesGroupByType(type) {
+  return request({
+    url: '/center-fire/VisuForestFireTreesController/selectCenterdataTForestTreesGroupByType',
+    method: 'get',
+  })
+}
+
+/**
+ * 珍惜古树列表
+ * @param type
+ */
+export function getTreesRemoteList(treesSpecies) {
+  return request({
+    url: '/center-fire/VisuForestFireTreesController/getTreesRemoteList',
+    method: 'post',
+    data: {treesSpecies:treesSpecies}
+  })
+}
+
+/**
+ * 珍惜古树详情
+ * @param type
+ */
+export function getTreesDetail(id) {
+  return request({
+    url: '/center-fire/VisuForestFireTreesController/getTreesDetail/'+id,
+    method: 'get',
+  })
+}

+ 1 - 1
src/components/v-fastmenu.vue

@@ -75,7 +75,7 @@ import { getUserProfile } from "@/api/system/user";
         let mo = href.lastIndexOf(":") > 6  ? href.lastIndexOf(":") : href.lastIndexOf("/")
         let ip = href.substr(href.indexOf("://")+3,mo);
         let url =href.substr(0,mo)
-        let toUrl = url +":15001/index58"
+        let toUrl = url +":15001/newpage"
         window.location.href = toUrl
       },
       getUser(){

+ 16 - 16
src/router/index.js

@@ -82,19 +82,19 @@ export const constantRoutes = [{
 			title: '植树造林'
 		}
 	},
-  // {
-  //   path: '/',
-  //   name: '',
-  //   component: () => import('@/views/animal'),
-  //   meta: {
-  //     title: '动物保护'
-  //   }
-  // },
   {
-    path: '/',
-    name: '',
+    path: '/animal',
+    name: 'animal',
     component: () => import('@/views/animal'),
     meta: {
+      title: '野生动物'
+    }
+  },
+  {
+    path: '/trees',
+    name: 'trees',
+    component: () => import('@/views/trees'),
+    meta: {
       title: '珍惜古树'
     }
   },
@@ -167,17 +167,17 @@ export const constantRoutesNew = [{
 		}
 	},
   {
-    path: '/',
-    name: '',
+    path: '/animal',
+    name: 'animal',
     component: () => import('@/views/animal'),
     meta: {
-      title: '动物保护'
+      title: '野生动物'
     }
   },
   {
-    path: '/',
-    name: '',
-    component: () => import('@/views/animal'),
+    path: '/trees',
+    name: 'trees',
+    component: () => import('@/views/trees'),
     meta: {
       title: '珍惜古树'
     }

+ 91 - 145
src/views/animal.vue

@@ -10,24 +10,22 @@
           <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
             <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
             <div class="i-list-con h-78">
-              <div class="d-l-con-icon">
-                <div class="icon-con  m-btm-no icon-animal-con" :class="animalcount" @click="getInit()">
-                  <!--   -->
-                  <!--<div class="icon icon-dot"></div>-->
-                  <div class="icon-text animal-text">
-                    <h6>9</h6>
-                    <h5>总数</h5>
-                  </div>
-                </div>
-              </div>
+              <!--<div class="d-l-con-icon">-->
+                <!--<div class="icon-con  m-btm-no icon-animal-con" :class="animalcount">-->
+                  <!--<div class="icon-text animal-text">-->
+                    <!--<h6>9</h6>-->
+                    <!--<h5>总数</h5>-->
+                  <!--</div>-->
+                <!--</div>-->
+              <!--</div>-->
               <div class="d-l-con-icon">
                 <div class="icon-con icon-animal-con" :class="{on:iconCurrentIndex1==item.type}"
-                     v-for="(item,index) in animalDwfb" @click="selectForestAnimalListByType(item.type)">
+                     v-for="(item,index) in animalDwfb" @click="getAnimalRemotelist(item.type)">
                   <div class="iconfont icon icon-normal icon-animal">
                     <img :src="item.src">
                   </div>
                   <div class="icon-text icon-animal-text">
-                    <h5>{{ item.name }}</h5>
+                    <h5>{{ item.name }}:{{item.value}}</h5>
                   </div>
                 </div>
               </div>
@@ -41,44 +39,44 @@
       <!--      <button @click="showEventInfo1" style="position: absolute; right: 50%;top: 45%;z-index: 1000;">弹层事件演示用按钮-->
       <!--      </button>-->
       <!-- 右侧 -->
-      <div class="rightbar" :class="indentright" ref="right">
-        <div class="forthis">
-          <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
-            <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
-            <div class="this-title">
-              <span>事件分布</span>
-              <dv-decoration-3 style="width:150px;height:15px;margin-right: 1rem;"/>
-            </div>
-            <div class="i-list-con h-73">
-              <div class="d-l-con-icon">
-                <div class="h-19 overflow-y w100">
-                  <div class="d-l-con" v-for="(item,index) in animalSjfb">
-                    <div class="d-l-l-text">
-                      <i class="i-small"></i>
-                      <h4>{{ item.deptName }}</h4>
-                    </div>
-                    <div class="d-l-l-count">{{ item.count }}</div>
-                  </div>
-                </div>
-              </div>
-              <div class="d-l-con">
-                <div id="animal-chart" style="width: 100%;height:26.2vh;"></div>
-              </div>
-              <div class="d-l-con d-evnet-list-con" :class="{on:listCurrentIndex1==index}"
-                   v-for="(item,index) in animalSjlb"
-                   @click="dropLocation(item.latitude,item.longitude,index)">
-                <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.createTime }}</span>
-                  </h4>
-                </div>
-              </div>
-            </div>
-          </dv-border-box-13>
-        </div>
+      <!--<div class="rightbar" :class="indentright" ref="right">-->
+        <!--<div class="forthis">-->
+          <!--<dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">-->
+            <!--<img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>-->
+            <!--<div class="this-title">-->
+              <!--<span>事件分布</span>-->
+              <!--<dv-decoration-3 style="width:150px;height:15px;margin-right: 1rem;"/>-->
+            <!--</div>-->
+            <!--<div class="i-list-con h-73">-->
+              <!--<div class="d-l-con-icon">-->
+                <!--<div class="h-19 overflow-y w100">-->
+                  <!--<div class="d-l-con" v-for="(item,index) in animalSjfb">-->
+                    <!--<div class="d-l-l-text">-->
+                      <!--<i class="i-small"></i>-->
+                      <!--<h4>{{ item.deptName }}</h4>-->
+                    <!--</div>-->
+                    <!--<div class="d-l-l-count">{{ item.count }}</div>-->
+                  <!--</div>-->
+                <!--</div>-->
+              <!--</div>-->
+              <!--<div class="d-l-con">-->
+                <!--<div id="animal-chart" style="width: 100%;height:26.2vh;"></div>-->
+              <!--</div>-->
+              <!--<div class="d-l-con d-evnet-list-con" :class="{on:listCurrentIndex1==index}"-->
+                   <!--v-for="(item,index) in animalSjlb"-->
+                   <!--@click="dropLocation(item.latitude,item.longitude,index)">-->
+                <!--<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.createTime }}</span>-->
+                  <!--</h4>-->
+                <!--</div>-->
+              <!--</div>-->
+            <!--</div>-->
+          <!--</dv-border-box-13>-->
+        <!--</div>-->
 
-      </div>
+      <!--</div>-->
       <vBottomMenu ref="bottomMenu"></vBottomMenu>
 <!--      <el-tooltip :content="indentText" placement="top" :disabled="indentdisabled">-->
 <!--        <div class="mascot" ref="mascot" :class="indentStyle" @click="indent"><img-->
@@ -95,7 +93,9 @@
 <script>
 import {
   getInit,
-  selectForestAnimalListByType
+  selectForestAnimalListByType,
+  getAnimalRemotelist,
+  selectAnimalCountByType
 } from '@/api/animal'
 
 import supermap from '@/components/supermap' //超图
@@ -126,7 +126,7 @@ export default {
       indentdisabled: false,
 
       //虚拟数据
-      animalDwfb: [{
+      animalDwfbType: [{
         name: '虎',
         src: require('../assets/images/dwbh/hu-1.png'),
         type: 'forest_animal_hu'
@@ -163,6 +163,7 @@ export default {
         src: require('../assets/images/dwbh/paozi-1.png'),
         type: 'forest_animal_paozi'
       }],
+      animalDwfb:[],
       animalSjfb: [],
       animalSjlb: [],
       markersList: [] //点位列表
@@ -176,7 +177,9 @@ export default {
     /** ----------------------------------底部按钮公用组件结束------------------------------------- */
   },
   mounted() {
-    this.getInit()
+    // this.getInit();
+    this.getAnimalRemotelist();
+    this.selectAnimalCountByType();
   },
   methods: {
     /** ----------------------------------底部按钮公用组件开始------------------------------------- */
@@ -241,94 +244,29 @@ export default {
       this.$refs.supermap.layerSwitchingList(urlList)
     },
     /** ----------------------------------底部按钮公用组件结束------------------------------------- */
-    dropLocation(lat, lng, index) {
-      this.listCurrentIndex1 = index
-      this.$refs.supermap.dropLocation(lat, lng)
-    },
-    //初始化
-    getInit() {
-      this.iconCurrentIndex1 = ''
-      this.animalcount = 'on'
-      let that = this
-      //获取左侧菜单列表
-      getInit().then(res => {
-        this.animalSjfb = res.data.visuForestAnimalBOList
-        this.animalSjlb = res.data.visuForestVgdEventBOList
-
-        that.markersList = []
-        if (res.data.visuForestVgdEventBOList != null && res.data.visuForestVgdEventBOList.length >
-          0) {
-          for (let i = 0; i < res.data.visuForestVgdEventBOList.length; i++) {
-            let markersMap = {
-              lng: 124.59,
-              lat: 43.02,
-              icon: 'marker',
-              bindPopupHtml: '',
-              click: '',
-              parameter: '',
-              keepBindPopup: false,
-              isAggregation: false
-            }
-            if (res.data.visuForestVgdEventBOList.length > 50) {
-              markersMap.isAggregation = true
+    selectAnimalCountByType(){
+      selectAnimalCountByType().then(res => {
+        for (let i = 0; i < res.data.length; i++) {
+          for (let j = 0; j < this.animalDwfbType.length; j++) {
+            if(res.data[i].typeValue == this.animalDwfbType[j].name){
+              this.animalDwfb.push({
+                name: res.data[i].typeValue,
+                src: this.animalDwfbType[j].src,
+                type: this.animalDwfbType[j].type,
+                value: res.data[i].count,
+              })
             }
-            markersMap.lng = res.data.visuForestVgdEventBOList[i].longitude
-            markersMap.lat = res.data.visuForestVgdEventBOList[i].latitude
-            markersMap.bindPopupHtml = '<div class="map-tip">' +
-              '<span>' +
-              '                  <div class="d-l-con">' +
-              '                  <div class="d-l-l-text">' +
-              '                  <h4>经纬度:' + res.data.visuForestVgdEventBOList[i].longitude +
-              ',' + res.data.visuForestVgdEventBOList[i]
-                .latitude + '</h4>' +
-              '                </div>' +
-              '                </div>' +
-              '                </span>' +
-              '<span>' +
-              '                  <div class="d-l-con">' +
-              '                  <div class="d-l-l-text">' +
-              '                  <h4>事件名称:' + res.data.visuForestVgdEventBOList[i].eventTitle +
-              '</h4>' +
-              '                </div>' +
-              '                </div>' +
-              '                </span>' +
-              '<span>' +
-              '                  <div class="d-l-con">' +
-              '                  <div class="d-l-l-text">' +
-              '                  <h4>事件时间:' + res.data.visuForestVgdEventBOList[i].createTime +
-              '</h4>' +
-              '                </div>' +
-              '                </div>' +
-              '                </span>' +
-              '</div>'
-            that.markersList.push(markersMap)
           }
-          setTimeout(() => {
-            that.$refs.supermap.clearM(false)
-            that.$refs.supermap.clearM(true)
-            that.$refs.supermap.setMarkers(that.markersList)
-          }, 1000)
-        } else {
-          setTimeout(() => {
-            that.$refs.supermap.clearM(false)
-            that.$refs.supermap.clearM(true)
-          }, 1000)
         }
+
       })
     },
-
-    selectForestAnimalListByType(type) {
-      this.iconCurrentIndex1 = type
-      this.animalcount = ''
-      let that = this
-      //获取左侧菜单列表
-      selectForestAnimalListByType(type).then(res => {
-        this.animalSjfb = res.data.visuForestAnimalBOList
-        this.animalSjlb = res.data.visuForestVgdEventBOList
+    getAnimalRemotelist(type){
+      let that = this;
+      getAnimalRemotelist(type).then(res => {
         that.markersList = []
-        if (res.data.visuForestVgdEventBOList != null && res.data.visuForestVgdEventBOList.length >
-          0) {
-          for (let i = 0; i < res.data.visuForestVgdEventBOList.length; i++) {
+        if (res.data != null && res.data.length > 0) {
+          for (let i = 0; i < res.data.length; i++) {
             let markersMap = {
               lng: 124.59,
               lat: 43.02,
@@ -339,25 +277,29 @@ export default {
               keepBindPopup: false,
               isAggregation: false
             }
-            if (res.data.visuForestVgdEventBOList.length > 50) {
-              markersMap.isAggregation = true
+            let src= "";
+            for (let j = 0; j < that.animalDwfbType.length; j++) {
+              if(res.data[i].type == that.animalDwfbType[j].name){
+                // markersMap.icon = that.animalDwfb[j].type;
+                src = that.animalDwfbType[j].src;
+                break;
+              }
             }
-            markersMap.lng = res.data.visuForestVgdEventBOList[i].longitude
-            markersMap.lat = res.data.visuForestVgdEventBOList[i].latitude
+            markersMap.lng = res.data[i].longitude
+            markersMap.lat = res.data[i].latitude
             markersMap.bindPopupHtml = '<div class="map-tip">' +
               '<span>' +
               '                  <div class="d-l-con">' +
               '                  <div class="d-l-l-text">' +
-              '                  <h4>经纬度:' + res.data.visuForestVgdEventBOList[i].longitude +
-              ',' + res.data.visuForestVgdEventBOList[i]
-                .latitude + '</h4>' +
+              '                  <h4>动物名称:' + res.data[i].type +
+              '</h4>' +
               '                </div>' +
               '                </div>' +
               '                </span>' +
               '<span>' +
               '                  <div class="d-l-con">' +
               '                  <div class="d-l-l-text">' +
-              '                  <h4>事件名称:' + res.data.visuForestVgdEventBOList[i].eventTitle +
+              '                  <h4>事件时间:' + res.data[i].createTime +
               '</h4>' +
               '                </div>' +
               '                </div>' +
@@ -365,11 +307,10 @@ export default {
               '<span>' +
               '                  <div class="d-l-con">' +
               '                  <div class="d-l-l-text">' +
-              '                  <h4>事件时间:' + res.data.visuForestVgdEventBOList[i].createTime +
-              '</h4>' +
+              '<img src="' + src + '" style="width: 150px;height: 100px"/>' +
               '                </div>' +
               '                </div>' +
-              '                </span>' +
+              '                </span>'
               '</div>'
             that.markersList.push(markersMap)
           }
@@ -387,6 +328,11 @@ export default {
       })
     },
 
+    dropLocation(lat, lng, index) {
+      this.listCurrentIndex1 = index
+      this.$refs.supermap.dropLocation(lat, lng)
+    },
+
     //事件chart
     eventChart() {
       // 基于准备好的dom,初始化echarts实例

+ 2 - 2
src/views/eventdetailsdialog.vue

@@ -1693,7 +1693,7 @@ export default {
               that.refreshEvent(that.eventCode)
               that.cancelEventConfirm_send()
               that.showEventConfirm_gd = false
-              that.$emit('getEventList', that.calendarDay)
+              that.$emit('getEventList', that.calendarDay,10,1)
             }
           })
         } else {
@@ -1734,7 +1734,7 @@ export default {
               that.refreshEvent(that.eventCode)
               that.cancelEventConfirm_send()
               that.showEventConfirm = false
-              that.$emit('getEventList', that.calendarDay)
+              that.$emit('getEventList', that.calendarDay,10,1)
             }
           })
         }

+ 2 - 2
src/views/firespread.vue

@@ -1657,7 +1657,7 @@ export default {
               that.refreshEvent(that.eventCode)
               that.cancelEventConfirm_send()
               that.showEventConfirm_gd = false
-              that.$emit('getEventList', that.calendarDay)
+              that.$emit('getEventList', that.calendarDay,10,1)
             }
           })
         } else {
@@ -1698,7 +1698,7 @@ export default {
               that.refreshEvent(that.eventCode)
               that.cancelEventConfirm_send()
               that.showEventConfirm = false
-              that.$emit('getEventList', that.calendarDay)
+              that.$emit('getEventList', that.calendarDay,10,1)
             }
           })
         }

+ 72 - 128
src/views/forest.vue

@@ -274,9 +274,13 @@
                   <el-input
                     placeholder="请输入内容"
                     prefix-icon="el-icon-search"
-                    v-model="eventSearch" @change="searchEvent(eventSearch)">
+                    v-model="eventSearch" @change="getEventList(calendarDay,10,1,eventSearch)">
                   </el-input>
                 </div>
+                <div>
+                  <el-button type="button" @click="getEventList(calendarDay,10,pageNum-1)">上一页</el-button>
+                  <el-button type="button" @click="getEventList(calendarDay,10,pageNum+1)">下一页</el-button>
+                </div>
                 <div  class="d-l-con padding-box nowrap" v-for="(item,index) in eventList"
                      @click="dropLocation(item.latitude,item.longitude)" data-html2canvas-ignore>
                   <div class="bgt-img">
@@ -411,6 +415,9 @@ import {
   getEventByReportorOrder,
   getExposureStage
 } from '@/api/forest'
+import {
+  getNearEvent
+} from '@/api/event'
 import supermap from '@/components/supermap' //超图
 import supermapNotProcessed from '@/components/supermap' //超图
 import supermapProcessed from '@/components/supermap' //超图
@@ -462,10 +469,11 @@ export default {
     this.getTodayEvents(this.getCurrentDataStr())
     this.getDeptEventCount(this.getCurrentDataStr())
     this.getWeather(this.getCurrentDataStr())
-    this.getEventList(this.getCurrentDataStr())
+    this.getEventList(this.getCurrentDataStr(),this.pageSize,this.pageNum)
     this.getEventByEventType(this.getCurrentDataStr())
     this.getEventByReportorOrder(this.getCurrentDataStr())
     this.getExposureStage(this.getCurrentDataStr())
+    this.getSupermap(this.getCurrentDataStr())
     /** ----------------------------------weosocket开始------------------------------------- */
     // this.initWebSocket()
     /** ----------------------------------weosocket结束------------------------------------- */
@@ -474,10 +482,11 @@ export default {
       if(this.calendarDay == this.getCurrentDataStr()){
         this.getTodayEvents(this.getCurrentDataStr(),true);
         this.getDeptEventCount(this.getCurrentDataStr(),true);
-        this.getEventList(this.getCurrentDataStr(),true);
+        this.getEventList(this.getCurrentDataStr(),this.pageSize,this.pageNum,'',true);
         this.getEventByEventType(this.getCurrentDataStr(),true);
         this.getEventByReportorOrder(this.getCurrentDataStr(),true);
         this.getExposureStage(this.getCurrentDataStr(),true);
+        this.getSupermap(this.getCurrentDataStr(),true);
       }
     }, 10000)
   },
@@ -519,6 +528,9 @@ export default {
       exposureStageList: [],
       //右侧事件列表
       eventList: [],
+      pageSize:10,
+      pageNum:1,
+
       eventListnew: [],
       eventListAll: [],
       eventSearch: '',//事件列表搜索
@@ -555,103 +567,23 @@ export default {
   },
   /** ----------------------------------weosocket结束------------------------------------- */
   methods: {
-    searchEvent(eventSearch) {
-      let that = this
-      //事件列表搜索
-      this.eventListnew = []
-      if (eventSearch != null && eventSearch != '') {
-        for (var i = 0; i < this.eventListAll.length; i++) {
-          if (this.eventListAll[i].reportor.indexOf(eventSearch) > -1) {
-            this.eventListnew.push(this.eventListAll[i])
-          }
-        }
-        this.eventList = this.eventListnew
-      } else {
-        this.eventList = this.eventListAll
-      }
-      if (this.eventList != null && this.eventList.length > 0) {
-        for (let i = 0; i < this.eventList.length; i++) {
-          let markersMap = {
-            lng: 124.59,
-            lat: 43.02,
-            icon: 'marker',
-            bindPopupHtml: '',
-            click: '',
-            parameter: '',
-            keepBindPopup: false,
-            isAggregation: false
-          }
-          if (this.eventList.length > 200) {
-            markersMap.isAggregation = true
-          }
-          if (this.eventList[i].eventStatusValue == 'forest_event_status_1' && this.eventList[i].urgeCount == 0) {
-            markersMap.click = 'showEventDialog'
-            markersMap.icon = 'sj-icon-map-xinshangbao'
-          }
-          if (this.eventList[i].eventStatusValue == 'forest_event_status_1' && this.eventList[i].urgeCount > 0) {
-            markersMap.click = 'showEventDialog'
-            markersMap.icon = 'sj-icon-map-cuiban'
-          } else if (this.eventList[i].eventStatusValue == 'forest_event_status_2') {
-            markersMap.click = 'showEventDialog'
-            markersMap.icon = 'sj-icon-map-qianshou'
-            markersMap.isAggregation = false
-          } else if (this.eventList[i].eventStatusValue == 'forest_event_status_5') {
-            markersMap.click = 'showEventDialog'
-            markersMap.icon = 'sj-icon-map-banjie'
-            markersMap.isAggregation = false
-          } else if (this.eventList[i].eventStatusValue == 'forest_event_status_6') {
-            markersMap.click = 'showEventDialog'
-            markersMap.icon = 'sj-icon-map-guidang'
-          }
-          markersMap.parameter = this.eventList[i].eventCode
-          markersMap.lng = this.eventList[i].longitude
-          markersMap.lat = this.eventList[i].latitude
-          markersMap.bindPopupHtml = '<div class="map-tip">' +
-            '<span>' +
-            '                  <div class="d-l-con">' +
-            '                  <div class="d-l-l-text">' +
-            '                  <h4>经纬度:' + this.eventList[i].longitude + ',' + this.eventList[i].latitude + '</h4>' +
-            '                </div>' +
-            '                </div>' +
-            '                </span>' +
-            '<span>' +
-            '                  <div class="d-l-con">' +
-            '                  <div class="d-l-l-text">' +
-            '                  <h4>事件名称:' + this.eventList[i].eventName + '</h4>' +
-            '                </div>' +
-            '                </div>' +
-            '                </span>' +
-            '<span>' +
-            '                  <div class="d-l-con">' +
-            '                  <div class="d-l-l-text">' +
-            '                  <h4>事件时间:' + this.eventList[i].createTime + '</h4>' +
-            '                </div>' +
-            '                </div>' +
-            '                </span>'
-          if(this.eventList[i].pictureType=='image'&&this.eventList[i].picturePath != null && this.eventList[i].picturePath != ''){
-            markersMap.bindPopupHtml += '<span>' +
-              '                  <div class="d-l-con">' +
-              '                  <div class="d-l-l-text">' +
-              '<img src="' + this.eventList[i].picturePath + '" style="width: 150px;height: 100px"/>' +
-              '                </div>' +
-              '                </div>' +
-              '                </span>'
-          }
-          markersMap.bindPopupHtml += '</div>'
-          that.markersList.push(markersMap)
-        }
-        setTimeout(() => {
-          that.$refs.supermap.clearM(false)
-          that.$refs.supermap.clearM(true)
-          that.$refs.supermap.setMarkers(that.markersList)
-        }, 2000)
-      } else {
-        setTimeout(() => {
-          that.$refs.supermap.clearM(false)
-          that.$refs.supermap.clearM(true)
-        }, 2000)
-      }
-    },
+    // searchEvent(pageSize,pageNum,eventSearch) {
+    //   this.pageSize = pageSize;
+    //   this.pageNum = pageNum;
+    //   let that = this
+    //   //事件列表搜索
+    //   this.eventList = []
+    //   //右侧获取事件列表
+    //   getEventList({ day: that.calendarDay,pageSize:pageSize,pageNum: pageNum ,eventName:eventSearch}).then(res => {
+    //     this.eventList = res.data
+    //     if (this.eventList != null && this.eventList.length > 0) {
+    //       if(this.eventList[0].eventStatusValue == 'forest_event_status_1'){
+    //         that.$refs.bottomMenu.updateAlert();
+    //         that.$refs.up.play();
+    //       }
+    //     }
+    //   })
+    // },
     dropLocation(lat, lng) {
       this.$refs.supermap.dropLocation(lat, lng)
     },
@@ -675,10 +607,11 @@ export default {
       this.getTodayEvents(day)
       this.getDeptEventCount(day)
       this.getWeather(day)
-      this.getEventList(day)
+      this.getEventList(day,10,1)
       this.getEventByEventType(day)
       this.getEventByReportorOrder(day)
       this.getExposureStage(day)
+      this.getSupermap(day);
       this.calendarDay = day
     },
 
@@ -922,21 +855,12 @@ export default {
         }
       })
     },
-    getEventList(day,loading) {
+    getSupermap(day,loading){
       let that = this
-      this.eventList = []
-      this.eventListAll = []
-      //右侧获取事件列表
-      getEventList({ day: day },loading).then(res => {
-        this.eventList = res.data
-        this.eventListAll = res.data
+      getNearEvent('','',day,loading).then(res => {
         that.markersList = [];
-        if (this.eventList != null && this.eventList.length > 0) {
-          if(this.eventList[0].eventStatusValue == 'forest_event_status_1'){
-            that.$refs.bottomMenu.updateAlert();
-            that.$refs.up.play();
-          }
-          for (let i = 0; i < this.eventList.length; i++) {
+        if (res.data != null && res.data.length > 0) {
+          for (let i = 0; i < res.data.length; i++) {
             let markersMap = {
               lng: 124.59,
               lat: 43.02,
@@ -947,58 +871,58 @@ export default {
               keepBindPopup: false,
               isAggregation: false
             }
-            if (this.eventList.length > 200) {
+            if (res.data.length > 200) {
               markersMap.isAggregation = true
             }
-            if (this.eventList[i].eventStatusValue == 'forest_event_status_1' && this.eventList[i].urgeCount == 0) {
+            if (res.data[i].eventStatusValue == 'forest_event_status_1' && res.data[i].urgeCount == 0) {
               markersMap.click = 'showEventDialog'
               markersMap.icon = 'sj-icon-map-xinshangbao'
             }
-            if (this.eventList[i].eventStatusValue == 'forest_event_status_1' && this.eventList[i].urgeCount > 0) {
+            if (res.data[i].eventStatusValue == 'forest_event_status_1' && res.data[i].urgeCount > 0) {
               markersMap.click = 'showEventDialog'
               markersMap.icon = 'sj-icon-map-cuiban'
-            } else if (this.eventList[i].eventStatusValue == 'forest_event_status_2') {
+            } else if (res.data[i].eventStatusValue == 'forest_event_status_2') {
               markersMap.click = 'showEventDialog'
               markersMap.icon = 'sj-icon-map-qianshou'
               markersMap.isAggregation = false
-            } else if (this.eventList[i].eventStatusValue == 'forest_event_status_5') {
+            } else if (res.data[i].eventStatusValue == 'forest_event_status_5') {
               markersMap.click = 'showEventDialog'
               markersMap.icon = 'sj-icon-map-banjie'
               markersMap.isAggregation = false
-            } else if (this.eventList[i].eventStatusValue == 'forest_event_status_6') {
+            } else if (res.data[i].eventStatusValue == 'forest_event_status_6') {
               markersMap.click = 'showEventDialog'
               markersMap.icon = 'sj-icon-map-guidang'
             }
-            markersMap.parameter = this.eventList[i].eventCode
-            markersMap.lng = this.eventList[i].longitude
-            markersMap.lat = this.eventList[i].latitude
+            markersMap.parameter = res.data[i].eventCode
+            markersMap.lng = res.data[i].longitude
+            markersMap.lat = res.data[i].latitude
             markersMap.bindPopupHtml = '<div class="map-tip">' +
               '<span>' +
               '                  <div class="d-l-con">' +
               '                  <div class="d-l-l-text">' +
-              '                  <h4>经纬度:' + this.eventList[i].longitude + ',' + this.eventList[i].latitude + '</h4>' +
+              '                  <h4>经纬度:' + res.data[i].longitude + ',' + res.data[i].latitude + '</h4>' +
               '                </div>' +
               '                </div>' +
               '                </span>' +
               '<span>' +
               '                  <div class="d-l-con">' +
               '                  <div class="d-l-l-text">' +
-              '                  <h4>事件名称:' + this.eventList[i].eventName + '</h4>' +
+              '                  <h4>事件名称:' + res.data[i].eventName + '</h4>' +
               '                </div>' +
               '                </div>' +
               '                </span>' +
               '<span>' +
               '                  <div class="d-l-con">' +
               '                  <div class="d-l-l-text">' +
-              '                  <h4>事件时间:' + this.eventList[i].createTime + '</h4>' +
+              '                  <h4>事件时间:' + res.data[i].createTime + '</h4>' +
               '                </div>' +
               '                </div>' +
               '                </span>';
-            if(this.eventList[i].pictureType=='image'&&this.eventList[i].picturePath != null && this.eventList[i].picturePath != ''){
+            if(res.data[i].pictureType=='image'&&res.data[i].picturePath != null && res.data[i].picturePath != ''){
               markersMap.bindPopupHtml += '<span>' +
                 '                  <div class="d-l-con">' +
                 '                  <div class="d-l-l-text">' +
-                '<img src="' + this.eventList[i].picturePath + '" style="width: 150px;height: 100px"/>' +
+                '<img src="' + res.data[i].picturePath + '" style="width: 150px;height: 100px"/>' +
                 '                </div>' +
                 '                </div>' +
                 '                </span>'
@@ -1019,6 +943,26 @@ export default {
         }
       })
     },
+    getEventList(day,pageSize,pageNum,eventSearch,loading) {
+      if(pageNum < 1){
+        this.$modal.msg('当前已是第一页')
+        return;
+      }
+      this.pageSize = pageSize;
+      this.pageNum = pageNum;
+      let that = this
+      this.eventList = []
+      //右侧获取事件列表
+      getEventList({ day: day,pageSize:pageSize,pageNum: pageNum,eventName:eventSearch },loading).then(res => {
+        this.eventList = res.data
+        if (this.eventList != null && this.eventList.length > 0) {
+          if(this.eventList[0].eventStatusValue == 'forest_event_status_1'){
+            that.$refs.bottomMenu.updateAlert();
+            that.$refs.up.play();
+          }
+        }
+      })
+    },
     getEventByEventType(day,loading) {
       let that = this
       //右侧获取事件分类

+ 9 - 1
src/views/leader.vue

@@ -106,7 +106,8 @@ import {
   getForestLeader,
   getLeaderTrack,
   getPlanList,
-  getRy
+  getRy,
+  getRemotelist
 } from '@/api/leader'
 
 import supermap from '@/components/supermap' //超图
@@ -247,6 +248,7 @@ export default {
     },
     //点击左侧人员列表获取轨迹
     getLeaderTrack(userId) {
+      this.getRemotelist();
       this.listCurrentIndex1 = userId
       let that = this
       this.connectList = []
@@ -268,6 +270,12 @@ export default {
         }
       })
     },
+    //点击左侧人员获取人员的巡林计划列表
+    getRemotelist(){
+      getRemotelist().then(res => {
+        this.xunLinListOne = res.data;
+      })
+    },
 
     setConnectList(points, planName) {
       this.listCurrentIndex2 = planName

+ 334 - 0
src/views/trees.vue

@@ -0,0 +1,334 @@
+<template>
+  <div class="visual-con">
+    <!--头部-->
+    <vheader></vheader>
+    <!--主体-->
+    <div class="visual-body">
+      <!-- 左侧 -->
+      <div class="leftbar w-6" :class="indentleft" ref="left">
+        <div class="forthis">
+          <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
+            <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
+            <div class="i-list-con h-78">
+              <div class="d-l-con-icon">
+                <div class="icon-con icon-animal-con"
+                     v-for="(item,index) in animalDwfb" @click="getTreesRemoteList(item.treesSpecies)">
+                  <!--<div class="iconfont icon icon-normal icon-animal">-->
+                    <!--<img :src="item.src">-->
+                  <!--</div>-->
+                  <div class="icon-text icon-animal-text">
+                    <h5>{{ item.treesSpecies }}:{{item.count}}</h5>
+                  </div>
+                </div>
+              </div>
+            </div>
+          </dv-border-box-13>
+        </div>
+      </div>
+      <!-- 地图 -->
+      <supermap ref="supermap" style="width: 100%;height: 100vh;" :mapDiv="'animalMap'" class="indexSupermapClass"
+                :mapSite="{doubleClickZoom:false}" :codes="['9fa5']" :isSideBySide="false" @showTreesDetails="showTreesDetails" ></supermap>
+
+      <vBottomMenu ref="bottomMenu"></vBottomMenu>
+
+    </div>
+    <eventLocation ref="eventLocation"></eventLocation>
+    <TVWall ref="TVWall"></TVWall>
+    <treesDetails ref="treesDetails"></treesDetails>
+  </div>
+</template>
+
+<script>
+import {
+  selectCenterdataTForestTreesGroupByType,
+  getTreesRemoteList,
+  getTreesDetail
+} from '@/api/trees'
+
+import supermap from '@/components/supermap' //超图
+import vheader from '@/components/v-header.vue' //一体化共用头部
+import vBottomMenu from '@/components/vBottomMenu.vue' //一体化公共底部菜单
+import eventLocation from '@/components/eventLocation.vue' //事件定位弹窗
+import TVWall from '@/components/TVWall.vue' //电视墙弹窗
+import treesDetails from '@/views/treesDetails.vue' //古树详情页面
+
+let echarts = require('echarts')
+export default {
+  components: {
+    supermap,
+    vheader,
+    vBottomMenu,
+    eventLocation,
+    TVWall,
+    treesDetails
+  },
+  data() {
+    return {
+      animalcount: '',
+      iconCurrentIndex1: '',
+      listCurrentIndex1: '',
+      //左右缩进
+      indentStyle: '',
+      indentleft: '',
+      indentright: '',
+      indentText: '收起左右栏',
+      indentdisabled: false,
+
+      animalDwfb:[],
+      animalSjfb: [],
+      animalSjlb: [],
+      markersList: [] //点位列表
+    }
+  },
+  created() {
+    /** ----------------------------------底部按钮公用组件开始------------------------------------- */
+    window.showDialog = this.showDialog
+    window.choseLayerSwitching = this.choseLayerSwitching
+    window.choseLayerSwitchingList = this.choseLayerSwitchingList
+    /** ----------------------------------底部按钮公用组件结束------------------------------------- */
+  },
+  mounted() {
+    this.selectCenterdataTForestTreesGroupByType();
+    this.getTreesRemoteList();
+  },
+  methods: {
+    /** ----------------------------------底部按钮公用组件开始------------------------------------- */
+    showDialog(click) {
+      if (click == 'eventLocation') {
+        this.$refs.eventLocation.showEventLocation()
+        this.$refs.supermap.isEditableLayers = false
+        this.$refs.bottomMenu.showChild = false
+        this.$refs.bottomMenu.showBanChild = false
+        this.$refs.bottomMenu.showChangChild = false
+      } else if (click == 'editableLayers') {
+        this.$refs.bottomMenu.showChild = false
+        this.$refs.bottomMenu.showBanChild = false
+        this.$refs.bottomMenu.showChangChild = false
+        if (!this.$refs.supermap.isEditableLayers) {
+          this.$refs.supermap.isEditableLayers = true
+        } else {
+          this.$refs.supermap.isEditableLayers = false
+        }
+      } else if (click == 'layerSwitching') {
+        this.$refs.supermap.isEditableLayers = false
+        this.$refs.bottomMenu.showBanChild = false
+        this.$refs.bottomMenu.showChangChild = false
+        if (!this.$refs.bottomMenu.showChild) {
+          this.$refs.bottomMenu.showChild = true
+        } else {
+          this.$refs.bottomMenu.showChild = false
+        }
+      } else if (click == 'TVWall') {
+        this.$refs.TVWall.showTVWall()
+        this.$refs.supermap.isEditableLayers = false
+        this.$refs.bottomMenu.showChild = false
+        this.$refs.bottomMenu.showBanChild = false
+        this.$refs.bottomMenu.showChangChild = false
+      } else if (click == 'forestban') {
+        this.$refs.supermap.isEditableLayers = false
+        this.$refs.bottomMenu.showChild = false
+        this.$refs.bottomMenu.showChangChild = false
+        if (!this.$refs.bottomMenu.showBanChild) {
+          this.$refs.bottomMenu.showBanChild = true
+        } else {
+          this.$refs.bottomMenu.showBanChild = false
+        }
+      } else if (click == 'forestchang') {
+        this.$refs.supermap.isEditableLayers = false
+        this.$refs.bottomMenu.showBanChild = false
+        this.$refs.bottomMenu.showChild = false
+        if (!this.$refs.bottomMenu.showChangChild) {
+          this.$refs.bottomMenu.showChangChild = true
+        } else {
+          this.$refs.bottomMenu.showChangChild = false
+        }
+      }
+
+    },
+    //选择图层
+    choseLayerSwitching(url, isClear) {
+      this.$refs.supermap.layerSwitching(url, isClear)
+    },
+    //选择图层(传递数组)
+    choseLayerSwitchingList(urlList) {
+      this.$refs.supermap.layerSwitchingList(urlList)
+    },
+    /** ----------------------------------底部按钮公用组件结束------------------------------------- */
+    selectCenterdataTForestTreesGroupByType(){
+      selectCenterdataTForestTreesGroupByType().then(res => {
+        this.animalDwfb = res.data;
+      })
+    },
+    getTreesRemoteList(treesSpecies){
+      let that = this;
+      getTreesRemoteList(treesSpecies).then(res => {
+        that.markersList = []
+        if (res.data != null && res.data.length > 0) {
+          for (let i = 0; i < res.data.length; i++) {
+            let markersMap = {
+              lng: 124.59,
+              lat: 43.02,
+              icon: 'marker',
+              bindPopupHtml: '',
+              click: 'showTreesDetails',
+              parameter: {id:res.data[i].id},
+              keepBindPopup: false,
+              isAggregation: false
+            }
+            markersMap.lng = res.data[i].longitude
+            markersMap.lat = res.data[i].latitude
+            markersMap.bindPopupHtml = '<div class="map-tip">' +
+              '<span>' +
+              '                  <div class="d-l-con">' +
+              '                  <div class="d-l-l-text">' +
+              '                  <h4>植物名称:' + res.data[i].treesName +
+              '</h4>' +
+              '                </div>' +
+              '                </div>' +
+              '                </span>' +
+              '<span>' +
+              '                  <div class="d-l-con">' +
+              '                  <div class="d-l-l-text">' +
+              '                  <h4>树种:' + res.data[i].treesSpecies +
+              '</h4>' +
+              '                </div>' +
+              '                </div>' +
+              '                </span>' +
+              '<span>' +
+              '                  <div class="d-l-con">' +
+              '                  <div class="d-l-l-text">' +
+              '                  <h4>事件时间:' + res.data[i].createTime +
+              '</h4>' +
+              '                </div>' +
+              '                </div>' +
+              '                </span>' +
+              '<span>' +
+              '                  <div class="d-l-con">' +
+              '                  <div class="d-l-l-text">' +
+              '<img src="' + res.data[i].attachId + '" style="width: 150px;height: 100px"/>' +
+              '                </div>' +
+              '                </div>' +
+              '                </span>'
+              '</div>'
+            that.markersList.push(markersMap)
+          }
+          setTimeout(() => {
+            that.$refs.supermap.clearM(false)
+            that.$refs.supermap.clearM(true)
+            that.$refs.supermap.setMarkers(that.markersList)
+          }, 1000)
+        } else {
+          setTimeout(() => {
+            that.$refs.supermap.clearM(false)
+            that.$refs.supermap.clearM(true)
+          }, 1000)
+        }
+      })
+    },
+
+    showTreesDetails(pointParam){
+      //事件信息弹出
+      this.$refs.treesDetails.showTreesDetails(pointParam);
+    },
+
+    dropLocation(lat, lng, index) {
+      this.listCurrentIndex1 = index
+      this.$refs.supermap.dropLocation(lat, lng)
+    },
+
+    //事件chart
+    eventChart() {
+      // 基于准备好的dom,初始化echarts实例
+      let myChart = echarts.init(document.getElementById('animal-chart'))
+      myChart.setOption({
+        color: ['#2EACFF', '#FFA61C', '#2EC054', '#8C64D7'],
+        tooltip: {
+          trigger: 'item',
+          formatter: '{a} <br/>{b} : {c} ({d}%)'
+        },
+        toolbox: {
+          show: true
+        },
+        series: [{
+          name: '事件分类',
+          type: 'pie',
+          roseType: true,
+          radius: [30, 70],
+          label: {
+            show: true,
+            formatter: '{b}\n{c} '
+          },
+          data: this.eventChartData
+        }]
+      })
+
+    },
+    //吉祥物收起左右框
+    indent() {
+      let list = document.getElementsByClassName('el-tooltip__popper')
+      list[list.length - 1].style.display = 'none'
+      if (this.indentStyle == '') {
+        this.indentStyle = 'indent-style'
+        this.indentleft = 'indent-left'
+        this.indentright = 'indent-right'
+        this.indentText = '展开左右栏'
+      } else if (this.indentText == '展开左右栏') {
+        this.indentStyle = ''
+        this.indentleft = ''
+        this.indentright = ''
+        this.indentText = '收起左右栏'
+      }
+    }
+  }
+
+}
+</script>
+
+<style rel="stylesheet/scss" lang="scss" scoped>
+@import '@/assets/styles/base.scss';
+
+//动物保护
+.icon-animal-con {
+  width: 100%;
+  display: block !important;
+}
+
+.icon-animal {
+  display: block;
+  margin: 2px auto;
+  background: none !important;
+}
+
+.icon-animal-text {
+  display: block !important;
+  text-align: center !important;
+  padding: 0.5rem 0.5rem 0rem 0.5rem;
+}
+
+.animal-text {
+  background: #f5ad1b;
+  border: 0.2px solid rgba(19, 64, 64, 0.7);
+  height: 3.2rem;
+  width: 4rem;
+  text-align: center;
+  margin: 0px auto;
+  border-radius: 0.5rem;
+  color: #fff !important;
+}
+
+.animal-text h6 {
+  color: #fff !important;
+}
+
+.w100 {
+  width: 100% !important;
+}
+
+.animal-img {
+  height: 3rem !important;
+}
+
+.w-6 {
+  width: 6rem !important;
+}
+</style>

+ 61 - 0
src/views/treesDetails.vue

@@ -0,0 +1,61 @@
+<template>
+  <div class="visual-con">
+    <el-dialog title="古树详情" :visible.sync="pointDetailsVisible" width="50rem" v-if="pointDetailsVisible">
+      <div class="text-con">
+        <div><i class="ismall"></i><span>名称:{{retMap.treesName}}</span></div>
+        <div><i class="ismall"></i><span>经度:{{retMap.longitude}}</span></div>
+        <div><i class="ismall"></i><span>纬度:{{retMap.latitude}}</span></div>
+        <div><i class="ismall"></i><span>编号:{{retMap.treesNumber}}</span></div>
+        <div><i class="ismall"></i><span>树龄:{{retMap.treesAge}}</span></div>
+        <div><i class="ismall"></i><span>树种:{{retMap.treesSpecies}}</span></div>
+        <div><i class="ismall"></i><span>类型:{{retMap.treesType}}</span></div>
+        <div><i class="ismall"></i><span>备注:{{retMap.treesRemarks}}</span></div>
+        <div><i class="ismall"></i><span>部门名称:{{retMap.deptName}}</span></div>
+        <div><i class="ismall"></i><span>图片</span><img :src="retMap.attachId"></div>
+      </div>
+    </el-dialog>
+  </div>
+
+</template>
+
+<script>
+import {getTreesDetail} from '@/api/trees'
+export default {
+    // dicts: ['farm_hzs_type','farm_farmer_type','farm_breed_type'],
+    name: "treesDetails",
+    data() {
+      return {
+        pointDetailsVisible:false,
+        retMap:{},
+        type:'',
+      }
+    },
+    created(){
+    },
+    methods: {
+      showTreesDetails(pointParam) {
+        this.pointDetailsVisible=true;
+        getTreesDetail(pointParam.id).then(res => {
+          this.retMap = res.data;
+        })
+      },
+    },
+}
+
+</script>
+<style rel="stylesheet/scss" lang="scss" scoped>
+@import '@/assets/styles/base.scss';
+
+.text-con{
+	color: #ba8a2a;
+	line-height: 40px;
+	padding:0 .5rem;
+}
+.ismall{
+	    width: 0.5rem;
+	    height: 0.5rem;
+	    display: inline-block;
+	    background: #eb9e23;
+		margin-right: .3rem;
+}
+</style>