Browse Source

修复消息通知错误

master
xuye 1 year ago
parent
commit
ff8ea10dbd
1 changed files with 6 additions and 8 deletions
  1. +6
    -8
      sink/src/main/java/work/xuye/sink/handler/DisappearHandler.java

+ 6
- 8
sink/src/main/java/work/xuye/sink/handler/DisappearHandler.java View File

@@ -78,14 +78,12 @@ public class DisappearHandler {
SinkParams.DisappearConfig disappearConfig = task.getSinkParams().getCheckDelete().getDisappearConfig();

// 处理自动/手动删除,生成通知标题
if (disappearConfig.isAutoDeleteEnabled()) {
if (disappearConfig.getAutoDeleteThreshold() >= removed.size()) {
sqlExecutor.executeSql(sqlEntity.getId(), sqlEntity.getCaptcha());
autoDeleted = true;
messageTitle = "已经自动删除 " + taskName + " 已删除的资讯";
} else {
messageTitle = "检测到 " + taskName + " 已删除的资讯,条数超过自动删除阈值,未执行删除,请手动处理";
}
if (disappearConfig.isAutoDeleteEnabled() && disappearConfig.getAutoDeleteThreshold() >= removed.size()) {
sqlExecutor.executeSql(sqlEntity.getId(), sqlEntity.getCaptcha());
autoDeleted = true;
messageTitle = "已经自动删除 " + taskName + " 已删除的资讯";
} else {
messageTitle = "检测到 " + taskName + " 已删除的资讯,条数超过自动删除阈值,未执行删除,请手动处理";
}

// 根据模板,生成通知内容


Loading…
Cancel
Save