From 883c1d881768f65795c4aabf846a6d58d10cb199 Mon Sep 17 00:00:00 2001 From: "gao.zhiyuan" Date: Thu, 17 Nov 2022 15:05:46 +0800 Subject: [PATCH] =?UTF-8?q?fix=20=E5=BA=94=E7=94=A8=E5=91=8A=E8=AD=A6limit?= =?UTF-8?q?=20=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/app/lib/controllers/alarm/app.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/api/app/lib/controllers/alarm/app.js b/api/app/lib/controllers/alarm/app.js index 8e989df..c035bbe 100644 --- a/api/app/lib/controllers/alarm/app.js +++ b/api/app/lib/controllers/alarm/app.js @@ -301,12 +301,13 @@ async function apiErrorList (ctx) { findOption.where.$or.push( { '$app.name$': { $like: `%${keyword}%` } - } + }, ) } else { - findOption.where['$app->projectCorrelations.id$'] = { - $in: pomsProjectIds - } + // findOption.where['$app->projectCorrelations.id$'] = { + // $in: pomsProjectIds + // } + findOption.include[0].include[0].where.id = { $in: pomsProjectIds } } if (errType) { @@ -371,7 +372,7 @@ async function apiErrorList (ctx) { } } -async function exportAppAlarms(ctx, listRes) { +async function exportAppAlarms (ctx, listRes) { let typeData = { element: "元素异常", apiError: "接口报错 ", timeout: "加载超时" } try { const { utils: { simpleExcelDown, getExportAlarmHeader } } = ctx.app.fs;