1、修复bug
This commit is contained in:
@@ -17,6 +17,7 @@ public interface CommandMapper {
|
||||
|
||||
Boolean stopCommandsByTaskId(@Param("task_id") Long taskId);
|
||||
|
||||
@DS("doris")
|
||||
Boolean removeCommandsByTaskId(@Param("task_id") Long taskId);
|
||||
|
||||
Boolean startCommandsByTaskId(@Param("task_id") Long taskId);
|
||||
|
||||
@@ -122,6 +122,10 @@ public class WhiteListService {
|
||||
}
|
||||
|
||||
public Integer updateWhiteListObject(Integer id, WhiteListObject object) {
|
||||
Integer auditStatus = whiteListMapper.queryWhiteListObjectAuditStuatusById(id);
|
||||
if (auditStatus == null) {
|
||||
throw new IllegalArgumentException("无法找到白名单 " + id + ", 可能该白名单不存在");
|
||||
}
|
||||
if (!whiteListMapper.queryWhiteListObjectAuditStuatusById(id).equals(AuditStatusEnum.AUDITED.getNum())) {
|
||||
throw new IllegalStateException("无法修改白名单信息,因为其并未处于" + AuditStatusEnum.AUDITED + "状态");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user