From bc7b84f78c6c85ed341d0c40456c51a92d6cb3a0 Mon Sep 17 00:00:00 2001 From: wenlele Date: Sun, 9 Oct 2022 18:00:23 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=A7=E5=9B=BE=E5=B1=95=E7=A4=BA=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../sections/problem/components/inspection.jsx | 18 +++--------------- .../sections/problem/containers/dataAlarm.jsx | 8 +++++--- 2 files changed, 8 insertions(+), 18 deletions(-) diff --git a/web/client/src/sections/problem/components/inspection.jsx b/web/client/src/sections/problem/components/inspection.jsx index a129dee..9d567e5 100644 --- a/web/client/src/sections/problem/components/inspection.jsx +++ b/web/client/src/sections/problem/components/inspection.jsx @@ -86,7 +86,6 @@ const Inspection = ({ dispatch, actions, user, route, statistic }) => { dispatch(problem.putAlarmApplicationNoted({ inspectionId: patrolAbnormal[pictureId].id })) } }, 2000) - setPictureData(patrolAbnormal[pictureId]) } }, [pictureId]); @@ -103,19 +102,6 @@ const Inspection = ({ dispatch, actions, user, route, statistic }) => {
{ - // console.log({ - // appId: v.appId, - // noted: v.noted, - // projectId: v.projectId, - // timeStart: v.time == 'true' ? - // moment().startOf('day').format('YYYY-MM-DD HH:mm:ss') : - // v.time == 'false' ? - // moment().day(moment().day() - 1).startOf('day').format('YYYY-MM-DD HH:mm:ss') : "", - // timeEnd: v.time == 'true' ? - // moment().endOf('day').format('YYYY-MM-DD HH:mm:ss') : - // v.time == 'false' ? - // moment().day(moment().day() - 1).endOf('day').format('YYYY-MM-DD HH:mm:ss') : "", - // }); setCheckPatrol({ appId: v.appId, noted: v.noted, @@ -223,6 +209,7 @@ const Inspection = ({ dispatch, actions, user, route, statistic }) => { onClick={() => { setPicturePop(true) setPictureId(i); + setPictureData(patrolAbnormal[i]) }} > @@ -254,7 +241,7 @@ const Inspection = ({ dispatch, actions, user, route, statistic }) => { }}>{unfold ? '展开更多' : '收起'}
{picturePop ? {pictureData.app?.name} + title={
{pictureData?.app?.name} { width={837} onCancel={() => { setPicturePop(false) + setPictureId('') if (timer) clearTimeout(timer) }} > diff --git a/web/client/src/sections/problem/containers/dataAlarm.jsx b/web/client/src/sections/problem/containers/dataAlarm.jsx index f5303f4..e4699fb 100644 --- a/web/client/src/sections/problem/containers/dataAlarm.jsx +++ b/web/client/src/sections/problem/containers/dataAlarm.jsx @@ -60,9 +60,11 @@ const DataAlarm = ({ match, dispatch, actions, user, loading, socket, iotVcmpWeb attribute(tableType[route], route); //视频平台token - dispatch(problem.getVcmpAuth({})).then((res) => { - if (res.success) setVideoToken(res.payload.data?.token) - }) + if (route == 'videoAbnormal') { + dispatch(problem.getVcmpAuth({})).then((res) => { + if (res.success) setVideoToken(res.payload.data?.token) + }) + } }, []) // console.log(videoData);