fix: [excel-105]添加判断

This commit is contained in:
曹鹏飞 2024-04-18 14:33:07 +08:00
parent 998ac9bc50
commit b0c88ccb24
1 changed files with 4 additions and 1 deletions

View File

@ -418,7 +418,10 @@ public class BomNewPbomParentService extends ServiceImpl<BomNewPbomParentMapper,
}
//删除辅助物料
List<BomNewPbomParentVO> noDelList = childListVO.stream()
.filter(u -> !u.getMaterialCategoryCode().startsWith("1003") && !u.getMaterialCategoryCode().startsWith("1020") && !u.getMaterialCategoryCode().startsWith("1021"))
.filter(u -> !u.getMaterialCategoryCode().startsWith("1003")
&& !u.getMaterialCategoryCode().startsWith("1020")
&& !u.getMaterialCategoryCode().startsWith("1021")
&& !u.getMaterialCategoryCode().equals(MaterialMainConstant.CATEGORYCODE_TECHNOLOGYPACKAGE))
.collect(Collectors.toList());
VUtils.isTure(CollUtil.isNotEmpty(noDelList)).throwMessage("非机加工件的子级只能删除辅助物料");