|
@@ -6,7 +6,7 @@
|
|
<!--主体-->
|
|
<!--主体-->
|
|
<div class="visual-body">
|
|
<div class="visual-body">
|
|
<!-- 左侧 -->
|
|
<!-- 左侧 -->
|
|
- <div class="leftbar" ref="left">
|
|
|
|
|
|
+ <div class="leftbar" :class="indentleft" ref="left">
|
|
<div class="forthis">
|
|
<div class="forthis">
|
|
<dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
|
|
<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;"/>
|
|
<img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
|
|
@@ -71,7 +71,7 @@
|
|
:mapSite="{doubleClickZoom:false}" :codes="['9fa5']" :isSideBySide="false" @preview="preview">
|
|
:mapSite="{doubleClickZoom:false}" :codes="['9fa5']" :isSideBySide="false" @preview="preview">
|
|
</supermap>
|
|
</supermap>
|
|
<!-- 右侧 -->
|
|
<!-- 右侧 -->
|
|
- <div class="rightbar" ref="right">
|
|
|
|
|
|
+ <div class="rightbar" :class="indentright" ref="right">
|
|
<div class="forthis">
|
|
<div class="forthis">
|
|
<dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
|
|
<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;"/>
|
|
<img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
|
|
@@ -110,6 +110,11 @@
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<vBottomMenu ref="bottomMenu"></vBottomMenu>
|
|
<vBottomMenu ref="bottomMenu"></vBottomMenu>
|
|
|
|
+<!-- <el-tooltip :content="indentText" placement="top" :disabled="indentdisabled">-->
|
|
|
|
+<!-- <div class="mascot" ref="mascot" :class="indentStyle" @click="indent"><img-->
|
|
|
|
+<!-- src="@/assets/images/mascot.png"/></div>-->
|
|
|
|
+<!-- </el-tooltip>-->
|
|
|
|
+
|
|
</div>
|
|
</div>
|
|
<eventLocation ref="eventLocation"></eventLocation>
|
|
<eventLocation ref="eventLocation"></eventLocation>
|
|
<TVWall ref="TVWall"></TVWall>
|
|
<TVWall ref="TVWall"></TVWall>
|
|
@@ -144,7 +149,7 @@ import {
|
|
import {
|
|
import {
|
|
getHaiKangVideoServer
|
|
getHaiKangVideoServer
|
|
} from '@/api/haikang/haikang'
|
|
} from '@/api/haikang/haikang'
|
|
-// import DHWs from '@/dahua/lib/DHWs'
|
|
|
|
|
|
+import DHWs from '@/dahua/lib/DHWs'
|
|
|
|
|
|
/** ----------------------------------摄像头预览结束------------------------------------- */
|
|
/** ----------------------------------摄像头预览结束------------------------------------- */
|
|
// import echarts from 'echarts'
|
|
// import echarts from 'echarts'
|
|
@@ -160,8 +165,8 @@ export default {
|
|
},
|
|
},
|
|
created() {
|
|
created() {
|
|
/** ----------------------------------摄像头预览开始------------------------------------- */
|
|
/** ----------------------------------摄像头预览开始------------------------------------- */
|
|
- // const DHWsInstance = DHWs.getInstance()
|
|
|
|
- // this.ws = DHWsInstance
|
|
|
|
|
|
+ const DHWsInstance = DHWs.getInstance()
|
|
|
|
+ this.ws = DHWsInstance
|
|
/** ----------------------------------摄像头预览结束------------------------------------- */
|
|
/** ----------------------------------摄像头预览结束------------------------------------- */
|
|
|
|
|
|
/** ----------------------------------底部按钮公用组件开始------------------------------------- */
|
|
/** ----------------------------------底部按钮公用组件开始------------------------------------- */
|
|
@@ -180,6 +185,7 @@ export default {
|
|
listCurrentIndex1: '-1',
|
|
listCurrentIndex1: '-1',
|
|
listCurrentIndex2: '-1',
|
|
listCurrentIndex2: '-1',
|
|
listCurrentIndex3: '-1',
|
|
listCurrentIndex3: '-1',
|
|
|
|
+ graphicsList:[],//重点区域
|
|
/** ----------------------------------摄像头预览开始------------------------------------- */
|
|
/** ----------------------------------摄像头预览开始------------------------------------- */
|
|
//大华
|
|
//大华
|
|
activePanel: 'key1',
|
|
activePanel: 'key1',
|
|
@@ -204,6 +210,13 @@ export default {
|
|
activeName: 'info',
|
|
activeName: 'info',
|
|
radio: '1',
|
|
radio: '1',
|
|
region: [],
|
|
region: [],
|
|
|
|
+ //左右缩进
|
|
|
|
+ indentStyle: '',
|
|
|
|
+ indentleft: '',
|
|
|
|
+ indentright: '',
|
|
|
|
+ indentText: '收起左右栏',
|
|
|
|
+ indentdisabled: false,
|
|
|
|
+ domId: 'dom1',
|
|
}
|
|
}
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
@@ -333,7 +346,8 @@ export default {
|
|
}],
|
|
}],
|
|
xAxis: {
|
|
xAxis: {
|
|
show: false,
|
|
show: false,
|
|
- type: 'value'
|
|
|
|
|
|
+ type: 'value',
|
|
|
|
+ left:10
|
|
},
|
|
},
|
|
yAxis: {
|
|
yAxis: {
|
|
type: 'category', // 不设置类目轴,抽离的dataset数据展示不出来
|
|
type: 'category', // 不设置类目轴,抽离的dataset数据展示不出来
|
|
@@ -411,7 +425,7 @@ export default {
|
|
//获取左侧动态感知设备
|
|
//获取左侧动态感知设备
|
|
let that = this
|
|
let that = this
|
|
selectDeviceType().then(res => {
|
|
selectDeviceType().then(res => {
|
|
- that.cameraMarkersList = []
|
|
|
|
|
|
+ that.cameraMarkersList=[]
|
|
that.visuForestCloudMapDeviceBOList = res.data.visuForestCloudMapDeviceBOList
|
|
that.visuForestCloudMapDeviceBOList = res.data.visuForestCloudMapDeviceBOList
|
|
|
|
|
|
that.region = res.data.visuForestCloudTodaySjfbBOList
|
|
that.region = res.data.visuForestCloudTodaySjfbBOList
|
|
@@ -442,7 +456,8 @@ export default {
|
|
isAggregation: false
|
|
isAggregation: false
|
|
}
|
|
}
|
|
if (res.data.visuForestCloudCameraBOList[i].channelCode != null) {
|
|
if (res.data.visuForestCloudCameraBOList[i].channelCode != null) {
|
|
- markersMap.parameter = res.data.visuForestCloudCameraBOList[i].cameraCode
|
|
|
|
|
|
+ markersMap.parameter = {code:res.data.visuForestCloudCameraBOList[i].cameraCode,
|
|
|
|
+ type:res.data.visuForestCloudCameraBOList[i].cameraFactory}
|
|
} else {
|
|
} else {
|
|
markersMap.parameter = []
|
|
markersMap.parameter = []
|
|
}
|
|
}
|
|
@@ -484,7 +499,7 @@ export default {
|
|
' </div>' +
|
|
' </div>' +
|
|
' </span>' +
|
|
' </span>' +
|
|
'</div>'
|
|
'</div>'
|
|
- that.cameraMarkersList.push(markersMap)
|
|
|
|
|
|
+ this.cameraMarkersList.push(markersMap)
|
|
// cameraAccount: "1"
|
|
// cameraAccount: "1"
|
|
// cameraCode: "1000010"
|
|
// cameraCode: "1000010"
|
|
// cameraFactory: "2"
|
|
// cameraFactory: "2"
|
|
@@ -505,7 +520,7 @@ export default {
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
that.$refs.supermap.clearM(true)
|
|
that.$refs.supermap.clearM(true)
|
|
that.$refs.supermap.clearM(false)
|
|
that.$refs.supermap.clearM(false)
|
|
- that.$refs.supermap.setMarkersRadius(that.cameraMarkersList)
|
|
|
|
|
|
+ that.$refs.supermap.setMarkersRadius(this.cameraMarkersList)
|
|
}, 1000)
|
|
}, 1000)
|
|
}
|
|
}
|
|
})
|
|
})
|
|
@@ -522,7 +537,6 @@ export default {
|
|
selectCameraByDeptId(depId).then(res => {
|
|
selectCameraByDeptId(depId).then(res => {
|
|
//根据设备类型查看列表
|
|
//根据设备类型查看列表
|
|
that.visuForestCloudCameraBOList = res.data
|
|
that.visuForestCloudCameraBOList = res.data
|
|
-
|
|
|
|
if (res.data != null && res.data.length > 0) {
|
|
if (res.data != null && res.data.length > 0) {
|
|
for (let i = 0; i < res.data.length; i++) {
|
|
for (let i = 0; i < res.data.length; i++) {
|
|
let markersMap = {
|
|
let markersMap = {
|
|
@@ -535,11 +549,9 @@ export default {
|
|
keepBindPopup: false,
|
|
keepBindPopup: false,
|
|
isAggregation: false
|
|
isAggregation: false
|
|
}
|
|
}
|
|
- if (res.data.length > 50) {
|
|
|
|
- markersMap.isAggregation = true
|
|
|
|
- }
|
|
|
|
if (res.data[i].channelCode != null) {
|
|
if (res.data[i].channelCode != null) {
|
|
- markersMap.parameter = res.data[i].cameraCode
|
|
|
|
|
|
+ markersMap.parameter = {code:res.data.data[i].cameraCode,
|
|
|
|
+ type:res.data.data[i].cameraFactory}
|
|
} else {
|
|
} else {
|
|
markersMap.parameter = []
|
|
markersMap.parameter = []
|
|
}
|
|
}
|
|
@@ -601,11 +613,27 @@ export default {
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
that.$refs.supermap.clearM(true)
|
|
that.$refs.supermap.clearM(true)
|
|
that.$refs.supermap.clearM(false)
|
|
that.$refs.supermap.clearM(false)
|
|
- that.$refs.supermap.setMarkersRadius(that.cameraMarkersList)
|
|
|
|
|
|
+ that.$refs.supermap.setMarkersRadius(this.cameraMarkersList)
|
|
}, 1000)
|
|
}, 1000)
|
|
}
|
|
}
|
|
})
|
|
})
|
|
},
|
|
},
|
|
|
|
+ //吉祥物收起左右框
|
|
|
|
+ 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 = '收起左右栏'
|
|
|
|
+ }
|
|
|
|
+ },
|
|
/** ----------------------------------摄像头预览开始------------------------------------- */
|
|
/** ----------------------------------摄像头预览开始------------------------------------- */
|
|
alertLogin: function() {
|
|
alertLogin: function() {
|
|
this.$modal.msg('登录中....')
|
|
this.$modal.msg('登录中....')
|
|
@@ -629,45 +657,48 @@ export default {
|
|
}
|
|
}
|
|
},
|
|
},
|
|
/** 预览按钮操作 */
|
|
/** 预览按钮操作 */
|
|
- preview(cameraCode) {
|
|
|
|
- let that = this
|
|
|
|
- // getDahuaVideoServer().then(newResponse => {
|
|
|
|
- // console.log(newResponse)
|
|
|
|
- // this.ws.detectConnectQt().then(res => {
|
|
|
|
- // if (res) { // 连接客户端成功
|
|
|
|
- // this.alertLogin()
|
|
|
|
- // this.ws.login({
|
|
|
|
- // loginIp: newResponse.loginIp,
|
|
|
|
- // loginPort: newResponse.loginPort,
|
|
|
|
- // userName: newResponse.userName,
|
|
|
|
- // userPwd: newResponse.userPwd,
|
|
|
|
- // token: '',
|
|
|
|
- // https: 1
|
|
|
|
- // })
|
|
|
|
- // this.ws.on('loginState', (res) => {
|
|
|
|
- // this.isLogin = res
|
|
|
|
- // console.log('---res-----', res)
|
|
|
|
- // if (res) {
|
|
|
|
- // this.alertLoginSuccess()
|
|
|
|
- // this.activePanel = 'key2'
|
|
|
|
- // this.realTimeVideoDialog(channelCode)
|
|
|
|
- // } else {
|
|
|
|
- // this.alertLoginFailed()
|
|
|
|
- // }
|
|
|
|
- // })
|
|
|
|
- // } else { // 连接客户端失败
|
|
|
|
- // this.alertReinstall()
|
|
|
|
- // }
|
|
|
|
- // })
|
|
|
|
- // })
|
|
|
|
- that.cameraVisible = true
|
|
|
|
- getHaiKangVideoServer({cameraCode:cameraCode}).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)
|
|
|
|
- })
|
|
|
|
|
|
+ preview(cameraParam) {
|
|
|
|
+ if(cameraParam.type=='大华'){
|
|
|
|
+ getDahuaVideoServer().then(newResponse => {
|
|
|
|
+ console.log(newResponse)
|
|
|
|
+ this.ws.detectConnectQt().then(res => {
|
|
|
|
+ if (res) { // 连接客户端成功
|
|
|
|
+ this.alertLogin()
|
|
|
|
+ this.ws.login({
|
|
|
|
+ loginIp: newResponse.loginIp,
|
|
|
|
+ loginPort: newResponse.loginPort,
|
|
|
|
+ userName: newResponse.userName,
|
|
|
|
+ userPwd: newResponse.userPwd,
|
|
|
|
+ token: '',
|
|
|
|
+ https: 0
|
|
|
|
+ })
|
|
|
|
+ this.ws.on('loginState', (res) => {
|
|
|
|
+ this.isLogin = res
|
|
|
|
+ console.log('---res-----', res)
|
|
|
|
+ if (res) {
|
|
|
|
+ this.alertLoginSuccess()
|
|
|
|
+ this.activePanel = 'key2'
|
|
|
|
+ this.realTimeVideoDialog(cameraParam.code)
|
|
|
|
+ } else {
|
|
|
|
+ this.alertLoginFailed()
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ } else { // 连接客户端失败
|
|
|
|
+ this.alertReinstall()
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ })
|
|
|
|
+ }else if(cameraParam.type=='海康'){
|
|
|
|
+ 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)
|
|
|
|
+ setTimeout(function() {
|
|
|
|
+ that.playhk(newResponse.data.channelCode)
|
|
|
|
+ }, 5000)
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
|
|
},
|
|
},
|
|
realTimeVideoDialog(cameraParams) { // 调用弹窗实时播放接口
|
|
realTimeVideoDialog(cameraParams) { // 调用弹窗实时播放接口
|
|
@@ -675,7 +706,8 @@ export default {
|
|
this.$Message.info('正在登陆客户端,请稍等......')
|
|
this.$Message.info('正在登陆客户端,请稍等......')
|
|
return false
|
|
return false
|
|
}
|
|
}
|
|
- this.ws.openVideo(cameraParams)
|
|
|
|
|
|
+ const params = [cameraParams];
|
|
|
|
+ this.ws.openVideo(params)
|
|
},
|
|
},
|
|
/** ----------------------------------摄像头预览结束------------------------------------- */
|
|
/** ----------------------------------摄像头预览结束------------------------------------- */
|
|
|
|
|
|
@@ -719,7 +751,7 @@ export default {
|
|
cbConnectClose: function(bNormalClose) {
|
|
cbConnectClose: function(bNormalClose) {
|
|
// 异常断开:bNormalClose = false
|
|
// 异常断开:bNormalClose = false
|
|
// JS_Disconnect正常断开:bNormalClose = true
|
|
// JS_Disconnect正常断开:bNormalClose = true
|
|
-
|
|
|
|
|
|
+ console.log('cbConnectClose')
|
|
that.oWebControl = null
|
|
that.oWebControl = null
|
|
}
|
|
}
|
|
})
|
|
})
|
|
@@ -797,7 +829,7 @@ export default {
|
|
keyLength: 1024
|
|
keyLength: 1024
|
|
})
|
|
})
|
|
}).then(function(oData) {
|
|
}).then(function(oData) {
|
|
-
|
|
|
|
|
|
+ console.log(oData)
|
|
if (oData.responseMsg.data) {
|
|
if (oData.responseMsg.data) {
|
|
that.pubKey = oData.responseMsg.data
|
|
that.pubKey = oData.responseMsg.data
|
|
callback()
|
|
callback()
|