|
|
|
@ -5685,18 +5685,19 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
|
|
|
|
|
if (row == 1) { |
|
|
|
|
DistributionLoadscanEntity loadscanEntity = distributionLoadscanService.getOne(Wrappers.<DistributionLoadscanEntity>query().lambda().eq(DistributionLoadscanEntity::getDeliveryId, deliveryId).eq(DistributionLoadscanEntity::getReservationId, reservationId).eq(DistributionLoadscanEntity::getPackageId, orderPackageId).ne(DistributionLoadscanEntity::getScanStatus, LoadingStatusConstant.quxiao.getValue())); |
|
|
|
|
if (Func.isNotEmpty(loadscanEntity)) { |
|
|
|
|
//修改包件状态 达到回库的状态
|
|
|
|
|
DistributionParcelListEntity parcelListEntity = distributionParcelListService.getById(loadscanEntity.getPackageId()); |
|
|
|
|
parcelListEntity.setOrderPackageLoadingStatus(OrderPackageLoadingStatusConstant.weizhuancghe.getValue()); |
|
|
|
|
parcelListEntity.setOrderPackageReservationStatus(OrderPackageReservationStatusConstant.daiyuyue.getValue()); |
|
|
|
|
parcelListEntity.setOrderPackageStatus(OrderPackageStatusConstant.yiruku.getValue()); |
|
|
|
|
distributionParcelListService.updateById(parcelListEntity); |
|
|
|
|
//已经进行装车
|
|
|
|
|
loadscanEntity.setScanStatus(LoadingStatusConstant.quxiao.getValue()); |
|
|
|
|
distributionLoadscanService.updateById(loadscanEntity); |
|
|
|
|
// 对应签收信息的装车数量要进行扣减
|
|
|
|
|
int a = distributionSignforMapper.deductionLoadingPacjageNum(loadscanEntity.getReservationId(), loadscanEntity.getDeliveryId(), loadscanEntity.getLoadedNub()); |
|
|
|
|
//维护在库订单的在库数量字段
|
|
|
|
|
distributionStockArticleMapper.augmentHandQuantity(loadscanEntity.getOrderId(), loadscanEntity.getLoadedNub()); |
|
|
|
|
distributionAsyncService.checkReservationStatusAndLoadingStatusByPackage(parcelListEntity.getId()); |
|
|
|
|
//维护订单状态
|
|
|
|
|
distributionStockArticleService.maintenanceOrderInfo(parcelListEntity.getOrderCode(),parcelListEntity.getWarehouseId()); |
|
|
|
|
} |
|
|
|
|
//进行了一条包件任务的取消,此时就应该对预约、配送任务进行数量的维护
|
|
|
|
|
distributionAsyncService.checkRetentionReservationAndDeliveryInfo(reservationId, deliveryId); |
|
|
|
|