浏览代码

应急可视化 监控中心可以查看所有摄像头

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

+ 6 - 6
src/components/eventLocation.vue

@@ -547,7 +547,7 @@ export default {
     },
     /** 预览按钮操作 */
     preview(cameraParam) {
-      if (cameraParam.type == '大华') {
+      if(cameraParam.type=='1'){
         getDahuaVideoServer().then(newResponse => {
           console.log(newResponse)
           this.ws.detectConnectQt().then(res => {
@@ -559,7 +559,7 @@ export default {
                 userName: newResponse.userName,
                 userPwd: newResponse.userPwd,
                 token: '',
-                https: 0
+                https: 1
               })
               this.ws.on('loginState', (res) => {
                 this.isLogin = res
@@ -577,12 +577,12 @@ export default {
             }
           })
         })
-      } else if (cameraParam.type == '海康') {
+      }else if(cameraParam.type=='0'){
         let that = this
         that.cameraVisible = true
-        getHaiKangVideoServer({ cameraCode: cameraParam.code }).then(newResponse => {
-          that.cameraTitle = '摄像头-' + newResponse.data.cameraName
-          that.initPlugin(newResponse.data.appkey, newResponse.data.loginIp, newResponse.data.secret, newResponse.data.loginPort)
+        getHaiKangVideoServer({cameraCode:cameraParam.code}).then(newResponse => {
+          that.cameraTitle = '摄像头-'+newResponse.data.cameraName
+          that.initPlugin(newResponse.data.appkey,newResponse.data.loginIp,newResponse.data.secret,newResponse.data.loginPort)
           setTimeout(function() {
             that.playhk(newResponse.data.channelCode)
           }, 5000)