diff --git a/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/BomNewPbomParentService.java b/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/BomNewPbomParentService.java index 6ea99e8b..6a499d88 100644 --- a/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/BomNewPbomParentService.java +++ b/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/BomNewPbomParentService.java @@ -398,7 +398,7 @@ public class BomNewPbomParentService extends ServiceImpl mMap = materialService.batchAddMaterial(ImmutableList.of(toM)); // String materialNo = materialService.addMaterial(drawingNo, materialName, materialDesc, "201201"); String materialNo=mMap.get(key).getMaterialNo(); - return materialMainService.getMaterialBaseInfo(ImmutableList.of(materialNo)).get(0); + BaseMaterialVO resultD = materialMainService.getMaterialBaseInfo(ImmutableList.of(materialNo)).get(0); + //插入工艺包 + packageParam.setTechnologyPackageMaterialNo(materialNo); + insertTechnologyPackage(packageParam); + + return resultD; } @Transactional(rollbackFor = Exception.class) diff --git a/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/MaterialService.java b/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/MaterialService.java index b9d39887..7ece978c 100644 --- a/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/MaterialService.java +++ b/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/MaterialService.java @@ -381,7 +381,7 @@ public class MaterialService { if (optional.isPresent()) { OaResult oaResult = optional.get(); materialMainEntity.setOaRowId(oaResult.getInstId()); - materialMainEntity.setProcessState(100); + // materialMainEntity.setProcessState(10); } } materialMainService.updateBatchById(entityList); diff --git a/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/PBom/ConvertToMBom.java b/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/PBom/ConvertToMBom.java index b9de2283..1dfb0efb 100644 --- a/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/PBom/ConvertToMBom.java +++ b/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/PBom/ConvertToMBom.java @@ -163,9 +163,9 @@ public class ConvertToMBom { * * @param */ - private void handEmptyMakePackage() { + private void handEmptyMakePackage(List childBomTree) { - List childBomTree = ConvertToMbomUtil.toTree(parent.getRowId(), allChildTreeList_1020, ConvertToMBomDTO::getRelParentRowId, ConvertToMBomDTO::getBomRowId); +// List childBomTree = ConvertToMbomUtil.toTree(parent.getRowId(), allChildTreeList_1020, ConvertToMBomDTO::getRelParentRowId, ConvertToMBomDTO::getBomRowId); for (ConvertToMBomDTO item : childBomTree) { if (VirtualPackageTypeEnum.DELIVERY_PACKAGE.equalsValue(item.getVirtualPartType())) { List makeChild = item.getChildNodes().stream().filter(u -> VirtualPackageTypeEnum.MAKING_PACKAGE.equalsValue(u.getVirtualPartType())).collect(Collectors.toList()); @@ -231,7 +231,7 @@ public class ConvertToMBom { recursionHandlerChild1020(item, directDeliveryPackage); } //处理制作包无下级的情况 - handEmptyMakePackage(); + handEmptyMakePackage(childBomTree); }