fix(pbom): 修复导入到sap时,只导入了第一层的问题
This commit is contained in:
parent
1cb3869052
commit
207b1a6d44
|
|
@ -1117,7 +1117,11 @@ public class BomNewPbomParentService extends ServiceImpl<BomNewPbomParentMapper,
|
|||
|
||||
ImportSapParamDTO sapDto = new ImportSapParamDTO();
|
||||
sapDto.setZID(RandomUtil.randomNumbers(5));
|
||||
sapDto.setI_WERKS("1");
|
||||
if (StrUtil.equals(root.getFacCode(), EBomConstant.MAIN_FACTORY_CODE_1010)) {
|
||||
sapDto.setI_WERKS("1");
|
||||
} else if (StrUtil.equals(root.getFacCode(), EBomConstant.XIAN_TAO_FACTORY_CODE_1020)) {
|
||||
sapDto.setI_WERKS("2");
|
||||
}
|
||||
sapDto.setI_STLAN("1");
|
||||
sapDto.setI_EMPNO(root.getCreatedBy());
|
||||
List<T1DTO> t1s = new ArrayList<>();
|
||||
|
|
@ -1155,7 +1159,8 @@ public class BomNewPbomParentService extends ServiceImpl<BomNewPbomParentMapper,
|
|||
for (BomNewPbomChildEntity c : children) {
|
||||
BomNewPbomParentEntity cp = lambdaQuery()
|
||||
.eq(BomNewPbomParentEntity::getMaterialNo, c.getMaterialNo())
|
||||
.eq(BomNewPbomParentEntity::getStatus, EBomStatusEnum.PUBLISHED.getValue())
|
||||
.eq(BomNewPbomParentEntity::getFacCode, parent.getFacCode())
|
||||
.eq(BomNewPbomParentEntity::getStatus, PBomStatusEnum.FACTORY_CONFIRM.getValue())
|
||||
.orderByDesc(BomNewPbomParentEntity::getRowId)
|
||||
.last(" limit 1")
|
||||
.one();
|
||||
|
|
|
|||
Loading…
Reference in New Issue