优化规则文件,优化文件删除日志记录
This commit is contained in:
@@ -30,6 +30,7 @@ import xtools.boot.api.model.dto.req.IdListReq;
|
||||
import xtools.boot.db.mybatisplus.utils.QueryUtils;
|
||||
import xtools.boot.log.LogBus;
|
||||
import xtools.boot.log.enums.LogBusBaseType;
|
||||
import xtools.boot.log.holder.LogTrackHolder;
|
||||
import xtools.boot.storage.base.config.StorageConfig;
|
||||
import xtools.boot.storage.base.service.StorageService;
|
||||
import xtools.boot.task.TaskBus;
|
||||
@@ -361,6 +362,7 @@ public class SysFileServiceImpl implements SysFileService, BaseParams {
|
||||
}
|
||||
String type = storageConfig.getType();
|
||||
Set<Long> ids = new HashSet<>(list.size());
|
||||
LogTrackHolder.saveLog(false);
|
||||
for (SysFile item : list) {
|
||||
if (!Objects.equals(type, item.getStorageType())) {
|
||||
continue;
|
||||
@@ -373,6 +375,7 @@ public class SysFileServiceImpl implements SysFileService, BaseParams {
|
||||
}
|
||||
ids.add(item.getId());
|
||||
}
|
||||
LogTrackHolder.saveLog(true);
|
||||
return sysFileBaseService.getBaseMapper().deleteByIds(ids);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user