|
@ -181,7 +181,7 @@ async function edit (ctx) { |
|
|
if (pushId) { |
|
|
if (pushId) { |
|
|
repeatOption.where.id = { $ne: pushId } |
|
|
repeatOption.where.id = { $ne: pushId } |
|
|
} |
|
|
} |
|
|
let repeatRes = await models.findOne(repeatOption) |
|
|
let repeatRes = await models.AlarmPushConfig.findOne(repeatOption) |
|
|
if (repeatRes) { |
|
|
if (repeatRes) { |
|
|
throw `已有名称为[${name}]的同名策略` |
|
|
throw `已有名称为[${name}]的同名策略` |
|
|
} |
|
|
} |
|
|