pbom-用户跟节点问题修复

This commit is contained in:
luolm 2024-10-13 20:46:36 +08:00
parent 901a68d2b7
commit 21a75d6726
1 changed files with 11 additions and 0 deletions

View File

@ -1060,6 +1060,12 @@ public class BomNewEbomParentService extends ServiceImpl<BomNewEbomParentMapper,
} }
if (CollUtil.isNotEmpty(eBomToPBom.getPBomParentResult())) { if (CollUtil.isNotEmpty(eBomToPBom.getPBomParentResult())) {
//将物料标记为用户跟节点
List<BomNewPbomParentEntity> rootParent = eBomToPBom.getPBomParentResult().stream().filter(u -> u.getMaterialNo().equals(parent.getMaterialNo())).collect(Collectors.toList());
if(CollUtil.isNotEmpty(rootParent)) {
rootParent.get(0).setUserRootIs(1);
}
pBomParentService.saveOrUpdateBatch(eBomToPBom.getPBomParentResult()); pBomParentService.saveOrUpdateBatch(eBomToPBom.getPBomParentResult());
} }
@ -1258,6 +1264,11 @@ public class BomNewEbomParentService extends ServiceImpl<BomNewEbomParentMapper,
if (CollUtil.isNotEmpty(eBomToPBom.getPBomParentResult())) { if (CollUtil.isNotEmpty(eBomToPBom.getPBomParentResult())) {
//将物料标记为用户跟节点
List<BomNewPbomParentEntity> rootParent = eBomToPBom.getPBomParentResult().stream().filter(u -> u.getMaterialNo().equals(parent.getMaterialNo())).collect(Collectors.toList());
if(CollUtil.isNotEmpty(rootParent)) {
rootParent.get(0).setUserRootIs(1);
}
pBomParentService.saveOrUpdateBatch(eBomToPBom.getPBomParentResult()); pBomParentService.saveOrUpdateBatch(eBomToPBom.getPBomParentResult());
} }