|
|
|
@ -1375,7 +1375,7 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
distributionDeliveryListEntity.setDeliveryNumber(packageNum.get()); |
|
|
|
|
distributionDeliveryListEntity.setInventoryNub(inventoryNum.get()); |
|
|
|
|
distributionDeliveryListService.updateById(distributionDeliveryListEntity); |
|
|
|
|
distributionAsyncService.recordsReservationDeliveryLog(reservationIds,myCurrentWarehouse,user,distributionDeliveryListEntity.getTrainNumber()); |
|
|
|
|
// distributionAsyncService.recordsReservationDeliveryLog(reservationIds,myCurrentWarehouse,user,distributionDeliveryListEntity.getTrainNumber());
|
|
|
|
|
return R.status(true); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -1405,6 +1405,7 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
//这里查询出该订单下已经被选取的包件信息
|
|
|
|
|
List<DistributionParcelListEntity> packageVOList = distributionReservationPackageMapper.selectPackageVOList(reservationEntity.getId(), s.getId()); |
|
|
|
|
s.setPackageList(DistributionParcelListWrapper.build().listVO(packageVOList)); |
|
|
|
|
s.setReservationNum(pageVOList.size()); |
|
|
|
|
} else { |
|
|
|
|
List<DistributionParcelNumberVO> parcelNumberVOS = baseMapper.selectReservationZeroOrderDetail(s.getId(), Long.parseLong(reservationId)); |
|
|
|
|
s.setParcelNumberVOS(parcelNumberVOS); |
|
|
|
@ -1445,10 +1446,7 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
List<Long> mallId = new ArrayList<>(); |
|
|
|
|
HashSet<String> storeName = new HashSet<>(); |
|
|
|
|
HashSet<String> receivingUnit = new HashSet<>(); |
|
|
|
|
List<String> addOrderPackageCodes = new ArrayList<>(); |
|
|
|
|
List<String> cancelOrderPackageCodes = new ArrayList<>(); |
|
|
|
|
List<JSONObject> addPackageLog = new ArrayList<>(); |
|
|
|
|
List<JSONObject> cancelPackageLog = new ArrayList<>(); |
|
|
|
|
List<JSONObject> aaa = new ArrayList<>(); |
|
|
|
|
newStockArticle.forEach((k, v) -> { |
|
|
|
|
List<Long> packageLockIds = new ArrayList<>(); |
|
|
|
|
if (Func.isEmpty(oldStockArticle.get(k))) { |
|
|
|
@ -1475,22 +1473,21 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
String content = "包件在"+myCurrentWarehouse.getName()+"由"+AuthUtil.getUser().getNickName()+"新增计划市配配送,操作方式:新增订单选中包件,预约任务号:"+reservationEntity.getReservationCode(); |
|
|
|
|
|
|
|
|
|
JSONObject trunklinePackageTrackLog= new JSONObject(); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",reservationEntity.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",reservationEntity.getCreateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",reservationEntity.getCreateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",reservationEntity.getUpdateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",reservationEntity.getUpdateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("isDeleted",reservationEntity.getIsDeleted()); |
|
|
|
|
trunklinePackageTrackLog.put("status",reservationEntity.getStatus()); |
|
|
|
|
trunklinePackageTrackLog.put("createDept",reservationEntity.getCreateDept()); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",AuthUtil.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("isDeleted",0); |
|
|
|
|
trunklinePackageTrackLog.put("status",1); |
|
|
|
|
trunklinePackageTrackLog.put("createDept",myCurrentWarehouse.getDepartment()); |
|
|
|
|
trunklinePackageTrackLog.put("orderPackageCode",p.getOrderPackageCode()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",reservationEntity.getWarehouseId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",reservationEntity.getWarehouseName()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",myCurrentWarehouse.getId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",myCurrentWarehouse.getName()); |
|
|
|
|
trunklinePackageTrackLog.put("workNode",WorkNodeEnums.PLAN_DELIVERY.getCode()); |
|
|
|
|
trunklinePackageTrackLog.put("content",content); |
|
|
|
|
trunklinePackageTrackLog.put("operator",AuthUtil.getUser().getNickName()); |
|
|
|
|
addPackageLog.add(trunklinePackageTrackLog); |
|
|
|
|
addOrderPackageCodes.add(p.getOrderPackageCode()); |
|
|
|
|
aaa.add(trunklinePackageTrackLog); |
|
|
|
|
}); |
|
|
|
|
} else { |
|
|
|
|
//添加此订单可用所有包件数量
|
|
|
|
@ -1514,42 +1511,35 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
//此时订单下的所有包件都处于预约状态,可用数为0
|
|
|
|
|
packageNum.getAndAdd(dp.getQuantity()); |
|
|
|
|
//修改订单下的包件状态
|
|
|
|
|
// p.setOrderPackageReservationStatus();
|
|
|
|
|
dp.setOrderPackageReservationStatus(OrderPackageReservationStatusConstant.yiyueyue.getValue()); |
|
|
|
|
distributionParcelListService.updateById(dp); |
|
|
|
|
distributionAsyncService.checkStockArticleReservationStatus(dp); |
|
|
|
|
|
|
|
|
|
String content = "包件在"+myCurrentWarehouse.getName()+"由"+AuthUtil.getUser().getNickName()+"新增计划市配配送,操作方式:新增订单系统默认选中,预约任务号:"+reservationEntity.getReservationCode(); |
|
|
|
|
String content = "包件在"+myCurrentWarehouse.getName()+"由"+AuthUtil.getUser().getNickName()+"新增计划市配配送,操作方式:新增订单系统默认选中可用包件,预约任务号:"+reservationEntity.getReservationCode(); |
|
|
|
|
JSONObject trunklinePackageTrackLog= new JSONObject(); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",reservationEntity.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",reservationEntity.getCreateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",reservationEntity.getCreateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",reservationEntity.getUpdateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",reservationEntity.getUpdateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("isDeleted",reservationEntity.getIsDeleted()); |
|
|
|
|
trunklinePackageTrackLog.put("status",reservationEntity.getStatus()); |
|
|
|
|
trunklinePackageTrackLog.put("createDept",reservationEntity.getCreateDept()); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",AuthUtil.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("isDeleted",0); |
|
|
|
|
trunklinePackageTrackLog.put("status",1); |
|
|
|
|
trunklinePackageTrackLog.put("createDept",myCurrentWarehouse.getDepartment()); |
|
|
|
|
trunklinePackageTrackLog.put("orderPackageCode",dp.getOrderPackageCode()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",reservationEntity.getWarehouseId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",reservationEntity.getWarehouseName()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",myCurrentWarehouse.getId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",myCurrentWarehouse.getName()); |
|
|
|
|
trunklinePackageTrackLog.put("workNode",WorkNodeEnums.PLAN_DELIVERY.getCode()); |
|
|
|
|
trunklinePackageTrackLog.put("content",content); |
|
|
|
|
trunklinePackageTrackLog.put("operator",AuthUtil.getUser().getNickName()); |
|
|
|
|
addPackageLog.add(trunklinePackageTrackLog); |
|
|
|
|
addOrderPackageCodes.add(dp.getOrderPackageCode()); |
|
|
|
|
aaa.add(trunklinePackageTrackLog); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
// stockArticleEntity.setReservationStatus(OrderReservationStatusConstant.yiyueyue.getValue());
|
|
|
|
|
}); |
|
|
|
|
// distributionStockArticleDTO.setReservationStatus(OrderReservationStatusConstant.yiyueyue.getValue());
|
|
|
|
|
// distributionStockArticleDTO.setAvailableQuantity(0);
|
|
|
|
|
// distributionStockArticleService.updateById(stockArticleEntity);
|
|
|
|
|
DistributionStockArticleEntity stockArticleEntity = Func.copy(distributionStockArticleDTO, DistributionStockArticleEntity.class); |
|
|
|
|
if (Func.isNotEmpty(stockArticleEntity)){ |
|
|
|
|
//维护订单状态
|
|
|
|
|
distributionStockArticleService.updateOrderInfo(stockArticleEntity.getOrderCode(),myCurrentWarehouse.getId()); |
|
|
|
|
//维护配送数量
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
@ -1662,6 +1652,23 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
DistributionParcelListEntity parcelListEntity = distributionParcelListService.getById(distributionParcelListEntity.getId()); |
|
|
|
|
parcelListEntity.setOrderPackageReservationStatus(OrderPackageReservationStatusConstant.yiyueyue.getValue()); |
|
|
|
|
distributionParcelListService.updateById(parcelListEntity); |
|
|
|
|
String content = "包件在"+myCurrentWarehouse.getName()+"由"+AuthUtil.getUser().getNickName()+"新增计划市配配送,操作方式:订单选中包件,预约任务号:"+reservationEntity.getReservationCode(); |
|
|
|
|
JSONObject trunklinePackageTrackLog= new JSONObject(); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",AuthUtil.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("isDeleted",0); |
|
|
|
|
trunklinePackageTrackLog.put("status",1); |
|
|
|
|
trunklinePackageTrackLog.put("createDept",myCurrentWarehouse.getDepartment()); |
|
|
|
|
trunklinePackageTrackLog.put("orderPackageCode",parcelListEntity.getOrderPackageCode()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",myCurrentWarehouse.getId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",myCurrentWarehouse.getName()); |
|
|
|
|
trunklinePackageTrackLog.put("workNode",WorkNodeEnums.CANCEL_DELIVERY.getCode()); |
|
|
|
|
trunklinePackageTrackLog.put("content",content); |
|
|
|
|
trunklinePackageTrackLog.put("operator",AuthUtil.getUser().getNickName()); |
|
|
|
|
aaa.add(trunklinePackageTrackLog); |
|
|
|
|
} else { |
|
|
|
|
//数量维护
|
|
|
|
|
packageNum.getAndAdd(distributionParcelListEntity.getQuantity()); |
|
|
|
@ -1681,24 +1688,21 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
|
|
|
|
|
String content = "包件在"+myCurrentWarehouse.getName()+"由"+AuthUtil.getUser().getNickName()+"取消计划市配配送,操作方式:取消选中包件,预约任务号:"+reservationEntity.getReservationCode(); |
|
|
|
|
JSONObject trunklinePackageTrackLog= new JSONObject(); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",reservationEntity.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",reservationEntity.getCreateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",reservationEntity.getCreateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",reservationEntity.getUpdateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",reservationEntity.getUpdateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",AuthUtil.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("isDeleted",reservationEntity.getIsDeleted()); |
|
|
|
|
trunklinePackageTrackLog.put("status",reservationEntity.getStatus()); |
|
|
|
|
trunklinePackageTrackLog.put("createDept",reservationEntity.getCreateDept()); |
|
|
|
|
trunklinePackageTrackLog.put("orderPackageCode",parcelListEntity.getOrderPackageCode()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",reservationEntity.getWarehouseId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",reservationEntity.getWarehouseName()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",myCurrentWarehouse.getId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",myCurrentWarehouse.getName()); |
|
|
|
|
trunklinePackageTrackLog.put("workNode",WorkNodeEnums.CANCEL_DELIVERY.getCode()); |
|
|
|
|
trunklinePackageTrackLog.put("content",content); |
|
|
|
|
trunklinePackageTrackLog.put("operator",AuthUtil.getUser().getNickName()); |
|
|
|
|
cancelPackageLog.add(trunklinePackageTrackLog); |
|
|
|
|
cancelOrderPackageCodes.add(parcelListEntity.getOrderPackageCode()); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
aaa.add(trunklinePackageTrackLog); |
|
|
|
|
distributionParcelListService.updateById(parcelListEntity); |
|
|
|
|
if (Func.isNotEmpty(bladeRedis.get("warehouseId:"+myCurrentWarehouse.getId()+"orderCode:"+parcelListEntity.getOrderCode()))){ |
|
|
|
|
List<Long> ids = bladeRedis.get("warehouseId:" + myCurrentWarehouse.getId() + "orderCode:" + parcelListEntity.getOrderCode()); |
|
|
|
@ -1708,7 +1712,6 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
bladeRedis.setEx("warehouseId:" + myCurrentWarehouse.getId() + "orderCode:" + parcelListEntity.getOrderCode(),ids,1*60L); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
//移除缓存
|
|
|
|
|
}); |
|
|
|
|
reservationStockarticleEntity.setReservationNum(packageNum.get()); |
|
|
|
|
distributionReservationStockarticleService.updateById(reservationStockarticleEntity); |
|
|
|
@ -1804,10 +1807,6 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
storeName.add(distributionStockArticleDTO.getStoreName()); |
|
|
|
|
} |
|
|
|
|
receivingUnit.add(distributionStockArticleDTO.getConsigneeUnit()); |
|
|
|
|
|
|
|
|
|
// DistributionStockArticleEntity stockArticleEntity = distributionStockArticleService.getById(distributionStockArticleDTO.getId());
|
|
|
|
|
// stockArticleEntity.setReservationStatus(status);
|
|
|
|
|
// distributionStockArticleService.updateById(stockArticleEntity);
|
|
|
|
|
} |
|
|
|
|
//添加缓存
|
|
|
|
|
if (!packageLockIds.isEmpty()){ |
|
|
|
@ -1827,16 +1826,11 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
if (!addOrderPackageCodes.isEmpty()) { |
|
|
|
|
log.info(">>>>>>>>>>>>>>>>>>>推送新增日志"); |
|
|
|
|
trunklinePackageTrackLogClient.addPackageTrackLog(addPackageLog); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (Func.isNotEmpty(oldStockArticle)) { |
|
|
|
|
oldStockArticle.forEach((i, j) -> { |
|
|
|
|
//这里就是需要进行取消的订单信息
|
|
|
|
|
DistributionStockArticleEntity stockArticleEntity = distributionStockArticleService.getById(i); |
|
|
|
|
|
|
|
|
|
DistributionReservationStockarticleEntity reservationStockarticleEntity = j.get(0); |
|
|
|
|
if (reservationStockarticleEntity.getIsZero().equals(IsOrNoConstant.no.getValue())) { |
|
|
|
|
reservationStockarticleEntity.setStockArticleStatus(ReservationOrderStatusConstant.quxiao.getValue()); |
|
|
|
@ -1846,22 +1840,21 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
distributionReservationPackageService.updateById(p); |
|
|
|
|
String content = "包件在"+myCurrentWarehouse.getName()+"由"+AuthUtil.getUser().getNickName()+"取消计划市配配送,操作方式:取消订单,预约任务号:"+reservationEntity.getReservationCode(); |
|
|
|
|
JSONObject trunklinePackageTrackLog= new JSONObject(); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",reservationEntity.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",reservationEntity.getCreateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",reservationEntity.getCreateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",reservationEntity.getUpdateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",reservationEntity.getUpdateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",AuthUtil.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("isDeleted",reservationEntity.getIsDeleted()); |
|
|
|
|
trunklinePackageTrackLog.put("status",reservationEntity.getStatus()); |
|
|
|
|
trunklinePackageTrackLog.put("createDept",reservationEntity.getCreateDept()); |
|
|
|
|
trunklinePackageTrackLog.put("orderPackageCode",p.getPacketBarCode()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",reservationEntity.getWarehouseId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",reservationEntity.getWarehouseName()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",myCurrentWarehouse.getId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",myCurrentWarehouse.getName()); |
|
|
|
|
trunklinePackageTrackLog.put("workNode",WorkNodeEnums.CANCEL_DELIVERY.getCode()); |
|
|
|
|
trunklinePackageTrackLog.put("content",content); |
|
|
|
|
trunklinePackageTrackLog.put("operator",AuthUtil.getUser().getNickName()); |
|
|
|
|
cancelPackageLog.add(trunklinePackageTrackLog); |
|
|
|
|
cancelOrderPackageCodes.add(p.getPacketBarCode()); |
|
|
|
|
aaa.add(trunklinePackageTrackLog); |
|
|
|
|
reduceTotal.getAndAdd(distributionParcelListService.getById(p.getParceListId()).getQuantity()); |
|
|
|
|
DistributionParcelListEntity parcelListEntity = distributionParcelListService.getById(p.getParceListId()); |
|
|
|
|
parcelListEntity.setOrderPackageReservationStatus(OrderPackageReservationStatusConstant.daiyuyue.getValue()); |
|
|
|
@ -1898,9 +1891,8 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
distributionReservationStockarticleService.updateById(reservationStockarticleEntity); |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
if (!cancelOrderPackageCodes.isEmpty()) { |
|
|
|
|
log.info(">>>>>>>>>>>>>>>>>>>推送取消日志"); |
|
|
|
|
trunklinePackageTrackLogClient.addPackageTrackLog(cancelPackageLog); |
|
|
|
|
if (!aaa.isEmpty()) { |
|
|
|
|
trunklinePackageTrackLogClient.addPackageTrackLog(aaa); |
|
|
|
|
} |
|
|
|
|
//库存品修改
|
|
|
|
|
//查询出原来的库存品信息
|
|
|
|
@ -2614,7 +2606,6 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
.eq(DistributionReservationStockarticleEntity::getReservationId, reservationEntity.getId()) |
|
|
|
|
.ne(DistributionReservationStockarticleEntity::getStockArticleStatus, ReservationOrderStatusConstant.quxiao.getValue())); |
|
|
|
|
if (Func.isNotEmpty(reservationStockarticleEntityList) && reservationStockarticleEntityList.size() > 0) { |
|
|
|
|
List<String> orderPackageCodes = new ArrayList<>(); |
|
|
|
|
List<JSONObject> aaa = new ArrayList<>(); |
|
|
|
|
reservationStockarticleEntityList.forEach(rs -> { |
|
|
|
|
rs.setStockArticleStatus(ReservationOrderStatusConstant.quxiao.getValue()); |
|
|
|
@ -2638,24 +2629,21 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
// distributionAsyncService.checkStockArticleReservationStatus(parcelListEntity);
|
|
|
|
|
String content = "包件在"+myCurrentWarehouse.getName()+"由"+AuthUtil.getUser().getNickName()+"取消配送,操作方式:取消配送任务,预约任务号:"+reservationEntity.getReservationCode(); |
|
|
|
|
JSONObject trunklinePackageTrackLog= new JSONObject(); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",reservationEntity.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",reservationEntity.getCreateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",reservationEntity.getCreateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",reservationEntity.getUpdateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",reservationEntity.getUpdateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("isDeleted",reservationEntity.getIsDeleted()); |
|
|
|
|
trunklinePackageTrackLog.put("status",reservationEntity.getStatus()); |
|
|
|
|
trunklinePackageTrackLog.put("createDept",reservationEntity.getCreateDept()); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",AuthUtil.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",AuthUtil.getUserId()); |
|
|
|
|
trunklinePackageTrackLog.put("updateTime",new Date()); |
|
|
|
|
trunklinePackageTrackLog.put("isDeleted",0); |
|
|
|
|
trunklinePackageTrackLog.put("status",1); |
|
|
|
|
trunklinePackageTrackLog.put("createDept",myCurrentWarehouse.getDepartment()); |
|
|
|
|
trunklinePackageTrackLog.put("orderPackageCode",rp.getPacketBarCode()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",reservationEntity.getWarehouseId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",reservationEntity.getWarehouseName()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",myCurrentWarehouse.getId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",myCurrentWarehouse.getName()); |
|
|
|
|
trunklinePackageTrackLog.put("workNode",WorkNodeEnums.DISTRIBUTION_LOADING.getCode()); |
|
|
|
|
trunklinePackageTrackLog.put("content",content); |
|
|
|
|
trunklinePackageTrackLog.put("operator",AuthUtil.getUser().getNickName()); |
|
|
|
|
aaa.add(trunklinePackageTrackLog); |
|
|
|
|
orderPackageCodes.add(rp.getPacketBarCode()); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} else { |
|
|
|
|
log.error("#################错误包件ID:{}", rp.getParceListId()); |
|
|
|
|
} |
|
|
|
@ -3064,6 +3052,7 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
reservationEntity.setReservationStatus(ReservationStatusConstant.yiqueren.getValue()); |
|
|
|
|
//新建预约单订单处于未备货状态
|
|
|
|
|
reservationEntity.setStockupStatus(ReservationStockupStatusConstant.weibeihuo.getValue()); |
|
|
|
|
reservationEntity.setReservationCode(reservationMa()); |
|
|
|
|
this.save(reservationEntity); |
|
|
|
|
//获取新增预约信息的编号
|
|
|
|
|
Long reservationId = reservationEntity.getId(); |
|
|
|
@ -3191,7 +3180,7 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
orderPackageCodes.add(dp.getOrderPackageCode()); |
|
|
|
|
String content = "包件在"+myCurrentWarehouse.getName()+"由"+AuthUtil.getUser().getNickName()+"计划配送,操作方式:系统默认全部包件,预约任务号:"+reservationEntity.getReservationCode(); |
|
|
|
|
JSONObject trunklinePackageTrackLog= new JSONObject(); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",reservationEntity.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",AuthUtil.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",reservationEntity.getCreateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",reservationEntity.getCreateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",reservationEntity.getUpdateUser()); |
|
|
|
@ -3200,8 +3189,8 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
trunklinePackageTrackLog.put("status",reservationEntity.getStatus()); |
|
|
|
|
trunklinePackageTrackLog.put("createDept",reservationEntity.getCreateDept()); |
|
|
|
|
trunklinePackageTrackLog.put("orderPackageCode",dp.getOrderPackageCode()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",reservationEntity.getWarehouseId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",reservationEntity.getWarehouseName()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseId",myCurrentWarehouse.getId()); |
|
|
|
|
trunklinePackageTrackLog.put("warehouseName",myCurrentWarehouse.getName()); |
|
|
|
|
trunklinePackageTrackLog.put("workNode", WorkNodeEnums.DISTRIBUTION_LOADING.getCode()); |
|
|
|
|
trunklinePackageTrackLog.put("content",content); |
|
|
|
|
trunklinePackageTrackLog.put("operator",AuthUtil.getUser().getNickName()); |
|
|
|
@ -3229,7 +3218,7 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
orderPackageCodes.add(p.getOrderPackageCode()); |
|
|
|
|
String content = "包件在"+myCurrentWarehouse.getName()+"由"+AuthUtil.getUser().getNickName()+"计划市配配送,操作方式:选择包件,预约任务号:"+reservationEntity.getReservationCode(); |
|
|
|
|
JSONObject trunklinePackageTrackLog= new JSONObject(); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",reservationEntity.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("tenantId",AuthUtil.getTenantId()); |
|
|
|
|
trunklinePackageTrackLog.put("createTime",reservationEntity.getCreateTime()); |
|
|
|
|
trunklinePackageTrackLog.put("createUser",reservationEntity.getCreateUser()); |
|
|
|
|
trunklinePackageTrackLog.put("updateUser",reservationEntity.getUpdateUser()); |
|
|
|
@ -3487,7 +3476,6 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
|
|
|
|
|
} else { |
|
|
|
|
reservationEntity.setFee(new BigDecimal(0)); |
|
|
|
|
} |
|
|
|
|
reservationEntity.setReservationCode(reservationMa()); |
|
|
|
|
//设置预约为市配
|
|
|
|
|
reservationEntity.setDeliveryType(DistributionTypeConstant.shipie.getValue()); |
|
|
|
|
reservationEntity.setReservationNum(packageTotal.get()); |
|
|
|
|