feat(): 视频监控对接

qzc-dev-demo
李神峰 2025-04-01 17:57:12 +08:00
parent c5b4fbdebd
commit aa5874bbc5
2 changed files with 8 additions and 6 deletions

View File

@ -67,7 +67,8 @@ const apiurl = {
//闸门监控
zmjk: {
getList : service_xyt + '/attGateB/list',
getList: service_xyt + '/attGateB/list',
video:service_xyt + '/attCctvBase/list',
getInformation: service_xyt + '/attGateB/data',
getDamData: service_xyt + '/gatePore/listByStcd',
getVideo: service_xyt + '/gateValveCctvRel/list'

View File

@ -263,19 +263,20 @@ const Page = () => {
const pts = contextCoordinates(xunit, hole);
const eqpnoList = useMemo(() => damList ? new Array(damList.length).fill(0).map((o, index) => index) : [], [damList]);
// useEffect(() => {
// getList()
// }, [])
useEffect(() => {
getList()
}, [])
const getList = async () => {
const { code, data } = await httppost2(apiurl.zmjk.getList)
const { code, data } = await httppost2(apiurl.zmjk.video)
if (code !== 200) {
return
}
const obj = data[0] || {}
// getInformation(obj.gateCode)
// getDamData(obj.stcd)
getVideo(obj.gateCode)
// getVideo(obj.indexCode)
getVideoSrc(data[0]?.indexCode)
setData(obj)
}