修改法规清单-导入检查重复编号问题

This commit is contained in:
gaosong
2022-08-23 02:08:33 +08:00
parent 3e6213ee94
commit e9a74c4025
@@ -4755,10 +4755,12 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl<ProjectLawsIn
//存在文档库没有的数据
List<String> collect = bussDocumentLibraryEOList.stream().map(BussDocumentLibraryEO::getSerialNumber).collect(Collectors.toList());
List<String> serialNumbers = serialNumberList.stream().filter(e -> !collect.contains(e)).collect(Collectors.toList());
if(CutEnum.CN.getValue().equals(dataList.get(0).getCut())){
throw new JeroBootException(StringUtils.join(serialNumbers,",")+"文档库中不存在,不能添加");
}else{
throw new JeroBootException(StringUtils.join(serialNumbers,",")+" does not exist in the document library and cannot be added");
if(serialNumbers.size() > 0){
if(CutEnum.CN.getValue().equals(dataList.get(0).getCut())){
throw new JeroBootException(StringUtils.join(serialNumbers,",")+"文档库中不存在,不能添加");
}else{
throw new JeroBootException(StringUtils.join(serialNumbers,",")+" does not exist in the document library and cannot be added");
}
}
}