Merge branch 'refs/heads/feature/DM/nflg-bom-transition' into dev
This commit is contained in:
commit
92fabbd964
|
|
@ -233,7 +233,8 @@ public class BomNewPbomExportToSAPImpl implements IBomNewPbomExportToSAP {
|
||||||
LOGGER.debug("{} 物料提层到顶级发货包且合并 编号:{},父级编号:{},数量:{},合并后总数:{},描述:{}", TAG, it.getMaterialNo(), p.getMaterialNo(), it.getNum().toString(), cct.getMENGE(), it.getMaterialDesc());
|
LOGGER.debug("{} 物料提层到顶级发货包且合并 编号:{},父级编号:{},数量:{},合并后总数:{},描述:{}", TAG, it.getMaterialNo(), p.getMaterialNo(), it.getNum().toString(), cct.getMENGE(), it.getMaterialDesc());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else if (!Objects.equals(it.getVirtualPartType(), VirtualPackageTypeEnum.DIRECT_DELIVERY_PACKAGE.getValue())) {
|
// } else if (!Objects.equals(it.getVirtualPartType(), VirtualPackageTypeEnum.DIRECT_DELIVERY_PACKAGE.getValue())) {
|
||||||
|
} else {
|
||||||
LOGGER.debug("{} 添加物料 编号:{},父级编号:{},数量:{},描述:{}", TAG, it.getMaterialNo(), p.getMaterialNo(), it.getNum().toString(), it.getMaterialDesc());
|
LOGGER.debug("{} 添加物料 编号:{},父级编号:{},数量:{},描述:{}", TAG, it.getMaterialNo(), p.getMaterialNo(), it.getNum().toString(), it.getMaterialDesc());
|
||||||
children.add(convert(cp, it, p.getMaterialNo(), ignore));
|
children.add(convert(cp, it, p.getMaterialNo(), ignore));
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -135,7 +135,7 @@ public abstract class EBomToPbomBase {
|
||||||
|
|
||||||
List<BomNewEbomParentVO> result = child.stream().filter(u -> StrUtil.isBlank(u.getMaterialNo())).collect(Collectors.toList());
|
List<BomNewEbomParentVO> result = child.stream().filter(u -> StrUtil.isBlank(u.getMaterialNo())).collect(Collectors.toList());
|
||||||
|
|
||||||
Map<String, List<BomNewEbomParentVO>> listMp = child.stream().collect(Collectors.groupingBy(BomNewEbomParentVO::getMaterialNo));
|
Map<String, List<BomNewEbomParentVO>> listMp = child.stream().filter(u->StrUtil.isNotBlank(u.getMaterialNo())).collect(Collectors.groupingBy(BomNewEbomParentVO::getMaterialNo));
|
||||||
|
|
||||||
for (String key : listMp.keySet()) {
|
for (String key : listMp.keySet()) {
|
||||||
List<BomNewEbomParentVO> voList = listMp.get(key);
|
List<BomNewEbomParentVO> voList = listMp.get(key);
|
||||||
|
|
|
||||||
|
|
@ -335,25 +335,25 @@ public class OriginalBomToEBomV2Convert extends BaseConvert {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
protected BomNewEbomChildEntity buildCommonEbomChildEntity(BaseMaterialVO material, BomOriginalListVO parent) {
|
protected BomNewEbomChildEntity buildCommonEbomChildEntity(BaseMaterialVO material, BomOriginalListVO parentV) {
|
||||||
BomNewEbomChildEntity childEntity = new BomNewEbomChildEntity();
|
BomNewEbomChildEntity childEntity = new BomNewEbomChildEntity();
|
||||||
childEntity.setParentRowId(parent.getEBomRowId() > 0 ? parent.getEBomRowId() : parent.getRowId());
|
childEntity.setParentRowId(parentV.getEBomRowId() > 0 ? parentV.getEBomRowId() : parentV.getRowId());
|
||||||
childEntity.setOrderNumber("001");
|
childEntity.setOrderNumber("001");
|
||||||
childEntity.setIdentityNo(StrUtil.join("-", parent.getMaterialNo(), material.getMaterialNo()));
|
childEntity.setIdentityNo(StrUtil.join("-", parentV.getMaterialNo(), material.getMaterialNo()));
|
||||||
//图号=物料编码
|
//图号=物料编码
|
||||||
childEntity.setDrawingNo(material.getMaterialNo());
|
childEntity.setDrawingNo(material.getMaterialNo());
|
||||||
childEntity.setMaterialNo(material.getMaterialNo());
|
childEntity.setMaterialNo(material.getMaterialNo());
|
||||||
childEntity.setMaterialName(material.getMaterialName());
|
childEntity.setMaterialName(material.getMaterialName());
|
||||||
childEntity.setMaterialDesc(material.getMaterialDesc());
|
childEntity.setMaterialDesc(material.getMaterialDesc());
|
||||||
childEntity.setMaterialTexture(material.getMaterial());
|
childEntity.setMaterialTexture(material.getMaterial());
|
||||||
childEntity.setUnitWeight(parent.getUnitWeight());
|
childEntity.setUnitWeight(parentV.getUnitWeight());
|
||||||
childEntity.setNum(parent.getUnitWeight());
|
childEntity.setNum(parentV.getUnitWeight());
|
||||||
childEntity.setCreatedBy(SessionUtil.getUserCode());
|
childEntity.setCreatedBy(SessionUtil.getUserCode());
|
||||||
childEntity.setMaterialUnit("KG");
|
childEntity.setMaterialUnit("KG");
|
||||||
childEntity.setProjectType("L");
|
childEntity.setProjectType("L");
|
||||||
childEntity.setMaterialOriginalUnit(material.getMaterialUnit());
|
childEntity.setMaterialOriginalUnit(material.getMaterialUnit());
|
||||||
childEntity.setSourceRowId(parent.getRowId().toString());
|
childEntity.setSourceRowId(parentV.getRowId().toString());
|
||||||
parent.setBomExist(1);
|
parentV.setBomExist(1);
|
||||||
|
|
||||||
// this.eBomChildResult.add(childEntity);
|
// this.eBomChildResult.add(childEntity);
|
||||||
return childEntity;
|
return childEntity;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue