|
@@ -262,10 +262,26 @@ public class IotSapServiceImpl implements IotSapService {
|
|
});
|
|
});
|
|
// 将集合 pickingListHeads 设置成 Map<String, String> key领料单号 value成本中心
|
|
// 将集合 pickingListHeads 设置成 Map<String, String> key领料单号 value成本中心
|
|
Map<String, String> pickingCodeCostCenterPair = new HashMap<>();
|
|
Map<String, String> pickingCodeCostCenterPair = new HashMap<>();
|
|
|
|
+ Map<String, String> notExistCostCenters = new HashMap<>();
|
|
// 遍历主表
|
|
// 遍历主表
|
|
pickingListHeads.forEach(head -> {
|
|
pickingListHeads.forEach(head -> {
|
|
pickingCodeCostCenterPair.put(head.getZLTNO(), head.getKOSTL());
|
|
pickingCodeCostCenterPair.put(head.getZLTNO(), head.getKOSTL());
|
|
|
|
+ // 找出本地没有维护 过的成本中心
|
|
|
|
+ String originCostCenterCode = head.getKOSTL();
|
|
|
|
+ if (!costCenterIdPair.containsKey(originCostCenterCode)) {
|
|
|
|
+ String tempMsg = "当前系统没有维护的成本中心:-工厂- " + head.getWERKS()
|
|
|
|
+ + " -工厂名称- " + head.getTXTMD() + " -领料/退料编号- " + head.getZLTNO() + " -成本中心 编码- " + head.getKOSTL() + " -成本中心描述- " + head.getLTEXT();
|
|
|
|
+ notExistCostCenters.put(head.getKOSTL(), tempMsg);
|
|
|
|
+
|
|
|
|
+ }
|
|
});
|
|
});
|
|
|
|
+ // 打印不存在的成本中心集合 notExistCostCenters
|
|
|
|
+ if (CollUtil.isNotEmpty(notExistCostCenters)) {
|
|
|
|
+ notExistCostCenters.forEach((k,v) -> {
|
|
|
|
+ System.out.println(v);
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+
|
|
// 领料单表不合并物料数量、单价 todo(审核入本地库时 合并相同成本中心下的物料数量 单价)
|
|
// 领料单表不合并物料数量、单价 todo(审核入本地库时 合并相同成本中心下的物料数量 单价)
|
|
List<IotSapPickingListDO> pickingLists = new ArrayList<>();
|
|
List<IotSapPickingListDO> pickingLists = new ArrayList<>();
|
|
// 本地库存初始化时合并相同成本中心的 物料数量 单价
|
|
// 本地库存初始化时合并相同成本中心的 物料数量 单价
|