From 85fb13abbeadc1765d2c0056ba99c6c19aa35dfd Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Sun, 09 Apr 2023 03:44:49 +0800
Subject: [PATCH] 电子沙盘的调整
---
src/views/activity/components/videoControlBox.vue | 24 +++++++++---------------
1 files changed, 9 insertions(+), 15 deletions(-)
diff --git a/src/views/activity/components/videoControlBox.vue b/src/views/activity/components/videoControlBox.vue
index 58b8c40..e1e4c32 100644
--- a/src/views/activity/components/videoControlBox.vue
+++ b/src/views/activity/components/videoControlBox.vue
@@ -115,8 +115,8 @@
</template>
<script>
-let tc = undefined
-let track = undefined
+let tc = null
+let track = null
let flvListPlayer = {
flvPlayer1: null,
@@ -130,8 +130,6 @@
import { getRegionList, getDevices } from '@/api/video/index.js'
export default {
- props: ['linePosition'],
-
data () {
return {
valChoosed: '',
@@ -189,10 +187,10 @@
* @description: 轨迹点击弹窗中,查看视频
* @return {*}
*/
- watchVideo () {
+ watchVideo (linePosition, polygonPosition) {
const that = this
- const line = this.$turf.lineString(this.linePosition.split(';').filter(item => item != '').map(item => item.split(',').map(i => Number(i))))
+ const line = this.$turf.lineString(linePosition.split(';').filter(item => item != '').map(item => item.split(',').map(i => Number(i))))
// const lineLength = this.$turf.length(line) * 1000
const chunkLine = this.$turf.lineChunk(line, 0.1)
let arr = chunkLine.features.reduce((pre, cur) =>
@@ -203,7 +201,7 @@
const time = arr.filter(item => arr.indexOf(item) == arr.lastIndexOf(item)).length * 16
const newPostion = arr.filter((item, index) => index == arr.lastIndexOf(item)).join(';')
- this.getRegionList(this.polygonPosition)
+ this.getRegionList(polygonPosition)
this.videoShow = true
if (tc) {
@@ -283,15 +281,15 @@
}
})
+ }, {
+ headingOffset: -90
})
track.setModel('/model/qiche.gltf', {
- scale: 0.8
+ scale: 1.2
})
tc.addTrack(track)
-
- this.$parent.lineEditVisible = false
},
// 遍历监控图标
@@ -470,11 +468,7 @@
type: 'VectorLayer'
})
- console.log(tc, 56555)
-
- if (tc) {
- tc.clear()
- }
+ tc = null
},
}
</script>
--
Gitblit v1.9.3