wang_xy 2 vuotta sitten
vanhempi
commit
d8871c70c8
3 muutettua tiedostoa jossa 42 lisäystä ja 2 poistoa
  1. 25 0
      src/api/monitor.js
  2. 16 0
      src/components/TVWall.vue
  3. 1 2
      src/views/eventdetailsdialog.vue

+ 25 - 0
src/api/monitor.js

@@ -37,3 +37,28 @@ export function getRegionalFlag(id) {
 //     data: {deptId:deptId,type:'1'}
 //   })
 // }
+
+//获取点位周边摄像头
+export function findCameraByEventCoordinate(longitude,latitude) {
+  longitude = '124.41986560821533';
+  latitude = '43.08817137032747';
+  return request({
+    url: '/center-fire/VisuForestMonitorCenterController/findCameraByEventCoordinate?longitude='+longitude+"&latitude="+latitude+"&type=1",
+    method: 'get',
+  })
+}
+
+//转到固定点位
+export function rotation(lng,lat,list) {
+  lng = '124.41986560821533';
+  lat = '43.08817137032747';
+  return request({
+    url: '/center-fire/VisuForestMonitorCenterController/rotation',
+    method: 'post',
+    data:{
+      lng:lng,
+      lat:lat,
+      list:list
+    }
+  })
+}

+ 16 - 0
src/components/TVWall.vue

@@ -2,6 +2,7 @@
   <div>
     <el-dialog title="电视墙" :visible.sync="TVWallVisible" v-if="TVWallVisible" customClass="TVWallCustomWidth"
                @close="cancelEventLocationShow()">
+      <div @click="findCameraByEventCoordinate()">视频联动</div>
 	  <!--<div class="forthis" style="width: 22%; position: absolute;left: 0;z-index: 9999999999999;">-->
 	  	<!--<div class="i-list-con" style="height: 46vh; overflow-y: scroll;">-->
 	  		<!--<span v-for="(item,index) in cameraList" :key="index">-->
@@ -31,6 +32,7 @@
 /** ----------------------------------摄像头预览开始------------------------------------- */
 import { getDahuaVideoServer, getTVWallList } from '@/api/dahua/dahua'
 import { tvCameraList } from '@/api/haikang/haikang'
+import { findCameraByEventCoordinate,rotation } from '@/api/monitor'
 import DHWs from '@/dahua/lib/DHWs'
 
 /** ----------------------------------摄像头预览结束------------------------------------- */
@@ -264,6 +266,20 @@ export default {
     this.ws = DHWsInstance
   },
   methods: {
+    findCameraByEventCoordinate(){
+      findCameraByEventCoordinate().then(res => {
+        const list = [];
+        for(let i in res.data){
+          list.push(res.data[i].cameraCode)
+        }
+        this.rotation('','',list);
+      })
+    },
+    rotation(lng,lat,list){
+      rotation(lng,lat,list).then(res => {
+
+      })
+    },
     cancelEventLocationShow() {
       // this.activeName = 'tv'
       this.TVWallVisible = false

+ 1 - 2
src/views/eventdetailsdialog.vue

@@ -59,8 +59,7 @@
                    </div> -->
                 <!-- 底部工具栏end -->
                 <div class="fire-m">
-                  <el-button size="small" icon="el-icon-upload" @click="showheatPlotting()">火灾蔓延
-                  </el-button>
+                  <el-button size="small" icon="el-icon-upload" @click="showheatPlotting()">火灾蔓延</el-button>
                 </div>
                 <!-- 地图 -->
                 <supermapDialog ref="supermapDialog"