|
|
@ -380,7 +380,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(nowWarehouseId); |
|
|
|
BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(nowWarehouseId); |
|
|
|
String warehouseAddress = null; |
|
|
|
String warehouseAddress = null; |
|
|
|
if (ObjectUtil.isNotEmpty(warehouseEntity)) { |
|
|
|
if (ObjectUtil.isNotEmpty(warehouseEntity)) { |
|
|
|
warehouseAddress = warehouseEntity.getName(); |
|
|
|
warehouseAddress = "从【" + warehouseEntity.getName() + "】发出"; |
|
|
|
} |
|
|
|
} |
|
|
|
sendFactoryData(brands, node, warehouseAddress); |
|
|
|
sendFactoryData(brands, node, warehouseAddress); |
|
|
|
} catch (Exception e) { |
|
|
|
} catch (Exception e) { |
|
|
@ -942,7 +942,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(nowWarehouseId); |
|
|
|
BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(nowWarehouseId); |
|
|
|
String warehouseAddress = null; |
|
|
|
String warehouseAddress = null; |
|
|
|
if (ObjectUtil.isNotEmpty(warehouseEntity)) { |
|
|
|
if (ObjectUtil.isNotEmpty(warehouseEntity)) { |
|
|
|
warehouseAddress = warehouseEntity.getName(); |
|
|
|
warehouseAddress = "到达【" + warehouseEntity.getName() + "】"; |
|
|
|
} |
|
|
|
} |
|
|
|
sendFactoryData(brands, node, warehouseAddress); |
|
|
|
sendFactoryData(brands, node, warehouseAddress); |
|
|
|
} catch (Exception e) { |
|
|
|
} catch (Exception e) { |
|
|
@ -1209,8 +1209,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
return R.fail(405, "配载计划不存在"); |
|
|
|
return R.fail(405, "配载计划不存在"); |
|
|
|
} |
|
|
|
} |
|
|
|
TrunklineCarsLoadLineEntity currentLoadLineEntity = trunklineCarsLoadLineService.findEntityByLoadIdAndNodeId(loadId, warehouseId); |
|
|
|
TrunklineCarsLoadLineEntity currentLoadLineEntity = trunklineCarsLoadLineService.findEntityByLoadIdAndNodeId(loadId, warehouseId); |
|
|
|
if(Objects.isNull(currentLoadLineEntity)){ |
|
|
|
if (Objects.isNull(currentLoadLineEntity)) { |
|
|
|
log.warn("###############updateCarsLoadBasicData: 配载计划节点不存在 loadId={} nodeId={}", loadId,warehouseId); |
|
|
|
log.warn("###############updateCarsLoadBasicData: 配载计划节点不存在 loadId={} nodeId={}", loadId, warehouseId); |
|
|
|
return R.fail(405, "配载计划节点不存在"); |
|
|
|
return R.fail(405, "配载计划节点不存在"); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -1709,7 +1709,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(nowWarehouseId); |
|
|
|
BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(nowWarehouseId); |
|
|
|
String warehouseAddress = null; |
|
|
|
String warehouseAddress = null; |
|
|
|
if (ObjectUtil.isNotEmpty(warehouseEntity)) { |
|
|
|
if (ObjectUtil.isNotEmpty(warehouseEntity)) { |
|
|
|
warehouseAddress = warehouseEntity.getName(); |
|
|
|
warehouseAddress = "从【" + warehouseEntity.getName() + "】发出"; |
|
|
|
} |
|
|
|
} |
|
|
|
this.sendFactoryData(brands, NodeEnums.TRIPARTITE_TRANSFER_DEPART, warehouseAddress); |
|
|
|
this.sendFactoryData(brands, NodeEnums.TRIPARTITE_TRANSFER_DEPART, warehouseAddress); |
|
|
|
} catch (Exception e) { |
|
|
|
} catch (Exception e) { |
|
|
@ -2039,7 +2039,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
distributionStockArticleClient.submitHandleNumByOrderId(1, articleId); |
|
|
|
distributionStockArticleClient.submitHandleNumByOrderId(1, articleId); |
|
|
|
|
|
|
|
|
|
|
|
remark = "有数据,不在当前仓,异常装车"; |
|
|
|
remark = "有数据,不在当前仓,异常装车"; |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode,fromWarehouseId,"干线装车下架解托"); |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode, fromWarehouseId, "干线装车下架解托"); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} else { |
|
|
|
} else { |
|
|
@ -2112,7 +2112,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
distributionParcelListClient.updateOrderPackageCodeById(packageId, "60"); |
|
|
|
distributionParcelListClient.updateOrderPackageCodeById(packageId, "60"); |
|
|
|
distributionStockArticleClient.submitHandleNumByOrderId(1, articleId); |
|
|
|
distributionStockArticleClient.submitHandleNumByOrderId(1, articleId); |
|
|
|
if (StringUtil.isBlank(trayCode)) { |
|
|
|
if (StringUtil.isBlank(trayCode)) { |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode,warehouseId,"干线装车下架解托"); |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode, warehouseId, "干线装车下架解托"); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
carsLoadScanEntity.setLoadingUserName(AuthUtil.getNickName()); |
|
|
|
carsLoadScanEntity.setLoadingUserName(AuthUtil.getNickName()); |
|
|
@ -2853,7 +2853,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
|
|
|
|
|
|
|
|
String orders = null; |
|
|
|
String orders = null; |
|
|
|
if (0 == isZero) { |
|
|
|
if (0 == isZero) { |
|
|
|
unloadPackage(loadId, orderPackageCode, warehouseId, 1, "卸分一体 卸车",incomingType); |
|
|
|
unloadPackage(loadId, orderPackageCode, warehouseId, 1, "卸分一体 卸车", incomingType); |
|
|
|
Map<String, Object> map = new HashMap<>(); |
|
|
|
Map<String, Object> map = new HashMap<>(); |
|
|
|
map.put("trayType", trayType); |
|
|
|
map.put("trayType", trayType); |
|
|
|
map.put("trayCode", trayCode); |
|
|
|
map.put("trayCode", trayCode); |
|
|
@ -2877,7 +2877,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
map.put("warehouseId", warehouseId); |
|
|
|
map.put("warehouseId", warehouseId); |
|
|
|
map.put("orderCode", orderCode); |
|
|
|
map.put("orderCode", orderCode); |
|
|
|
map.put("num", enterNum); |
|
|
|
map.put("num", enterNum); |
|
|
|
map.put("remark","卸分一体零担打托"); |
|
|
|
map.put("remark", "卸分一体零担打托"); |
|
|
|
boolean b = trayTypeClient.enterZeroOrderByTrayCode(map); |
|
|
|
boolean b = trayTypeClient.enterZeroOrderByTrayCode(map); |
|
|
|
if (!b) { |
|
|
|
if (!b) { |
|
|
|
log.warn("##########findNextNodeList: 打托失败 trayCode={} orderCode={}", trayCode, orderCode); |
|
|
|
log.warn("##########findNextNodeList: 打托失败 trayCode={} orderCode={}", trayCode, orderCode); |
|
|
@ -3064,7 +3064,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
distributionStockArticleClient.submitHandleNumByOrderId(1, articleId); |
|
|
|
distributionStockArticleClient.submitHandleNumByOrderId(1, articleId); |
|
|
|
distributionParcelListClient.updateOrderPackageCodeById(pacakageId, "60"); |
|
|
|
distributionParcelListClient.updateOrderPackageCodeById(pacakageId, "60"); |
|
|
|
|
|
|
|
|
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode,wid,"中转卸车下架解托"); |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode, wid, "中转卸车下架解托"); |
|
|
|
} |
|
|
|
} |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
// carsLoadScanEntity.getS
|
|
|
|
// carsLoadScanEntity.getS
|
|
|
@ -3101,8 +3101,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
trayId = trayEntity.getId(); |
|
|
|
trayId = trayEntity.getId(); |
|
|
|
trayName = trayEntity.getPalletName(); |
|
|
|
trayName = trayEntity.getPalletName(); |
|
|
|
} |
|
|
|
} |
|
|
|
if(unbindTray == 1){ |
|
|
|
if (unbindTray == 1) { |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode,fromWarehouseId,"中转卸车下架解托"); |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode, fromWarehouseId, "中转卸车下架解托"); |
|
|
|
} |
|
|
|
} |
|
|
|
trunklineCarsLoadScanService.updateById(carsLoadScanEntity); |
|
|
|
trunklineCarsLoadScanService.updateById(carsLoadScanEntity); |
|
|
|
|
|
|
|
|
|
|
@ -3182,9 +3182,9 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
trunklineCarsUnloadLogService.savaUnloadLog(warehouseId, warehouseName, loadId, loadCode, waybillId, waybillNo, orderCode, |
|
|
|
trunklineCarsUnloadLogService.savaUnloadLog(warehouseId, warehouseName, loadId, loadCode, waybillId, waybillNo, orderCode, |
|
|
|
scanCode, enterNum, 2, 1, isAbnormal, trayId, trayCode, trayName, fromWarehouseId, loadScanId, remark); |
|
|
|
scanCode, enterNum, 2, 1, isAbnormal, trayId, trayCode, trayName, fromWarehouseId, loadScanId, remark); |
|
|
|
|
|
|
|
|
|
|
|
if(unbindTray == 1){ |
|
|
|
if (unbindTray == 1) { |
|
|
|
if(!StringUtil.isBlank(trayCode)){ |
|
|
|
if (!StringUtil.isBlank(trayCode)) { |
|
|
|
trayTypeClient.deleteZeroOrderByTrayCode(orderCode,trayCode,fromWarehouseId,"干线中转零担解托"); |
|
|
|
trayTypeClient.deleteZeroOrderByTrayCode(orderCode, trayCode, fromWarehouseId, "干线中转零担解托"); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -3247,7 +3247,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
|
|
|
|
|
|
|
|
for (UnloadPackageDTO unloadPackageDTO : unloadPackageList) { |
|
|
|
for (UnloadPackageDTO unloadPackageDTO : unloadPackageList) { |
|
|
|
String orderPackageCode = unloadPackageDTO.getOrderPackageCode(); |
|
|
|
String orderPackageCode = unloadPackageDTO.getOrderPackageCode(); |
|
|
|
unloadPackage(loadId, orderPackageCode, warehouseId, 1, "批量卸车包件正常卸车",incomingType); |
|
|
|
unloadPackage(loadId, orderPackageCode, warehouseId, 1, "批量卸车包件正常卸车", incomingType); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -3749,7 +3749,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
Integer planNum = carsOrderEntity.getPlanNum(); |
|
|
|
Integer planNum = carsOrderEntity.getPlanNum(); |
|
|
|
List<DistributionParcelListEntity> entityListByOrderCode = distributionParcelListClient.findEntityListByOrderCodeAndStatus(orderCode, warehouseId, "20"); |
|
|
|
List<DistributionParcelListEntity> entityListByOrderCode = distributionParcelListClient.findEntityListByOrderCodeAndStatus(orderCode, warehouseId, "20"); |
|
|
|
int size = entityListByOrderCode.size(); |
|
|
|
int size = entityListByOrderCode.size(); |
|
|
|
if (planNum.equals(size+realNum)) { |
|
|
|
if (planNum.equals(size + realNum)) { |
|
|
|
for (DistributionParcelListEntity parcelListEntity : entityListByOrderCode) { |
|
|
|
for (DistributionParcelListEntity parcelListEntity : entityListByOrderCode) { |
|
|
|
String orderPackageCode = parcelListEntity.getOrderPackageCode(); |
|
|
|
String orderPackageCode = parcelListEntity.getOrderPackageCode(); |
|
|
|
//查询包件是否已经装车
|
|
|
|
//查询包件是否已经装车
|
|
|
@ -4302,12 +4302,12 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
parcelListEntity.setIsTransfer(1); |
|
|
|
parcelListEntity.setIsTransfer(1); |
|
|
|
} |
|
|
|
} |
|
|
|
distributionParcelListClient.update(parcelListEntity); |
|
|
|
distributionParcelListClient.update(parcelListEntity); |
|
|
|
if(StringUtil.isNotBlank(trayCode)){ |
|
|
|
if (StringUtil.isNotBlank(trayCode)) { |
|
|
|
updownTypeClient.downPackageOrDelTray(scanCode,warehouseId,"包件下架解托"); |
|
|
|
updownTypeClient.downPackageOrDelTray(scanCode, warehouseId, "包件下架解托"); |
|
|
|
} |
|
|
|
} |
|
|
|
}else{ |
|
|
|
} else { |
|
|
|
if(StringUtil.isNotBlank(trayCode)){ |
|
|
|
if (StringUtil.isNotBlank(trayCode)) { |
|
|
|
trayTypeClient.deleteZeroOrderByTrayCode(orderCode,trayCode,warehouseId,"零担解托"); |
|
|
|
trayTypeClient.deleteZeroOrderByTrayCode(orderCode, trayCode, warehouseId, "零担解托"); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
@ -4315,7 +4315,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
if(!Objects.isNull(loadId)){ |
|
|
|
if (!Objects.isNull(loadId)) { |
|
|
|
updateNumByLoadId(loadId); |
|
|
|
updateNumByLoadId(loadId); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -4371,7 +4371,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public R unloadPackage(Long loadId, String orderPackageCode, Long warehouseId, Integer unbindTray, String remark,Integer incomingType) { |
|
|
|
public R unloadPackage(Long loadId, String orderPackageCode, Long warehouseId, Integer unbindTray, String remark, Integer incomingType) { |
|
|
|
log.info("#############unloadPackage: 卸车包件"); |
|
|
|
log.info("#############unloadPackage: 卸车包件"); |
|
|
|
|
|
|
|
|
|
|
|
BasicdataWarehouseEntity basicdataWarehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); |
|
|
|
BasicdataWarehouseEntity basicdataWarehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); |
|
|
@ -4587,7 +4587,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
} |
|
|
|
} |
|
|
|
distributionParcelListClient.update(distributionParcelListEntity); |
|
|
|
distributionParcelListClient.update(distributionParcelListEntity); |
|
|
|
} |
|
|
|
} |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode,wid,"干线卸车下架解托"); |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode, wid, "干线卸车下架解托"); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
//无装车记录异常日志记录
|
|
|
|
//无装车记录异常日志记录
|
|
|
@ -4625,8 +4625,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
trayId = trayEntity.getId(); |
|
|
|
trayId = trayEntity.getId(); |
|
|
|
trayName = trayEntity.getPalletName(); |
|
|
|
trayName = trayEntity.getPalletName(); |
|
|
|
} |
|
|
|
} |
|
|
|
if(unbindTray == 1){ |
|
|
|
if (unbindTray == 1) { |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode,fromWarehouseId,"干线卸车下架解托"); |
|
|
|
updownTypeClient.downPackageOrDelTray(orderPackageCode, fromWarehouseId, "干线卸车下架解托"); |
|
|
|
} |
|
|
|
} |
|
|
|
trunklineCarsLoadScanService.updateById(carsLoadScanEntity); |
|
|
|
trunklineCarsLoadScanService.updateById(carsLoadScanEntity); |
|
|
|
|
|
|
|
|
|
|
@ -4835,9 +4835,9 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
trunklineCarsUnloadLogService.savaUnloadLog(warehouseId, warehouseName, loadId, loadCode, waybillId, waybillNo, orderCode, |
|
|
|
trunklineCarsUnloadLogService.savaUnloadLog(warehouseId, warehouseName, loadId, loadCode, waybillId, waybillNo, orderCode, |
|
|
|
scanCode, enterNun, 2, 1, isAbnormal, trayId, trayCode, trayName, fromWarehouseId, loadScanId, remark); |
|
|
|
scanCode, enterNun, 2, 1, isAbnormal, trayId, trayCode, trayName, fromWarehouseId, loadScanId, remark); |
|
|
|
|
|
|
|
|
|
|
|
if(unbindTray == 1){ |
|
|
|
if (unbindTray == 1) { |
|
|
|
if(!StringUtil.isBlank(trayCode)){ |
|
|
|
if (!StringUtil.isBlank(trayCode)) { |
|
|
|
trayTypeClient.deleteZeroOrderByTrayCode(orderCode,trayCode,fromWarehouseId,"干线卸车零担解托"); |
|
|
|
trayTypeClient.deleteZeroOrderByTrayCode(orderCode, trayCode, fromWarehouseId, "干线卸车零担解托"); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -5072,7 +5072,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public R unloadTray(Long loadId, String trayCode, Long warehouseId,Integer incomingType) { |
|
|
|
public R unloadTray(Long loadId, String trayCode, Long warehouseId, Integer incomingType) { |
|
|
|
TrunklineCarsLoadEntity carsLoadEntity = baseMapper.selectById(loadId); |
|
|
|
TrunklineCarsLoadEntity carsLoadEntity = baseMapper.selectById(loadId); |
|
|
|
if (Objects.isNull(carsLoadEntity)) { |
|
|
|
if (Objects.isNull(carsLoadEntity)) { |
|
|
|
log.warn("###############unloadTray: 配载计划不存在 loadId={}", loadId); |
|
|
|
log.warn("###############unloadTray: 配载计划不存在 loadId={}", loadId); |
|
|
@ -5086,7 +5086,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL |
|
|
|
String scanCode = carsLoadScanEntity.getScanCode(); |
|
|
|
String scanCode = carsLoadScanEntity.getScanCode(); |
|
|
|
if (type == 1) { |
|
|
|
if (type == 1) { |
|
|
|
//包件
|
|
|
|
//包件
|
|
|
|
unloadPackage(loadId, scanCode, warehouseId, 0, "托盘正常卸车",incomingType); |
|
|
|
unloadPackage(loadId, scanCode, warehouseId, 0, "托盘正常卸车", incomingType); |
|
|
|
} else if (type == 2) { |
|
|
|
} else if (type == 2) { |
|
|
|
String waybillNo = carsLoadScanEntity.getWaybillNo(); |
|
|
|
String waybillNo = carsLoadScanEntity.getWaybillNo(); |
|
|
|
Integer num = carsLoadScanEntity.getNum(); |
|
|
|
Integer num = carsLoadScanEntity.getNum(); |
|
|
|