feat(mapper): 添加物理删除功能并优化垃圾清理逻辑
- 在 GroupingMapper 和 MarkdownFileMapper 中添加物理删除方法 - 修改 TrashServiceImpl 中的 cleanTrash 方法,使用新增的物理删除方法 -优化了垃圾清理的 SQL 执行效率
This commit is contained in:
@@ -23,4 +23,6 @@ public interface GroupingMapper extends BaseMapper<Grouping> {
|
||||
|
||||
@Update("UPDATE grouping SET is_deleted = 0, deleted_at = NULL, deleted_by = NULL WHERE id = #{id}")
|
||||
void restoreById(@Param("id") Long id);
|
||||
@Delete("DELETE FROM grouping WHERE is_deleted = 1")
|
||||
void physicalDeleteByIsDeleted();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user