From 772c486497ede348637dff0ba76f708106478287 Mon Sep 17 00:00:00 2001 From: zhenghaoyu Date: Fri, 17 Jan 2025 18:05:20 +0800 Subject: [PATCH 1/2] =?UTF-8?q?1.bug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../trunkline/service/impl/OpenOrderServiceImpl.java | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java index 1bc8508a8..deb195aea 100644 --- a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java @@ -802,6 +802,7 @@ public class OpenOrderServiceImpl implements IOpenOrderService { //绑定订单和运单的关系 List advanceEntityList = advanceService.findListByIds(advanceIds); List waybillOrderEntities = new ArrayList<>(); + List updateAdvanceEntityList = new ArrayList<>(); Set orderCodeSet = new HashSet<>(); for (TrunklineAdvanceEntity advanceEntity : advanceEntityList) { orderCodeSet.add(advanceEntity.getOrderCode()); @@ -824,13 +825,16 @@ public class OpenOrderServiceImpl implements IOpenOrderService { waybillOrderEntities.add(waybillOrderEntity); // orderCodes.add(advanceEntity.getOrderCode()); - advanceEntity.setWaybillStatus("1"); - advanceEntity.setWaybillNo(waybillNo); + TrunklineAdvanceEntity updateAdvanceEntity = new TrunklineAdvanceEntity(); + updateAdvanceEntity.setId(advanceId); + updateAdvanceEntity.setWaybillStatus("1"); + updateAdvanceEntity.setWaybillNo(waybillNo); + updateAdvanceEntityList.add(updateAdvanceEntity); } trunklineWaybillOrderService.saveBatch(waybillOrderEntities); //修改暂存单的状态为已开单 - advanceService.updateBatchById(advanceEntityList); + advanceService.updateBatchById(updateAdvanceEntityList); //更新暂存单包件的运单信息 From 3158426c467115b7dc8062eceee986ef7b58d20b Mon Sep 17 00:00:00 2001 From: "pref_mail@163.com" Date: Fri, 17 Jan 2025 18:15:54 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BC=98=E5=8C=96=E7=AD=BE=E6=94=B6?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=20=E5=92=8C=E9=85=8D=E9=80=81=E8=BD=A6?= =?UTF-8?q?=E6=AC=A1=E7=8A=B6=E6=80=81=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/LogpmDataSearchServiceImpl.java | 15 +++- .../mapper/DistributionSignforMapper.java | 2 + .../mapper/DistributionSignforMapper.xml | 11 +++ .../DistributionDeliveryListServiceImpl.java | 13 ++- .../DistributionReservationServiceImpl.java | 22 ++--- .../impl/DistributionSignforServiceImpl.java | 88 +++++++++++++------ 6 files changed, 108 insertions(+), 43 deletions(-) diff --git a/blade-service/logpm-data-sharing/src/main/java/com/logpm/datasharing/service/impl/LogpmDataSearchServiceImpl.java b/blade-service/logpm-data-sharing/src/main/java/com/logpm/datasharing/service/impl/LogpmDataSearchServiceImpl.java index d29087cf2..f69fb4154 100644 --- a/blade-service/logpm-data-sharing/src/main/java/com/logpm/datasharing/service/impl/LogpmDataSearchServiceImpl.java +++ b/blade-service/logpm-data-sharing/src/main/java/com/logpm/datasharing/service/impl/LogpmDataSearchServiceImpl.java @@ -173,13 +173,13 @@ public class LogpmDataSearchServiceImpl implements ILogpmDataSearchService { if (signListByWaybillNumber != null && !signListByWaybillNumber.isEmpty()) { //统计装车数量load_num - int loadNum = signListByWaybillNumber.stream().mapToInt(QualityDeliverEntity::getLoadNum).sum(); + int loadNum = signListByWaybillNumber.stream().filter(e -> e.getLoadNum() !=null).mapToInt(QualityDeliverEntity::getLoadNum).sum(); // 计划配送数 plan_num - int planNum = signListByWaybillNumber.stream().mapToInt(QualityDeliverEntity::getPlanNum).sum(); + int planNum = signListByWaybillNumber.stream().filter(e-> e.getPlanNum()!=null).mapToInt(QualityDeliverEntity::getPlanNum).sum(); // 计算签收数量sign_num - int signNum = signListByWaybillNumber.stream().mapToInt(QualityDeliverEntity::getSignNum).sum(); + int signNum = signListByWaybillNumber.stream().filter(e-> e.getSignNum()!=null).mapToInt(QualityDeliverEntity::getSignNum).sum(); // 配送装车 QualityDeliverEntity qualityDeliverEntity = signListByWaybillNumber.get(0); @@ -214,6 +214,8 @@ public class LogpmDataSearchServiceImpl implements ILogpmDataSearchService { } + //对nodeInfoVOList集合中的作业时间 按照 时间倒序排序 + nodeInfoVOList.sort(Comparator.comparing(NodeInfoVO::getOperateTime).reversed()); result.setNodeInfoVOList(nodeInfoVOList); // 配送签收 @@ -372,6 +374,13 @@ public class LogpmDataSearchServiceImpl implements ILogpmDataSearchService { } + + + //对nodeInfoVOList集合中的作业时间 按照 时间倒序排序 + nodeInfoVOList.sort(Comparator.comparing(NodeInfoVO::getOperateTime).reversed()); + + + result.setNodeInfoVOList(nodeInfoVOList); // 配送签收 diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.java index 9d8cc30d7..424d97e50 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionSignforMapper.java @@ -495,4 +495,6 @@ public interface DistributionSignforMapper extends BaseMapper + + + UPDATE logpm_distribution_signfor SET + signee_name = #{user.nickName}, + signee_id = #{user.userId}, + received_quantity = ( received_quantity + #{nub} ) + WHERE + is_deleted =0 and delivery_id = #{deliveryId} and reservation_id = #{reservationId} + + DELETE FROM logpm_distribution_signfor diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java index 32706b204..b11d4c9db 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java @@ -10641,7 +10641,7 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl distributionParcelListEntities = distributionReservationMapper.selectPackageListByReservationId(reservationId); @@ -3894,16 +3896,16 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl 0) { - reservationEntity.setLoadingStatus(ReservationLoadingStatusConstant.bufenzhuangche.getValue()); + updateEntity.setLoadingStatus(ReservationLoadingStatusConstant.bufenzhuangche.getValue()); } if (loadingNum == 0) { - reservationEntity.setLoadingStatus(ReservationLoadingStatusConstant.daizhuangche.getValue()); + updateEntity.setLoadingStatus(ReservationLoadingStatusConstant.daizhuangche.getValue()); } } } @@ -3912,28 +3914,28 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl 0) { - reservationEntity.setSigningStatus(ReservationSigningStatusConstant.bufenqianshou.getValue()); + updateEntity.setSigningStatus(ReservationSigningStatusConstant.bufenqianshou.getValue()); } if (signingNum == 0) { - reservationEntity.setSigningStatus(ReservationSigningStatusConstant.daiqianshou.getValue()); + updateEntity.setSigningStatus(ReservationSigningStatusConstant.daiqianshou.getValue()); } if (stockUpStatus) { - reservationEntity.setStockStatus(ReservationStockupStatusConstant.yibeihuo.getValue()); + updateEntity.setStockStatus(ReservationStockupStatusConstant.yibeihuo.getValue()); } else { //判断是否都为完成签收 Integer stockNum = distributionStockMapper.selectStockNumByReservationId(reservationId); //判断当前客户是否签收完成了 if (stockNum > 0) { - reservationEntity.setStockStatus(ReservationStockupStatusConstant.daibeihuo.getValue()); + updateEntity.setStockStatus(ReservationStockupStatusConstant.daibeihuo.getValue()); } else { - reservationEntity.setStockStatus(ReservationStockupStatusConstant.weibeihuo.getValue()); + updateEntity.setStockStatus(ReservationStockupStatusConstant.weibeihuo.getValue()); } } if ((reservationEntity.getReservationNum() + reservationEntity.getReservationStockListNum()) == 0) { - reservationEntity.setReservationStatus(ReservationStatusConstant.yiquexiao.getValue()); + updateEntity.setReservationStatus(ReservationStatusConstant.yiquexiao.getValue()); } - this.updateById(reservationEntity); + this.updateById(updateEntity); } } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java index fd5b1563c..97a14bcea 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java @@ -4377,10 +4377,12 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl