From 93b20481ae90f83a6fc2aeb72b66faad42ce6379 Mon Sep 17 00:00:00 2001 From: wenlele Date: Mon, 28 Nov 2022 16:57:01 +0800 Subject: [PATCH 1/2] =?UTF-8?q?EM=E6=8E=A8=E9=80=81=E6=A0=B7=E5=BC=8F?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/client/src/sections/service/components/pushModal.jsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/client/src/sections/service/components/pushModal.jsx b/web/client/src/sections/service/components/pushModal.jsx index 7bb780f..3026a1e 100644 --- a/web/client/src/sections/service/components/pushModal.jsx +++ b/web/client/src/sections/service/components/pushModal.jsx @@ -202,7 +202,7 @@ function pushModal (props) {
{ for (var key in field) { if (key == 'tactics') { @@ -370,7 +370,7 @@ function pushModal (props) { 分钟,则通过【信鸽服务】发送一条通知信息。 } - style={{ width: 198 }}> + style={{ width: 173 }}> 持续时长推送机制 Date: Tue, 29 Nov 2022 10:56:43 +0800 Subject: [PATCH 2/2] =?UTF-8?q?bug=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/sections/service/components/pushModal.jsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/web/client/src/sections/service/components/pushModal.jsx b/web/client/src/sections/service/components/pushModal.jsx index 3026a1e..b237879 100644 --- a/web/client/src/sections/service/components/pushModal.jsx +++ b/web/client/src/sections/service/components/pushModal.jsx @@ -35,6 +35,7 @@ function pushModal (props) { const [deviceProportion, setDeviceProportion] = useState(undefined); // const [subType, setSubType] = useState([]); //监听模块中的子类 const [factorShow, setFactorShow] = useState([]); //结构物对应监测项 + const [firstPass, setFirstPass] = useState(true) //初始化 @@ -89,10 +90,7 @@ function pushModal (props) { } }) setProjectStructure(data) - - if (!editObj.id) { - form.current.setValue('strucId', ProjectId) - } else { + if (editObj.id && firstPass) { let FactorId = [] if (alter?.pomsStrucFactorId) { for (let key in alter?.pomsStrucFactorId) { @@ -102,6 +100,9 @@ function pushModal (props) { } else { setFactorShow(ProjectId) } + setFirstPass(false) + } else { + form.current.setValue('strucId', ProjectId) } form.current.validate(['strucId', 'timeType']) setStructure(false) @@ -400,7 +401,6 @@ function pushModal (props) { 异常率推送机制 -