Browse Source

fix 应用告警关键字查询

dev
巴林闲侠 2 years ago
parent
commit
cb119faa3b
  1. 18
      api/app/lib/controllers/alarm/app.js

18
api/app/lib/controllers/alarm/app.js

@ -249,16 +249,14 @@ async function apiErrorList (ctx) {
${pepProjectSql}
WHERE project_name LIKE '%${keyword}%'`
).toPromise()
if (projectRes.length) {
findOption.where.$or.push(
{
'$app->projectCorrelations.pep_project_id$': {
$in: projectRes.map(p => p.id)
},
'$app.name$': { $like: `%${keyword}%` }
}
)
}
findOption.where.$or.push(
{
'$app->projectCorrelations.pep_project_id$': {
$in: projectRes.map(p => p.id)
},
'$app.name$': { $like: `%${keyword}%` }
}
)
}
// if (errType) {

Loading…
Cancel
Save