From 7955fbd1df3186553b5338e13bc698fd236b7873 Mon Sep 17 00:00:00 2001 From: PigBaoBei <2739175034@qq.com> Date: Sun, 22 Sep 2024 23:11:01 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A3=85=E8=BD=A6=E3=80=81=E7=AD=BE=E6=94=B6?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=9B=9E=E5=BA=93=E6=A0=A1=E9=AA=8C=EF=BC=8C?= =?UTF-8?q?=E5=AE=8C=E5=96=84=E5=BC=82=E5=B8=B8=E5=92=8C=E5=9B=9E=E5=BA=93?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../IDistributionLoadscanAbnormalClient.java | 5 +++-- .../feign/IWarehouseRetentionScanClient.java | 2 +- .../DistributionLoadscanAbnormalClient.java | 2 ++ .../DistributionDeliveryListServiceImpl.java | 11 +++++++++++ .../impl/DistributionSignforServiceImpl.java | 16 +++++++++++++++- .../feign/WarehouseRetentionScanClient.java | 2 -- .../WarehouseRetentionRecordServiceImpl.java | 4 +++- 7 files changed, 35 insertions(+), 7 deletions(-) diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionLoadscanAbnormalClient.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionLoadscanAbnormalClient.java index ebf9f2f64..3d7c05d9f 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionLoadscanAbnormalClient.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionLoadscanAbnormalClient.java @@ -17,6 +17,7 @@ package com.logpm.distribution.feign; import com.logpm.distribution.entity.DistributionLoadscanAbnormalEntity; +import org.springblade.common.constant.ModuleNameConstant; import org.springblade.core.mp.support.BladePage; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.web.bind.annotation.GetMapping; @@ -29,7 +30,7 @@ import org.springframework.web.bind.annotation.RequestParam; * @since 2023-09-22 */ @FeignClient( - value = "loadscanAbnormal" + value = ModuleNameConstant.APPLICATION_DISTRIBUTION_NAME ) public interface IDistributionLoadscanAbnormalClient { @@ -47,5 +48,5 @@ public interface IDistributionLoadscanAbnormalClient { BladePage loadscanAbnormalTop(@RequestParam("current") Integer current, @RequestParam("size") Integer size); @GetMapping(TOP+"completeAbnormal") - void completeAbnormal(Long abnormalId); + void completeAbnormal(@RequestParam("abnormalId")Long abnormalId); } diff --git a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/feign/IWarehouseRetentionScanClient.java b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/feign/IWarehouseRetentionScanClient.java index b1a8d00fc..221bcf0ed 100644 --- a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/feign/IWarehouseRetentionScanClient.java +++ b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/feign/IWarehouseRetentionScanClient.java @@ -73,5 +73,5 @@ public interface IWarehouseRetentionScanClient { List getRetentionScanEntityListByWarehouseId(@RequestParam("warehouseId") Long warehouseId,@RequestParam("taskTimeStart")String taskTimeStart,@RequestParam("taskTimeEnd")String taskTimeEnd); @GetMapping(TOP+"/judgeIsHaveRetention") - boolean judgeIsHaveRetention(String orderPackageCode, Long id); + boolean judgeIsHaveRetention(@RequestParam("orderPackageCode")String orderPackageCode,@RequestParam("warehouseId") Long warehouseId); } diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionLoadscanAbnormalClient.java b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionLoadscanAbnormalClient.java index a02b5fbb3..7f85bb9df 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionLoadscanAbnormalClient.java +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/feign/DistributionLoadscanAbnormalClient.java @@ -24,6 +24,7 @@ import org.springblade.common.constant.common.IsOrNoConstant; import org.springblade.core.mp.support.BladePage; import org.springblade.core.mp.support.Condition; import org.springblade.core.mp.support.Query; +import org.springframework.transaction.annotation.Transactional; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RestController; import springfox.documentation.annotations.ApiIgnore; @@ -52,6 +53,7 @@ public class DistributionLoadscanAbnormalClient implements IDistributionLoadscan } @Override + @Transactional public void completeAbnormal(Long abnormalId) { DistributionLoadscanAbnormalEntity distributionLoadscanAbnormalEntity = new DistributionLoadscanAbnormalEntity(); distributionLoadscanAbnormalEntity.setId(abnormalId); 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 05ca7e64b..0c1a7ffb1 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 @@ -6814,6 +6814,11 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl>>>>>packageCode:{},reservationId:{}", distrilbutionloadingscanDTO.getBarcode(), distrilbutionloadingscanDTO.getReservationId()); @@ -9246,6 +9256,7 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl abnormalEntities = distributionLoadscanAbnormalService.list(Wrappers.query().lambda() + .eq(DistributionLoadscanAbnormalEntity::getReservationId, distributionSignfor.getReservationId()) + .ne(DistributionLoadscanAbnormalEntity::getAbnormalType, LoadingAbnormalTypeConstant.zhuangcheyichang.getValue()) + ); + if (!abnormalEntities.isEmpty()) { + boolean isAuditing = abnormalEntities.stream().anyMatch(a -> LoadingAbnormalAuditingStatusConstant.daishenhe.getValue().equals(a.getAuditingStatus())); + if (isAuditing){ + return Resp.scanFail("当前客户存在异常未操作","当前客户存在异常未操作"); + }else { + boolean isComplete = abnormalEntities.stream().anyMatch(b -> b.getComplete() != 1); + if (isComplete){ + return Resp.scanFail("当前客户存在回库未完成","当前客户存在回库未完成"); + } + } + } int loadingPackageNum = 0; int loadingInventoryNum = 0; int signingPackageNum = 0; diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/feign/WarehouseRetentionScanClient.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/feign/WarehouseRetentionScanClient.java index 5a9a67198..9ad10f3a3 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/feign/WarehouseRetentionScanClient.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/feign/WarehouseRetentionScanClient.java @@ -83,8 +83,6 @@ public class WarehouseRetentionScanClient implements IWarehouseRetentionScanClie @Override public boolean judgeIsHaveRetention(String orderPackageCode, Long warehouseId) { - - return warehouseRetentionScanService.judgeIsHaveRetention(orderPackageCode,warehouseId); } diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseRetentionRecordServiceImpl.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseRetentionRecordServiceImpl.java index 9b652d73e..4f97b208b 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseRetentionRecordServiceImpl.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseRetentionRecordServiceImpl.java @@ -477,7 +477,9 @@ public class WarehouseRetentionRecordServiceImpl extends BaseServiceImpl