diff --git a/blade-service/logpm-factory/src/main/java/com/logpm/factory/comfac/service/impl/FactoryCommonServiceImpl.java b/blade-service/logpm-factory/src/main/java/com/logpm/factory/comfac/service/impl/FactoryCommonServiceImpl.java index 42554dad7..28ba1b8e6 100644 --- a/blade-service/logpm-factory/src/main/java/com/logpm/factory/comfac/service/impl/FactoryCommonServiceImpl.java +++ b/blade-service/logpm-factory/src/main/java/com/logpm/factory/comfac/service/impl/FactoryCommonServiceImpl.java @@ -34,6 +34,7 @@ public class FactoryCommonServiceImpl implements IFactoryCommonService { @Override public void syncTrayTypeData(String unitNo, Integer trayId, String oldWarehouseId) { + log.info("###############syncTrayTypeData: 包件打托开始 unitNo={} trayId={} oldWarehouseId={}",unitNo,trayId,oldWarehouseId); //先判断新系统仓库信息是否存在 BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getWarehouseByOldId(Integer.parseInt(oldWarehouseId)); if(Objects.isNull(warehouseEntity)){ diff --git a/blade-service/logpm-factory/src/main/java/com/logpm/factory/receiver/DealWithDataHandler.java b/blade-service/logpm-factory/src/main/java/com/logpm/factory/receiver/DealWithDataHandler.java index a27e7e498..b6ad1446c 100644 --- a/blade-service/logpm-factory/src/main/java/com/logpm/factory/receiver/DealWithDataHandler.java +++ b/blade-service/logpm-factory/src/main/java/com/logpm/factory/receiver/DealWithDataHandler.java @@ -17,7 +17,6 @@ import org.springframework.stereotype.Component; import java.io.IOException; import java.util.Map; -import java.util.Objects; /** @@ -48,7 +47,7 @@ public class DealWithDataHandler { String unitNo = orderStatusDTO.getUnitNo(); String operationTime = orderStatusDTO.getOperationTime(); Integer trayId = orderStatusDTO.getTrayId(); - if ("4".equals(status)) { + if ("4".equals(status) || "2".equals(status)) { //继续判断是否到达目的仓 String currentWarehouseId = orderStatusDTO.getCurrentWarehouse();//当前仓Id //查询destinationWarehouse logiBillNo plantId数据 @@ -68,11 +67,16 @@ public class DealWithDataHandler { } else { //真正的处理需要的数据 try { - panFactoryDataService.handleDataToPlatform(unitNo, operationTime); - //同步打托数据 - if(!Objects.isNull(trayId)){ - factoryCommonService.syncTrayTypeData(unitNo,trayId,currentWarehouseId); + if ("4".equals(status)) { + panFactoryDataService.handleDataToPlatform(unitNo, operationTime); + }else if("2".equals(status)){ +// //同步打托数据 +// if(!Objects.isNull(trayId)){ +// factoryCommonService.syncTrayTypeData(unitNo,trayId,currentWarehouseId); +// } } + + } catch (Exception e) { e.printStackTrace(); }