From 1273d9cc504357860ebf7e52213dcdb209cca63c Mon Sep 17 00:00:00 2001 From: wenlele Date: Wed, 10 May 2023 17:57:07 +0800 Subject: [PATCH] =?UTF-8?q?=E9=82=AE=E4=BB=B6=E5=91=8A=E8=AD=A6=E6=BA=90?= =?UTF-8?q?=E5=90=8D=E7=A7=B0=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/app/lib/schedule/alarms_push.js | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/api/app/lib/schedule/alarms_push.js b/api/app/lib/schedule/alarms_push.js index b6bb99d..197c838 100644 --- a/api/app/lib/schedule/alarms_push.js +++ b/api/app/lib/schedule/alarms_push.js @@ -1113,6 +1113,9 @@ module.exports = function (app, opts) { ` ).toPromise() || [] + console.log('当前结构物下所有告警', alarmDatas); + console.log('监测因素', factorData); + console.log('结构物对应的设备', equipment); equipment.map(f => { f.alarmDatas = [] @@ -1187,20 +1190,20 @@ module.exports = function (app, opts) { } f.rowspan = rowspan3 }) - x.factor = x.factor.filter(b => b.devices && b.devices.length>0) + x.factor = x.factor.filter(b => b.devices && b.devices.length > 0) } else { delete x.factor } x.rowspan = rowspan2 }) - h.projects = h.projects.filter(b => b.factor && b.factor.length>0) + h.projects = h.projects.filter(b => b.factor && b.factor.length > 0) } else { delete h.projects } h.rowspan = rowspan1 }) - - dataAlarmG1 = pepProject_name.filter(b => b.projects && b.projects.length>0)||[] + + dataAlarmG1 = pepProject_name.filter(b => b.projects && b.projects.length > 0) || [] } @@ -1219,7 +1222,7 @@ module.exports = function (app, opts) { if (type == 1) { - + alarmData.map((h, hi) => { if (h.projects && h.projects.length) {