From cddbb2f028970cab1b6c365c6903451e50e4d3d7 Mon Sep 17 00:00:00 2001 From: wenlele Date: Thu, 27 Oct 2022 17:37:22 +0800 Subject: [PATCH] =?UTF-8?q?topSerialNo=20=E8=A7=86=E9=A2=91=E8=AF=B7?= =?UTF-8?q?=E6=B1=82=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../api/app/lib/controllers/camera/index.js | 1 + .../src/components/videoPlayer/videoPlay.jsx | 20 +++++++++---------- code/VideoAccess-VCMP/web/package.json | 2 +- 3 files changed, 12 insertions(+), 11 deletions(-) diff --git a/code/VideoAccess-VCMP/api/app/lib/controllers/camera/index.js b/code/VideoAccess-VCMP/api/app/lib/controllers/camera/index.js index 4294f48..7971126 100644 --- a/code/VideoAccess-VCMP/api/app/lib/controllers/camera/index.js +++ b/code/VideoAccess-VCMP/api/app/lib/controllers/camera/index.js @@ -79,6 +79,7 @@ async function getCameraProject (ctx, next) { } if (serialNo) { findOption.where.serialNo = { $in: serialNo.split(',') } + findOption.where.topSerialNo = { $in: serialNo.split(',') } } if (state) { if (state == 'DISABLED') { diff --git a/code/VideoAccess-VCMP/web/client/src/components/videoPlayer/videoPlay.jsx b/code/VideoAccess-VCMP/web/client/src/components/videoPlayer/videoPlay.jsx index 2e5961e..44b1239 100644 --- a/code/VideoAccess-VCMP/web/client/src/components/videoPlayer/videoPlay.jsx +++ b/code/VideoAccess-VCMP/web/client/src/components/videoPlayer/videoPlay.jsx @@ -54,13 +54,14 @@ const VideoPlay = ({ dispatch, actions, // }, // videoObj = { - // type: 'cascade', - // audio: false, - // serialNo: '34020000001310000001', // 设备序列号 必须 - // topSerialNo: '34020000001320000001', // 设备顶级序列号 必须 - // playUrlSd: 'wss://221.230.55.27:8082/jessica/34020000001320000001/34020000001310000001', // 必须 - // // playUrlHd: 'ezopen://open.ys7.com/G75922040/1.hd.live', - // // replayUrl: 'ezopen://open.ys7.com/G75922040/1.rec', + // type: 'cascade', + // audio: false, + // cloudControl: true, + // serialNo: '34020000001310000001', // 设备序列号 必须 + // topSerialNo: '34020000001320000001', // 设备顶级序列号 必须 + // playUrlSd: 'wss://221.230.55.27:8082/jessica/34020000001320000001/34020000001310000001', // 必须 + // // playUrlHd: 'ezopen://open.ys7.com/G75922040/1.hd.live', + // // replayUrl: 'ezopen://open.ys7.com/G75922040/1.rec', // }, // @@ -68,7 +69,7 @@ const VideoPlay = ({ dispatch, actions, iotVideoPlayServer, local, //是否本地调用视频 }) => { - console.log('1754',videoObj); + // console.log('1754', videoObj); if (videoObj.type == 'yingshi') { videoObj = { ...videoObj, @@ -382,7 +383,6 @@ const VideoPlay = ({ dispatch, actions, videoAfter = new moment(); //验证后时间 console.log(11111, res) }) - } catch (error) { console.log(123151); console.log(error.response); @@ -449,7 +449,7 @@ const VideoPlay = ({ dispatch, actions, const pause = () => { if (videoObj.type == 'yingshi' && player) { - 5 + } else if (jessibuca) { jessibuca.pause(); setIsPlaying(false) diff --git a/code/VideoAccess-VCMP/web/package.json b/code/VideoAccess-VCMP/web/package.json index 90621ed..0ae4247 100644 --- a/code/VideoAccess-VCMP/web/package.json +++ b/code/VideoAccess-VCMP/web/package.json @@ -7,7 +7,7 @@ "test": "mocha", "start-vite": "cross-env NODE_ENV=developmentVite npm run start-params", "start": "cross-env NODE_ENV=development npm run start-params", - "start-params": "node server -p 5000 -u http://localhost:4000 --apiVcmpUrl http://localhost:4000 --apiAuthUrl http://localhost:4200 --apiAnxinyunUrl http://localhost:4100 --iotAuthWeb http://localhost:5200 --iotVideoServer https://iotmedia.anxinyun.cn --iotVideoPlayServer wss://221.230.55.27:8082", + "start-params": "node server -p 5000 -u http://localhost:4000 --apiVcmpUrl http://localhost:4000 --apiAuthUrl http://localhost:4200 --apiAnxinyunUrl http://localhost:4100 --iotAuthWeb http://localhost:5200 --iotVideoServer https://iotmedia.anxinyun.cn --iotVideoPlayServer wss://iotmedia.anxinyun.cn", "deploy": "export NODE_ENV=production&& npm run build && node server", "build-dev": "cross-env NODE_ENV=development&&webpack --config webpack.config.js", "build": "cross-env NODE_ENV=production&&webpack --config webpack.config.prod.js"