4.2
This commit is contained in:
@@ -119,9 +119,10 @@
|
||||
props.isCollect = 1
|
||||
} else {
|
||||
props.isCollect = 0
|
||||
modelValue.value = false
|
||||
}
|
||||
pubSub.publish('videoCollect', props.cameraIndexCode)
|
||||
modelValue.value = false
|
||||
|
||||
}
|
||||
const handleAction = async (e) => {
|
||||
if (e == STOP) {
|
||||
|
||||
@@ -87,7 +87,7 @@
|
||||
import trafficJam from './traffic-jam'
|
||||
import { getPreviewUrlApi } from '@/api/home'
|
||||
import { useMap } from '@/hooks/map'
|
||||
|
||||
import pubSub from 'pubsub-js'
|
||||
import { getRouterListApi, getRoutersApi,getRoutersMapApi } from '@/api/traffic'
|
||||
import mapIcon from '@/assets/images/map-video.png'
|
||||
const { map, initMap,addMarker,marker } = useMap()
|
||||
@@ -145,7 +145,12 @@
|
||||
immediate: true
|
||||
}
|
||||
)
|
||||
|
||||
const onVideoCollect = () => {
|
||||
pubSub.subscribe('videoCollect', () => {
|
||||
// clearHlsRefs()
|
||||
getRoutersMap()
|
||||
})
|
||||
}
|
||||
const getPreviewUrl = async (code) => {
|
||||
let res = await getPreviewUrlApi({
|
||||
cameraIndexCode: code,
|
||||
@@ -184,6 +189,7 @@
|
||||
getRouterList()
|
||||
getRouters()
|
||||
getRoutersMap()
|
||||
onVideoCollect()
|
||||
})
|
||||
</script>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user