电控系统发货包优化9.18
This commit is contained in:
parent
2af307b195
commit
bebe0e3fe6
|
|
@ -141,14 +141,17 @@ public class BomNewPbomExportToSAPImpl implements IBomNewPbomExportToSAP {
|
||||||
|
|
||||||
private Long getZFBBomRowId(List<BomNewPbomChildEntity> children) {
|
private Long getZFBBomRowId(List<BomNewPbomChildEntity> children) {
|
||||||
Long ddpRowId = null;
|
Long ddpRowId = null;
|
||||||
|
//电控系统的无须增加 直发包parent记录 by 10002327 240918
|
||||||
BomNewPbomChildEntity czfb = children.stream()
|
BomNewPbomChildEntity czfb = children.stream()
|
||||||
.filter(c -> Objects.equals(c.getVirtualPartType(), VirtualPackageTypeEnum.DIRECT_DELIVERY_PACKAGE.getValue()))
|
.filter(c -> Objects.equals(c.getVirtualPartType(), VirtualPackageTypeEnum.DIRECT_DELIVERY_PACKAGE.getValue())
|
||||||
|
&& !c.getMaterialDesc().contains("电控系统"))
|
||||||
.findFirst()
|
.findFirst()
|
||||||
.orElse(null);
|
.orElse(null);
|
||||||
if (Objects.nonNull(czfb)) {
|
if (Objects.nonNull(czfb)) {
|
||||||
BomNewPbomParentEntity cpttp = getParent(czfb);
|
BomNewPbomParentEntity cpttp = getParent(czfb);
|
||||||
// VUtils.isTure(Objects.isNull(cpttp)).throwMessage(StrUtil.format("顶层直发包({})对应的parent丢失", czfb.getMaterialNo()));
|
// VUtils.isTure(Objects.isNull(cpttp)).throwMessage(StrUtil.format("顶层直发包({})对应的parent丢失", czfb.getMaterialNo()));
|
||||||
if (Objects.isNull(cpttp)) {
|
|
||||||
|
if (Objects.isNull(cpttp) ) {
|
||||||
//添加直发包的parent
|
//添加直发包的parent
|
||||||
cpttp = addZFBParent(czfb);
|
cpttp = addZFBParent(czfb);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -514,8 +514,9 @@ public class DQBomService {
|
||||||
buildTree(root, parents, children);
|
buildTree(root, parents, children);
|
||||||
dQBomParentService.updateBatchById(parents);
|
dQBomParentService.updateBatchById(parents);
|
||||||
dQBomChildService.updateBatchById(children);
|
dQBomChildService.updateBatchById(children);
|
||||||
savePbomParents(parents, root.getMaterialNo().startsWith("31") ? PBomStatusEnum.FACTORY_CONFIRM : PBomStatusEnum.PUBLISH);
|
//电气BOM发布正式版之后,不再写入导入PBOM中 by 10002327 240914
|
||||||
savePbomChildren(children, parents);
|
//savePbomParents(parents, root.getMaterialNo().startsWith("31") ? PBomStatusEnum.FACTORY_CONFIRM : PBomStatusEnum.PUBLISH);
|
||||||
|
//savePbomChildren(children, parents);
|
||||||
|
|
||||||
// CompletableFuture.runAsync(() -> {
|
// CompletableFuture.runAsync(() -> {
|
||||||
// bomNewPbomParentService.getBaseMapper().updatePBomMaterialUse();
|
// bomNewPbomParentService.getBaseMapper().updatePBomMaterialUse();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue