From 34013d4966bdde7709ed3d70d69930b75c034ada Mon Sep 17 00:00:00 2001 From: PigBaoBei <2739175034@qq.com> Date: Mon, 26 Aug 2024 09:54:36 +0800 Subject: [PATCH 1/6] =?UTF-8?q?=E8=87=AA=E6=8F=90=E8=B5=84=E6=BA=90?= =?UTF-8?q?=E9=87=8A=E6=94=BEBUG=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/DistributionAsyncServiceImpl.java | 4 ++ .../DistrilbutionBillLadingServiceImpl.java | 46 ++++++++++++++++++- 2 files changed, 49 insertions(+), 1 deletion(-) diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionAsyncServiceImpl.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionAsyncServiceImpl.java index 3cd75aac4..d333a395a 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionAsyncServiceImpl.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionAsyncServiceImpl.java @@ -1870,6 +1870,10 @@ public class DistributionAsyncServiceImpl implements IDistributionAsyncService { .eq(DistrilbutionBillPackageEntity::getBillLadingId, l) .in(DistrilbutionBillPackageEntity::getParceListId, packageIds) ); + //增加释放日志 + + + } String collect = distributionParcelListEntities.stream().map(DistributionParcelListEntity::getOrderCode).distinct().collect(Collectors.joining(",")); distributionStockArticleService.maintenanceOrderInfo(collect, warehouseId); diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java index 0bfaf120a..74f9a0af4 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java @@ -126,6 +126,7 @@ import org.springblade.common.constant.order.OrderStatusConstant; import org.springblade.common.constant.orderpackage.OrderPackageLoadingStatusConstant; import org.springblade.common.constant.orderpackage.OrderPackageReservationStatusConstant; import org.springblade.common.constant.orderpackage.OrderPackageStatusConstant; +import org.springblade.common.constant.orderpackage.OrderPackageStockupStatusConstant; import org.springblade.common.constant.pda.PdaAudioLingoStatus; import org.springblade.common.constant.reservation.ReservationOrderStatusConstant; import org.springblade.common.constant.reservation.ReservationPackageStatusConstant; @@ -3614,7 +3615,7 @@ public class DistrilbutionBillLadingServiceImpl extends BaseServiceImpl 0){ @@ -3730,6 +3731,49 @@ public class DistrilbutionBillLadingServiceImpl extends BaseServiceImpl list = distrilbutionBillPackageService.list(Wrappers.query().lambda() + .eq(DistrilbutionBillPackageEntity::getBillLadingId, l) + .ne(DistrilbutionBillPackageEntity::getPacketBarStatus, 2) + ); + if (Func.isNotEmpty(list)) { + List ids = list.stream().map(DistrilbutionBillPackageEntity::getParceListId).collect(Collectors.toList()); + //查询包件 + List distributionParcelListEntities = distributionParcelListService.listByIds(ids); + List packageIds = distributionParcelListEntities.stream().filter(f -> !OrderPackageLoadingStatusConstant.yizhuangche.getValue().equals(f.getOrderPackageLoadingStatus()) || !OrderPackageStatusConstant.yiqianshou.getValue().equals(f.getOrderPackageStatus())).map(DistributionParcelListEntity::getId).collect(Collectors.toList()); + if (Func.isNotEmpty(packageIds)) { + distributionParcelListService.update(new UpdateWrapper().lambda() + .set(DistributionParcelListEntity::getOrderPackageReservationStatus, OrderPackageReservationStatusConstant.daiyuyue.getValue()) + .set(DistributionParcelListEntity::getOrderPackageLoadingStatus, OrderPackageLoadingStatusConstant.weizhuancghe.getValue()) + .set(DistributionParcelListEntity::getOrderPackageStatus, OrderPackageStatusConstant.yiruku.getValue()) + .set(DistributionParcelListEntity::getOrderPackageStockupStatus, OrderPackageStockupStatusConstant.daibeihuo.getValue()) + .in(DistributionParcelListEntity::getId, packageIds) + ); + distrilbutionBillPackageService.update(new UpdateWrapper().lambda() + .set(DistrilbutionBillPackageEntity::getPacketBarStatus, 2) + .eq(DistrilbutionBillPackageEntity::getBillLadingId, l) + .in(DistrilbutionBillPackageEntity::getParceListId, packageIds) + ); + List logList = new ArrayList<>(); + + for (DistributionParcelListEntity distributionParcelListEntity : distributionParcelListEntities) { + String content = "包件在" + warehouse.getName() + "由" + AuthUtil.getNickName() + "取消自提,操作方式:复核自提单包件释放,自提批次号:" + pickupBatch; + JSONObject logJS = handleLogJSONObject(warehouse, AuthUtil.getUser(), distributionParcelListEntity.getOrderPackageCode(), content, WorkNodeEnums.CANCEL_BILLOFLADING.getCode()); + logList.add(logJS); + } + if (!logList.isEmpty()) { + trunklinePackageTrackLogClient.addPackageTrackLog(logList); + } + + } + String collect = distributionParcelListEntities.stream().map(DistributionParcelListEntity::getOrderCode).distinct().collect(Collectors.joining(",")); + distributionStockArticleService.maintenanceOrderInfo(collect, warehouse.getId()); + //维护自提单订单信息 + distrilbutionBillStockService.maintenanceOrderInfo(l); + } + + } + private void sendFactory(BasicdataWarehouseEntity myCurrentWarehouse, Set parcelListIds) { try { // ladingScanEntities中的包件id数据封装为set From b7133c1e7d28c2c6ecef987b1541e8ae42fb6a23 Mon Sep 17 00:00:00 2001 From: PigBaoBei <2739175034@qq.com> Date: Mon, 26 Aug 2024 10:27:59 +0800 Subject: [PATCH 2/6] =?UTF-8?q?=E8=87=AA=E6=8F=90=E8=B5=84=E6=BA=90?= =?UTF-8?q?=E9=87=8A=E6=94=BEBUG=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/DistrilbutionBillLadingServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java index 74f9a0af4..907ab32fe 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java @@ -3757,7 +3757,7 @@ public class DistrilbutionBillLadingServiceImpl extends BaseServiceImpl logList = new ArrayList<>(); for (DistributionParcelListEntity distributionParcelListEntity : distributionParcelListEntities) { - String content = "包件在" + warehouse.getName() + "由" + AuthUtil.getNickName() + "取消自提,操作方式:复核自提单包件释放,自提批次号:" + pickupBatch; + String content = "包件在" + warehouse.getName() + "由" + AuthUtil.getNickName() + "确认自提,取消包件计划,操作方式:复核自提单包件释放,自提批次号:" + pickupBatch; JSONObject logJS = handleLogJSONObject(warehouse, AuthUtil.getUser(), distributionParcelListEntity.getOrderPackageCode(), content, WorkNodeEnums.CANCEL_BILLOFLADING.getCode()); logList.add(logJS); } From cc9965bc3c60578bd9110018ae24c8940b95cf9b Mon Sep 17 00:00:00 2001 From: PigBaoBei <2739175034@qq.com> Date: Mon, 26 Aug 2024 10:32:20 +0800 Subject: [PATCH 3/6] =?UTF-8?q?=E8=87=AA=E6=8F=90=E8=BF=90=E5=8D=95?= =?UTF-8?q?=E4=BF=A1=E6=81=AF=E6=8E=A8=E9=80=81=E8=87=B3=E5=B9=B2=E7=BA=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/DistrilbutionBillLadingMapper.xml | 2 +- .../impl/DistrilbutionBillLadingServiceImpl.java | 16 ++++++++++++++-- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml index 77f96c770..7bba4abee 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml @@ -1022,7 +1022,7 @@ GROUP_CONCAT( DISTINCT t.signOrderCode ) AS signOrderCode, 3 AS type, #{userId} AS userId, - #{userName} AS nickName + #{nickName} AS nickName FROM ( SELECT diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java index 907ab32fe..f8ea3e3c3 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java @@ -109,6 +109,7 @@ import com.logpm.oldproject.dto.SignPushDataUnitDTO; import com.logpm.oldproject.feign.IOldSignPushClient; import com.logpm.trunkline.dto.WaybillLogDTO; import com.logpm.trunkline.feign.ITrunklinePackageTrackLogClient; +import com.logpm.trunkline.feign.ITrunklineWaybillTrackClient; import com.logpm.warehouse.feign.IWarehouseUpdownTypeClient; import com.sun.org.apache.xpath.internal.operations.Bool; import lombok.extern.log4j.Log4j2; @@ -255,6 +256,9 @@ public class DistrilbutionBillLadingServiceImpl extends BaseServiceImpl selectDistrilbutionBillLadingPage(IPage page, DistrilbutionBillLadingVO distrilbutionBillLading) { @@ -3698,8 +3702,7 @@ public class DistrilbutionBillLadingServiceImpl extends BaseServiceImpl mapList = baseMapper.getWaybillSignforData(billLadingEntity.getId(),AuthUtil.getUser().getUserId(),AuthUtil.getUser().getNickName()); - + handletrunklineWaybillSignLog(billLadingEntity.getId()); } // 回传工厂数据 sendFactory(myCurrentWarehouse, parcelListIds); @@ -3731,6 +3734,15 @@ public class DistrilbutionBillLadingServiceImpl extends BaseServiceImpl mapList = baseMapper.getWaybillSignforData(id, AuthUtil.getUser().getUserId(), AuthUtil.getUser().getNickName()); + if (!mapList.isEmpty()) { + for (WaybillLogDTO waybillLogDTO : mapList) { + trunklineWaybillTrackClient.addSignWaybillLog(waybillLogDTO); + } + } + } + public void releaseBillLadingResource(Long l, BasicdataWarehouseEntity warehouse,String pickupBatch) { List list = distrilbutionBillPackageService.list(Wrappers.query().lambda() .eq(DistrilbutionBillPackageEntity::getBillLadingId, l) From 78a65d3ee167bf39a67ad23b5f684231ca442593 Mon Sep 17 00:00:00 2001 From: PigBaoBei <2739175034@qq.com> Date: Mon, 26 Aug 2024 10:47:09 +0800 Subject: [PATCH 4/6] =?UTF-8?q?=E8=87=AA=E6=8F=90=E8=BF=90=E5=8D=95?= =?UTF-8?q?=E4=BF=A1=E6=81=AF=E6=8E=A8=E9=80=81=E8=87=B3=E5=B9=B2=E7=BA=BF?= =?UTF-8?q?BUG=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../distribution/mapper/DistrilbutionBillLadingMapper.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.java index 7cd50b677..c491f91c2 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.java @@ -197,7 +197,7 @@ public interface DistrilbutionBillLadingMapper extends BaseMapper getWaybillSignforData(@Param("param")Long id,@Param("userId") Long userId,@Param("nickName") String nickName); + List getWaybillSignforData(@Param("id")Long id,@Param("userId") Long userId,@Param("nickName") String nickName); // Page getInventoryPage(IPage page, DistrilbutionBillLadingEntity distrilbutionBillLadingEntity); From 8a7accdd225df3c6a515282128757cdd507cd097 Mon Sep 17 00:00:00 2001 From: PigBaoBei <2739175034@qq.com> Date: Mon, 26 Aug 2024 15:17:19 +0800 Subject: [PATCH 5/6] =?UTF-8?q?=E8=87=AA=E6=8F=90=E6=8E=A8=E9=80=81?= =?UTF-8?q?=E8=BF=90=E5=8D=95=E4=BF=A1=E6=81=AF=E7=B1=BB=E5=9E=8B=E5=8F=98?= =?UTF-8?q?=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml index 7bba4abee..de53a351d 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml @@ -1020,7 +1020,7 @@ GROUP_CONCAT( DISTINCT t.loadingUser ) AS loadingUser, GROUP_CONCAT( DISTINCT t.signUser ) AS signUser, GROUP_CONCAT( DISTINCT t.signOrderCode ) AS signOrderCode, - 3 AS type, + 4 AS type, #{userId} AS userId, #{nickName} AS nickName FROM From aa2bade4f15c1eb75a220c1c6048a4d8326e4a79 Mon Sep 17 00:00:00 2001 From: PigBaoBei <2739175034@qq.com> Date: Tue, 27 Aug 2024 10:08:10 +0800 Subject: [PATCH 6/6] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml index de53a351d..9027811e6 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillLadingMapper.xml @@ -984,7 +984,7 @@ ldsld.id