This commit is contained in:
ran.shang
2026-01-24 23:22:21 +08:00
parent d5cb399e8c
commit 673a211619
69 changed files with 333 additions and 2946 deletions

View File

@@ -245,7 +245,7 @@ public class UserFileServiceImpl implements UserFileService {
}
// 2.2 在SQL中一次性更新当前节点和所有子孙节点的path(SQL内部会限制相同userId和rootType)
userFileMapper.updatePathByParentIdChange(id, newParentId);
userFileMapper.updatePathByParentIdChange(id, newParentId, modifyDTO.getOperateUserId());
}
// 3. 更新文件信息
@@ -305,6 +305,18 @@ public class UserFileServiceImpl implements UserFileService {
remove(id);
}
@Override
@Transactional
public void removeByIds(List<Long> ids, Long userId) {
Assert.notEmpty(ids, "文件ID列表不能为空");
Assert.notNull(userId, "用户ID不能为空");
// 循环删除每个文件
for (Long id : ids) {
remove(id, userId);
}
}
@Override
public List<UserFileDTO> list(UserFileQueryDTO queryDTO) {
queryDTO.disablePage();