From e2faeb2d059917e3e8d632d7858b71be9ad9156c Mon Sep 17 00:00:00 2001 From: joylink_fanyuhong <18706759286@163.com> Date: Mon, 18 Nov 2024 17:29:46 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A0=B9=E6=8D=AE=E7=8A=B6=E6=80=81=E5=88=A4?= =?UTF-8?q?=E6=96=AD=E6=98=AF=E5=90=A6=E6=98=BE=E7=A4=BA=E6=95=85=E9=9A=9C?= =?UTF-8?q?=E6=97=B6=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/LineMonitorPage.vue | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) diff --git a/src/pages/LineMonitorPage.vue b/src/pages/LineMonitorPage.vue index 35f7174..64093d5 100644 --- a/src/pages/LineMonitorPage.vue +++ b/src/pages/LineMonitorPage.vue @@ -96,10 +96,28 @@ watch( (val) => { if (val.length) { centerFaultDevice(); - val.forEach((info) => { - alarmInfoList.push(info); - }); - faultInfo.value = true; + const lineState = lineNetStore.connectInfo?.msgs.find( + (msg) => msg.lineId == lineId + ); + // console.log(lineState, 'line'); + if (lineState?.atsWarnShowCounter) { + val.forEach((info) => { + alarmInfoList.push(info); + }); + faultInfo.value = true; + } + } + } +); + +watch( + () => lineNetStore.connectInfo, + (val) => { + if (val?.msgs) { + const lineState = val.msgs.find((msg) => msg.lineId == lineId); + if (!lineState?.atsWarnShowCounter) { + faultInfo.value = false; + } } } );