转EBOM时- PBOM发布报错修复2

This commit is contained in:
大米 2024-08-28 08:30:51 +08:00
parent 3a25f5d4bb
commit ba1209700a
1 changed files with 2 additions and 5 deletions

View File

@ -326,11 +326,8 @@ public class BomNewPbomParentService extends ServiceImpl<BomNewPbomParentMapper,
List<String> materialNos = parentChild.stream().map(BaseMaterialVO::getMaterialNo).collect(Collectors.toList());
if (CollUtil.isNotEmpty(materialNos)) {
List<BomNewPbomParentEntity> list = this.lambdaQuery().in(BomNewPbomParentEntity::getMaterialNo, materialNos)
// .eq(PBomStatusEnum.PUBLISH.equalsValue(parent.getStatus()), BomNewPbomParentEntity::getLastVersionIs, 1)
// .lt(!PBomStatusEnum.PUBLISH.equalsValue(parent.getStatus()),BomNewPbomParentEntity::getStatus,PBomStatusEnum.PUBLISH.getValue())
// .eq(PBomStatusEnum.PUBLISH.equalsValue(parent.getStatus()),BomNewPbomParentEntity::getStatus, PBomStatusEnum.PUBLISH.getValue())
.eq(PBomStatusEnum.PUBLISH.getValue() > parent.getStatus(), BomNewPbomParentEntity::getLastVersionIs, 1)
.ge(PBomStatusEnum.PUBLISH.getValue() <= parent.getStatus(), BomNewPbomParentEntity::getStatus, PBomStatusEnum.PUBLISH.getValue())
.eq(type.equals(0), BomNewPbomParentEntity::getLastVersionIs, 1)
.ge(type.equals(1), BomNewPbomParentEntity::getStatus, PBomStatusEnum.PUBLISH.getValue())
.eq(BomNewPbomParentEntity::getFacCode,parent.getFacCode())
.list();