|
|
@@ -292,8 +292,11 @@ public class ProjectFileManage { |
|
|
|
// 创建ZipOutputStream |
|
|
|
ZipOutputStream zos = new ZipOutputStream(response.getOutputStream()); |
|
|
|
if (CollUtil.isNotEmpty(fileIdList)) { |
|
|
|
// 对文件ID进行去重 |
|
|
|
HashSet<Long> hashSet = new HashSet<>(); |
|
|
|
List<Long> fidList = fileIdList.stream().filter(hashSet::add).collect(Collectors.toList()); |
|
|
|
// 获取文件输入流 |
|
|
|
for (Long fileId : fileIdList) { |
|
|
|
for (Long fileId : fidList) { |
|
|
|
File file = fileService.getById(fileId); |
|
|
|
// 文件不存在,跳过 |
|
|
|
if (Objects.isNull(file)) { |
|
|
|