diff --git a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionReservationStockarticleEntity.java b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionReservationStockarticleEntity.java index 19d15fb48..c173a4b1e 100644 --- a/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionReservationStockarticleEntity.java +++ b/blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionReservationStockarticleEntity.java @@ -66,7 +66,7 @@ public class DistributionReservationStockarticleEntity extends TenantEntity { /** * 订单状态;1-正常、2-取消 */ - @ApiModelProperty(value = "订单码") + @ApiModelProperty(value = "订单状态") private String stockArticleStatus; diff --git a/blade-service/logpm-basicdata/src/main/resources/application-dev.yml b/blade-service/logpm-basicdata/src/main/resources/application-dev.yml index abb6e8a17..8286d310f 100644 --- a/blade-service/logpm-basicdata/src/main/resources/application-dev.yml +++ b/blade-service/logpm-basicdata/src/main/resources/application-dev.yml @@ -43,3 +43,14 @@ spring: username: ${blade.datasource.basicdata.slave.username} password: ${blade.datasource.basicdata.slave.password} +xxl: + job: + accessToken: '' + admin: + addresses: http://127.0.0.1:7009/xxl-job-admin + executor: + appname: logpm-basicdata-xxljob + ip: 127.0.0.1 + logpath: ../data/applogs/logpm-factory-data-xxljob/jobhandler + logretentiondays: -1 + port: 17018 diff --git a/blade-service/logpm-basicdata/src/main/resources/application-prod.yml b/blade-service/logpm-basicdata/src/main/resources/application-prod.yml index abb6e8a17..40f040c5b 100644 --- a/blade-service/logpm-basicdata/src/main/resources/application-prod.yml +++ b/blade-service/logpm-basicdata/src/main/resources/application-prod.yml @@ -43,3 +43,14 @@ spring: username: ${blade.datasource.basicdata.slave.username} password: ${blade.datasource.basicdata.slave.password} +xxl: + job: + accessToken: '' + admin: + addresses: http://172.16.128.147:7009/xxl-job-admin + executor: + appname: logpm-basicdata-xxljob + ip: 127.0.0.1 + logpath: ../data/applogs/logpm-factory-data-xxljob/jobhandler + logretentiondays: -1 + port: 17018 diff --git a/blade-service/logpm-basicdata/src/main/resources/application-test.yml b/blade-service/logpm-basicdata/src/main/resources/application-test.yml index df229dcb5..0235f16a8 100644 --- a/blade-service/logpm-basicdata/src/main/resources/application-test.yml +++ b/blade-service/logpm-basicdata/src/main/resources/application-test.yml @@ -43,3 +43,14 @@ spring: username: ${blade.datasource.basicdata.slave.username} password: ${blade.datasource.basicdata.slave.password} +xxl: + job: + accessToken: '' + admin: + addresses: http://127.0.0.1:7009/xxl-job-admin + executor: + appname: logpm-basicdata-xxljob + ip: 127.0.0.1 + logpath: ../data/applogs/logpm-factory-data-xxljob/jobhandler + logretentiondays: -1 + port: 17018 diff --git a/blade-service/logpm-basicdata/src/main/resources/application.yml b/blade-service/logpm-basicdata/src/main/resources/application.yml index fc025c74f..a84f9a5a7 100644 --- a/blade-service/logpm-basicdata/src/main/resources/application.yml +++ b/blade-service/logpm-basicdata/src/main/resources/application.yml @@ -20,15 +20,4 @@ spring: main: allow-circular-references: true -xxl: - job: - accessToken: '' - admin: - addresses: http://127.0.0.1:7009/xxl-job-admin - executor: - appname: logpm-basicdata-xxljob - ip: 127.0.0.1 - logpath: ../data/applogs/logpm-factory-data-xxljob/jobhandler - logretentiondays: -1 - port: 17018 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 f1c201155..a0f818d69 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 @@ -6535,6 +6535,7 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib //先查询预约单对应有哪些订单 QueryWrapper<DistributionReservationStockarticleEntity> queryWrapper = new QueryWrapper<>(); queryWrapper.eq("reservation_id", reservationId); + queryWrapper.ne("stock_article_status", 2); List<DistributionReservationStockarticleEntity> reservationStockarticleList = distributionReservationStockarticleService.list(queryWrapper); List<Map<String, Object>> ls = new ArrayList<>(); BigDecimal totalPrice = BigDecimal.ZERO; diff --git a/blade-service/logpm-factory/src/main/java/com/logpm/factory/oupai/service/impl/OpFailRetryPushPackageServiceImpl.java b/blade-service/logpm-factory/src/main/java/com/logpm/factory/oupai/service/impl/OpFailRetryPushPackageServiceImpl.java index 8fc004111..a1077074e 100644 --- a/blade-service/logpm-factory/src/main/java/com/logpm/factory/oupai/service/impl/OpFailRetryPushPackageServiceImpl.java +++ b/blade-service/logpm-factory/src/main/java/com/logpm/factory/oupai/service/impl/OpFailRetryPushPackageServiceImpl.java @@ -29,7 +29,7 @@ public class OpFailRetryPushPackageServiceImpl implements OpFailRetryPushPackage protected IOuPaiFactoryService ouPaiFactoryService; - protected final int MAX_RETRY_TIMES = 3; + protected final int MAX_RETRY_TIMES = 7; @Async @Override diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineCarsLoadMapper.xml b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineCarsLoadMapper.xml index e9b561f0f..1a5bc1364 100644 --- a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineCarsLoadMapper.xml +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineCarsLoadMapper.xml @@ -495,7 +495,7 @@ </where> </select> <select id="fingPackageCodeByLoadId" resultType="com.logpm.trunkline.dto.LoadScanBrandDTO"> - select dpl.brand_name brand,dpl.accept_warehouse_id startWarehouseId,group_concat(dpl.order_package_code) packageCode + select dpl.brand_name brand,dpl.send_warehouse_id startWarehouseId,group_concat(dpl.order_package_code) packageCode from logpm_trunkline_cars_load_scan t left join logpm_distribution_parcel_list dpl on dpl.order_package_code = t.scan_code and dpl.warehouse_id = #{warehouseId} where t.load_id = #{loadId} diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java index f002cb807..7159d88fc 100644 --- a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java @@ -29,11 +29,73 @@ import com.logpm.factorydata.enums.BrandEnums; import com.logpm.factorydata.util.FactoryDataMessageSender; import com.logpm.factorydata.vo.NodePushMsg; import com.logpm.trunkline.bean.Resp; -import com.logpm.trunkline.dto.*; -import com.logpm.trunkline.entity.*; +import com.logpm.trunkline.dto.BatchUnloadDTO; +import com.logpm.trunkline.dto.InComingDTO; +import com.logpm.trunkline.dto.LoadCarsDTO; +import com.logpm.trunkline.dto.LoadScanBrandDTO; +import com.logpm.trunkline.dto.LoadingPackageDTO; +import com.logpm.trunkline.dto.LoadingZeroDTO; +import com.logpm.trunkline.dto.ProductInfoDTO; +import com.logpm.trunkline.dto.TrunklineCarsLoadDTO; +import com.logpm.trunkline.dto.TrunklineCarsLoadLineDTO; +import com.logpm.trunkline.dto.TrunklineCarsOrderDTO; +import com.logpm.trunkline.dto.UnloadPackageDTO; +import com.logpm.trunkline.dto.UnloadZeroDTO; +import com.logpm.trunkline.entity.TrunklineAdvanceDetailEntity; +import com.logpm.trunkline.entity.TrunklineCarsLoadContractEntity; +import com.logpm.trunkline.entity.TrunklineCarsLoadEntity; +import com.logpm.trunkline.entity.TrunklineCarsLoadFinanceEntity; +import com.logpm.trunkline.entity.TrunklineCarsLoadLineEntity; +import com.logpm.trunkline.entity.TrunklineCarsLoadLogEntity; +import com.logpm.trunkline.entity.TrunklineCarsLoadScanEntity; +import com.logpm.trunkline.entity.TrunklineCarsOrderEntity; +import com.logpm.trunkline.entity.TrunklineCostShareRecordEntity; +import com.logpm.trunkline.entity.TrunklineLoadSignOrderEntity; +import com.logpm.trunkline.entity.TrunklineLoadSignPhotoEntity; import com.logpm.trunkline.mapper.TrunklineCarsLoadMapper; -import com.logpm.trunkline.service.*; -import com.logpm.trunkline.vo.*; +import com.logpm.trunkline.service.ICarsLoadAsyncService; +import com.logpm.trunkline.service.IInComingService; +import com.logpm.trunkline.service.IOpenOrderAsyncService; +import com.logpm.trunkline.service.IPackageTrackLogAsyncService; +import com.logpm.trunkline.service.ITrunklineAdvanceDetailService; +import com.logpm.trunkline.service.ITrunklineCarsLoadContractService; +import com.logpm.trunkline.service.ITrunklineCarsLoadFinanceService; +import com.logpm.trunkline.service.ITrunklineCarsLoadLineService; +import com.logpm.trunkline.service.ITrunklineCarsLoadLogService; +import com.logpm.trunkline.service.ITrunklineCarsLoadScanService; +import com.logpm.trunkline.service.ITrunklineCarsLoadService; +import com.logpm.trunkline.service.ITrunklineCarsLoadingLogService; +import com.logpm.trunkline.service.ITrunklineCarsOrderService; +import com.logpm.trunkline.service.ITrunklineCarsSignLogService; +import com.logpm.trunkline.service.ITrunklineCarsUnloadLogService; +import com.logpm.trunkline.service.ITrunklineCostShareRecordService; +import com.logpm.trunkline.service.ITrunklineLoadSignOrderService; +import com.logpm.trunkline.service.ITrunklineLoadSignPhotoService; +import com.logpm.trunkline.service.ITrunklineWaybillOrderService; +import com.logpm.trunkline.vo.CarsLoadAllOrderVO; +import com.logpm.trunkline.vo.CarsLoadOrderInfoVO; +import com.logpm.trunkline.vo.CarsLoadWaybillInfoVO; +import com.logpm.trunkline.vo.HasNotFinalNodeIdDataVO; +import com.logpm.trunkline.vo.LoadScanFinalNodeIdVO; +import com.logpm.trunkline.vo.LoadScanOrderVO; +import com.logpm.trunkline.vo.LoadZeroListVO; +import com.logpm.trunkline.vo.LoadingListGoodsVO; +import com.logpm.trunkline.vo.LoadingListMainVO; +import com.logpm.trunkline.vo.NodeNumDataVO; +import com.logpm.trunkline.vo.OrderScanDetailVO; +import com.logpm.trunkline.vo.SignOrderDetailVO; +import com.logpm.trunkline.vo.SignPackageVO; +import com.logpm.trunkline.vo.SignScanOrderVO; +import com.logpm.trunkline.vo.TripartiteTransferVO; +import com.logpm.trunkline.vo.TrunklineCarsLoadLoadingListVO; +import com.logpm.trunkline.vo.TrunklineCarsLoadScanVO; +import com.logpm.trunkline.vo.TrunklineCarsLoadVO; +import com.logpm.trunkline.vo.TrunklineLoadSignOrderVO; +import com.logpm.trunkline.vo.UnloadPackageVO; +import com.logpm.trunkline.vo.UnloadScanOrderVO; +import com.logpm.trunkline.vo.UnloadZeroVO; +import com.logpm.trunkline.vo.WaybillCarsLoadVO; +import com.logpm.trunkline.vo.ZeroSuppleVO; import com.logpm.warehouse.entity.WarehouseWayBillDetail; import com.logpm.warehouse.entity.WarehouseWaybillEntity; import com.logpm.warehouse.feign.IWarehouseTrayTypeClient; @@ -43,7 +105,11 @@ import com.logpm.warehouse.feign.IWarehouseWaybillDetailClient; import lombok.AllArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang.StringEscapeUtils; -import org.springblade.common.constant.*; +import org.springblade.common.constant.CodeNumConstant; +import org.springblade.common.constant.DictBizConstant; +import org.springblade.common.constant.IncomingTypeEnum; +import org.springblade.common.constant.RabbitConstant; +import org.springblade.common.constant.WorkNodeEnums; import org.springblade.common.constant.carsload.CarsLoadLogTypeConstant; import org.springblade.common.exception.CustomerException; import org.springblade.common.utils.CommonUtil; @@ -62,7 +128,14 @@ import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import java.math.BigDecimal; -import java.util.*; +import java.util.ArrayList; +import java.util.Date; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import java.util.TreeSet; @Slf4j @Service @@ -156,7 +229,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL String fullLoadRate = loadCarsDTO.getFullLoadRate(); BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ + if (Objects.isNull(warehouseEntity)) { log.warn("#############startCarByLoadId: 仓库信息不存在 warehouseId={}", warehouseId); throw new CustomerException(400, "仓库信息不存在"); } @@ -227,8 +300,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL List<String> orderPackageCodes = trunklineCarsLoadScanService.findPackageListByLoadId(loadId); - String content = "包件在 "+warehouseEntity.getName()+"起始仓发车"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), WorkNodeEnums.INITIAL_WAREHOUSE_DEPART.getCode(),content ); + String content = "包件在 " + warehouseEntity.getName() + "起始仓发车"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), WorkNodeEnums.INITIAL_WAREHOUSE_DEPART.getCode(), content); } catch (Exception e) { log.warn("############startCarByLoadId: 存入日志失败"); @@ -305,8 +378,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL List<String> orderPackageCodes = trunklineCarsLoadScanService.findPackageListByLoadId(loadId); - String content = "包件在 "+warehouseEntity.getName()+"网点发车"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), WorkNodeEnums.TRANSFER_WAREHOUSE_DEPART.getCode(),content ); + String content = "包件在 " + warehouseEntity.getName() + "网点发车"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), WorkNodeEnums.TRANSFER_WAREHOUSE_DEPART.getCode(), content); } catch (Exception e) { log.warn("############startCarByLoadId: 存入日志失败"); } @@ -394,20 +467,20 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL String warehouseCode = basicdataWarehouseEntity.getWarehouseCode(); TrunklineCarsLoadEntity carsLoadEntity = baseMapper.selectById(loadId); - if(Objects.isNull(carsLoadEntity)){ + if (Objects.isNull(carsLoadEntity)) { log.warn("################createCustomerSignOrder: 配载计划不存在 loadId={}", loadId); throw new CustomerException(405, "配载计划不存在"); } Long driverId = carsLoadEntity.getDriverId(); Long driverUserId = null; BasicdataDriverArteryEntity driverArtery = driverArteryClient.getDriverArtery(driverId); - if(!Objects.isNull(driverArtery) && !Objects.isNull(driverArtery.getUserId())){ + if (!Objects.isNull(driverArtery) && !Objects.isNull(driverArtery.getUserId())) { driverUserId = driverArtery.getUserId(); } Long assistantId = carsLoadEntity.getAssistantId(); Long assistantUserId = null; BasicdataDriverArteryEntity assistantArtery = driverArteryClient.getDriverArtery(assistantId); - if(!Objects.isNull(assistantArtery) && !Objects.isNull(assistantArtery.getUserId())){ + if (!Objects.isNull(assistantArtery) && !Objects.isNull(assistantArtery.getUserId())) { assistantUserId = assistantArtery.getUserId(); } @@ -449,7 +522,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL Long warehouseId = loadCarsDTO.getWarehouseId(); BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ + if (Objects.isNull(warehouseEntity)) { log.warn("#############arriveCarByLoadId: 仓库信息不存在 warehouseId={}", warehouseId); throw new CustomerException(400, "仓库信息不存在"); } @@ -530,8 +603,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL List<String> orderPackageCodes = trunklineCarsLoadScanService.findPackageListByLoadId(loadId); - String content = "包件在 "+warehouseEntity.getName()+"到车"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), workNode,content ); + String content = "包件在 " + warehouseEntity.getName() + "到车"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), workNode, content); } catch (Exception e) { log.warn("#############arriveCarByLoadId: 存入日志失败"); @@ -547,7 +620,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL Long warehouseId = loadCarsDTO.getWarehouseId(); BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ + if (Objects.isNull(warehouseEntity)) { log.warn("#############cancelStartCarByLoadId: 仓库信息不存在 warehouseId={}", warehouseId); throw new CustomerException(400, "仓库信息不存在"); } @@ -615,8 +688,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL openOrderAsyncService.saveCancelStartCarLog(currentCarsLoadLineEntity, AuthUtil.getNickName(), AuthUtil.getUserId()); List<String> orderPackageCodes = trunklineCarsLoadScanService.findPackageListByLoadId(loadId); - String content = "包件在 "+warehouseEntity.getName()+"始发仓取消发车"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), WorkNodeEnums.CANCEL_INITIAL_WAREHOUSE_DEPART.getCode(),content ); + String content = "包件在 " + warehouseEntity.getName() + "始发仓取消发车"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), WorkNodeEnums.CANCEL_INITIAL_WAREHOUSE_DEPART.getCode(), content); } catch (Exception e) { log.warn("#############cancelStartCarByLoadId: 存入日志失败"); } @@ -638,8 +711,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL openOrderAsyncService.saveCancelStartCarLog(currentCarsLoadLineEntity, AuthUtil.getNickName(), AuthUtil.getUserId()); List<String> orderPackageCodes = trunklineCarsLoadScanService.findPackageListByLoadId(loadId); - String content = "包件在 "+warehouseEntity.getName()+"网点取消发车"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), WorkNodeEnums.CANEL_TRANSFER_WAREHOUSE_DEPART.getCode(),content ); + String content = "包件在 " + warehouseEntity.getName() + "网点取消发车"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), WorkNodeEnums.CANEL_TRANSFER_WAREHOUSE_DEPART.getCode(), content); } catch (Exception e) { log.warn("#############cancelStartCarByLoadId: 存入日志失败"); @@ -713,7 +786,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL //逻辑删除装车扫描表的数据 List<Long> carsLoadScanIdList = trunklineCarsLoadScanService.findAllIdListByLoadId(loadId); - removeCarsLoadScan(StringUtil.join(carsLoadScanIdList, ","),warehouseId); + removeCarsLoadScan(StringUtil.join(carsLoadScanIdList, ","), warehouseId); try { trunklineCarsLoadLogService.saveLog(carsLoadEntity, currentCarsLoadLineEntity, CarsLoadLogTypeConstant.CANCEL_CARS_LOAD.getValue()); @@ -730,7 +803,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL Long warehouseId = loadCarsDTO.getWarehouseId(); BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ + if (Objects.isNull(warehouseEntity)) { log.warn("#############cancelArriveCarByLoadId: 仓库信息不存在 warehouseId={}", warehouseId); throw new CustomerException(400, "仓库信息不存在"); } @@ -825,8 +898,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL openOrderAsyncService.saveCancelArriveCarLog(currentCarsLoadLineEntity, AuthUtil.getNickName(), AuthUtil.getUserId()); List<String> orderPackageCodes = trunklineCarsLoadScanService.findPackageListByLoadId(loadId); - String content = "包件在 "+warehouseId+"取消到车"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), workNode,content ); + String content = "包件在 " + warehouseId + "取消到车"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), workNode, content); } catch (Exception e) { log.warn("#############cancelArriveCarByLoadId: 存入日志失败"); } @@ -862,7 +935,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL Integer unloadType = loadCarsDTO.getUnloadType(); BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ + if (Objects.isNull(warehouseEntity)) { log.warn("#############unloadByLoadId: 仓库信息不存在 warehouseId={}", warehouseId); throw new CustomerException(400, "仓库信息不存在"); } @@ -969,10 +1042,10 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL //无装车记录异常日志记录 try { carsLoadAsyncService.abnormalListUnloadCheckByLoadIdAndWarehouseId(loadId, warehouseId, currentCarsLoadLineEntity.getNodeName(), AuthUtil.getTenantId(), AuthUtil.getUserId(), AuthUtil.getNickName(), Func.firstLong(AuthUtil.getDeptId())); - List<String> orderPackageCodes = trunklineCarsLoadScanService.findUnloadByLoadIdAndWarehouseId(loadId,warehouseId); + List<String> orderPackageCodes = trunklineCarsLoadScanService.findUnloadByLoadIdAndWarehouseId(loadId, warehouseId); - String content = "包件在 "+warehouseEntity.getName()+"卸车确认"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), node.getCode(),content ); + String content = "包件在 " + warehouseEntity.getName() + "卸车确认"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), node.getCode(), content); } catch (Exception e) { log.warn("###############unloadPackage: 存入异常列表记录失败"); @@ -1709,7 +1782,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL public R startCars(Long loadId, Long warehouseId) { BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ + if (Objects.isNull(warehouseEntity)) { log.warn("#############startCars: 仓库信息不存在 warehouseId={}", warehouseId); return R.fail(400, "仓库信息不存在"); } @@ -1757,8 +1830,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL List<String> orderPackageCodes = trunklineCarsLoadScanService.findPackageListByLoadId(loadId); - String content = "包件在 "+warehouseEntity.getName()+"三方中转发车"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), WorkNodeEnums.TRIPARTITE_TRANSFER_DEPART.getCode(),content ); + String content = "包件在 " + warehouseEntity.getName() + "三方中转发车"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), WorkNodeEnums.TRIPARTITE_TRANSFER_DEPART.getCode(), content); } catch (Exception e) { log.warn("#############startCarByLoadId: 存入日志失败"); @@ -1779,7 +1852,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL public R cancelStartCars(Long loadId, Long warehouseId) { BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ + if (Objects.isNull(warehouseEntity)) { log.warn("#############cancelStartCars: 仓库信息不存在 warehouseId={}", warehouseId); throw new CustomerException(400, "仓库信息不存在"); } @@ -1831,8 +1904,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL trunklineCarsLoadLogService.saveLog(carsLoadEntity, currentCarsLoadLineEntity, CarsLoadLogTypeConstant.CANCEL_FIRST_START_CARS_LOAD.getValue()); List<String> orderPackageCodes = trunklineCarsLoadScanService.findPackageListByLoadId(loadId); - String content = "包件在 "+warehouseEntity.getName()+"三方中转取消发车"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), WorkNodeEnums.CANCEL_TRIPARTITE_TRANSFER_DEPART.getCode(),content ); + String content = "包件在 " + warehouseEntity.getName() + "三方中转取消发车"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), WorkNodeEnums.CANCEL_TRIPARTITE_TRANSFER_DEPART.getCode(), content); } catch (Exception e) { log.warn("#############startCarByLoadId: 存入日志失败"); @@ -1845,7 +1918,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL public R arriveCars(Long loadId, Long warehouseId, String arriveDateStr) { BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ + if (Objects.isNull(warehouseEntity)) { log.warn("#############arriveCars: 仓库信息不存在 warehouseId={}", warehouseId); throw new CustomerException(400, "仓库信息不存在"); } @@ -1893,8 +1966,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL trunklineCarsLoadLogService.saveLog(carsLoadEntity, carsLoadLineEntity, CarsLoadLogTypeConstant.END_ARRIVE_CARS_LOAD.getValue()); List<String> orderPackageCodes = trunklineCarsLoadScanService.findPackageListByLoadId(loadId); - String content = "包件在 "+warehouseEntity.getName()+"三方中转到达"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), WorkNodeEnums.ARRICE_TRIPARTITE_TRANSFER_DEPART.getCode(),content ); + String content = "包件在 " + warehouseEntity.getName() + "三方中转到达"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), WorkNodeEnums.ARRICE_TRIPARTITE_TRANSFER_DEPART.getCode(), content); } catch (Exception e) { log.warn("#############startCarByLoadId: 存入日志失败"); @@ -1907,7 +1980,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL public R signCars(Long loadId, Long warehouseId) { BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ + if (Objects.isNull(warehouseEntity)) { log.warn("#############signCars: 仓库信息不存在 warehouseId={}", warehouseId); throw new CustomerException(400, "仓库信息不存在"); } @@ -1932,14 +2005,14 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL carsLoadEntity.setSignTime(new Date()); updateById(carsLoadEntity); - trunklineCarsLoadScanService.updateScanStatusByLoadId(loadId,"3"); + trunklineCarsLoadScanService.updateScanStatusByLoadId(loadId, "3"); - try{ + try { List<String> orderPackageCodes = trunklineCarsLoadScanService.findSignListOrderPackageCodes(loadId); - String content = "包件在"+warehouseEntity.getName()+"被三方中转整车签收"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), WorkNodeEnums.SIGN_TRIPARTITE_TRANSFER_DEPART.getCode(),content); - }catch (Exception e){ + String content = "包件在" + warehouseEntity.getName() + "被三方中转整车签收"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), WorkNodeEnums.SIGN_TRIPARTITE_TRANSFER_DEPART.getCode(), content); + } catch (Exception e) { log.warn("###########存入日志失败"); } @@ -2024,10 +2097,10 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL // } TrunklineCarsLoadScanEntity isExit = trunklineCarsLoadScanService.findEntityByOrderPackageCodeAndScanStatus(orderPackageCode, "1"); - if(!Objects.isNull(isExit)){ + if (!Objects.isNull(isExit)) { String loadCode = isExit.getLoadCode(); log.warn("##################loadingScan: 包件已经装车 orderPackageCode={}", orderPackageCode); - return R.fail(405, "包件已经装车到"+loadCode); + return R.fail(405, "包件已经装车到" + loadCode); } String loadCode = carsLoadEntity.getCarsNo(); @@ -2121,7 +2194,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL fromWarehouseId = otherParcelListEntity.getWarehouseId(); orderCode = otherParcelListEntity.getOrderCode(); BasicdataWarehouseEntity fromWarehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(fromWarehouseId); - if(!Objects.isNull(fromWarehouseEntity)){ + if (!Objects.isNull(fromWarehouseEntity)) { fromWarehouseName = fromWarehouseEntity.getName(); } WarehouseWaybillEntity waybillEntity = warehouseWaybillClient.findByWaybillNo(waybillNumber); @@ -2164,7 +2237,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL orderCode = parcelListEntity.getOrderCode(); fromWarehouseId = parcelListEntity.getWarehouseId(); BasicdataWarehouseEntity fromWarehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(fromWarehouseId); - if(!Objects.isNull(fromWarehouseEntity)){ + if (!Objects.isNull(fromWarehouseEntity)) { fromWarehouseName = fromWarehouseEntity.getName(); } WarehouseWaybillEntity waybillEntity = warehouseWaybillClient.findByWaybillNo(waybillNo); @@ -2230,8 +2303,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL List<String> orderPackageCodes = new ArrayList<>(); orderPackageCodes.add(orderPackageCode); - String content = "包件在 "+warehouseName+"装车,配载计划目的仓 "+carsLoadScanEntity.getFinalNodeName()+",数据来源仓库 "+fromWarehouseName; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseName, WorkNodeEnums.INITIAL_WAREHOUSE_LOADING.getCode(),content ); + String content = "包件在 " + warehouseName + "装车,配载计划目的仓 " + carsLoadScanEntity.getFinalNodeName() + ",数据来源仓库 " + fromWarehouseName; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseName, WorkNodeEnums.INITIAL_WAREHOUSE_LOADING.getCode(), content); trunklineCarsLoadingLogService.savaLoadingLog(warehouseId, warehouseName, loadId, loadCode, waybillId, waybillNo, orderCode, orderPackageCode, 1, 1, isData, isAbnormal, trayId, trayCode, trayName, fromWarehouseId, loadScanId, remark); @@ -3537,7 +3610,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL String marketName = signOrderEntity.getMallName(); BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ + if (Objects.isNull(warehouseEntity)) { log.warn("##############signScanPackageCode: 仓库信息不存在 warehouseId={}", warehouseId); return R.fail(405, "仓库信息不存在"); } @@ -3682,16 +3755,34 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL //重新计算签收单的数量 updateSignOrderNumBySignOrderId(signOrderId); - try{ - List<String> orderPackageCodes = new ArrayList<>(); - + List<String> orderPackageCodes = new ArrayList<>(); + try { orderPackageCodes.add(orderPackageCode); - String content = "包件在 "+warehouseEntity.getName()+"直发商家签收"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), WorkNodeEnums.SIGN_DIRECT_SHIPPER.getCode(),content ); - }catch (Exception e){ + String content = "包件在 " + warehouseEntity.getName() + "直发商家签收"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), WorkNodeEnums.SIGN_DIRECT_SHIPPER.getCode(), content); + } catch (Exception e) { log.warn("###########存入日志信息失败"); } - + // 推送签收数据给工厂 + try { + DistributionParcelListEntity parcelListEntity = distributionParcelListClient.findByPacketBarCodeAndWarehouseId(orderPackageCode, warehouseId); + if (ObjectUtil.isNotEmpty(parcelListEntity)) { + List<Object> contents = new ArrayList<>(); + JSONObject jsonObject = new JSONObject(); + jsonObject.put("packageCode", orderPackageCode); + contents.add(jsonObject); + NodePushMsg msg = new NodePushMsg(); + msg.setNode(WorkNodeEnums.CLERK_REVIEW); + msg.setBrand(BrandEnums.getByValue(parcelListEntity.getBrandName())); + msg.setOperator(AuthUtil.getNickName()); + msg.setOperatorTime(new Date()); + msg.setContent(contents); + log.info("推送工厂数据:{}", JSONUtil.toJsonStr(msg)); + factoryDataMessageSender.sendNodeDataByBrand(msg); + } + } catch (Exception e) { + log.error("推送签收数据给工厂失败 {}", e); + } return R.success("签收成功"); } @@ -4007,26 +4098,26 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL } @Override - public R signLoadScanByIds(List<Long> loadScanIds,Long warehouseId) { + public R signLoadScanByIds(List<Long> loadScanIds, Long warehouseId) { - if(loadScanIds.isEmpty()){ - log.warn("############signLoadScanByIds: 数据id为空 loadScanIds={}",loadScanIds); - return R.fail(405,"数据id为空"); + if (loadScanIds.isEmpty()) { + log.warn("############signLoadScanByIds: 数据id为空 loadScanIds={}", loadScanIds); + return R.fail(405, "数据id为空"); } BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); - if(Objects.isNull(warehouseEntity)){ - log.warn("############signLoadScanByIds: 仓库信息不存在 warehouseId={}",warehouseId); - return R.fail(405,"仓库信息不存在"); + if (Objects.isNull(warehouseEntity)) { + log.warn("############signLoadScanByIds: 仓库信息不存在 warehouseId={}", warehouseId); + return R.fail(405, "仓库信息不存在"); } trunklineCarsLoadScanService.updateScanStatus(loadScanIds, "3"); - try{ + try { List<String> orderPackageCodes = trunklineCarsLoadScanService.findSignListOrderPackageCodesByIds(loadScanIds); - String content = "包件在"+warehouseEntity.getName()+"被三方中转签收"; - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseEntity.getName(), WorkNodeEnums.SIGN_TRIPARTITE_TRANSFER_DEPART.getCode(),content); - }catch (Exception e){ + String content = "包件在" + warehouseEntity.getName() + "被三方中转签收"; + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseEntity.getName(), WorkNodeEnums.SIGN_TRIPARTITE_TRANSFER_DEPART.getCode(), content); + } catch (Exception e) { log.warn("###########存入日志失败"); } @@ -4248,7 +4339,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL return R.success("添加成功"); } -// @Retryable(value = CustomerException.class, maxAttempts = 3, backoff = @Backoff(value = 3000, multiplier = 1.5)) + // @Retryable(value = CustomerException.class, maxAttempts = 3, backoff = @Backoff(value = 3000, multiplier = 1.5)) @Override public void sendRabbitMessageLoadScanData(String jsonMsg) { String queue = RabbitConstant.INCOMING_TO_LOAD_QUEUE; @@ -4310,14 +4401,14 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL String routing = RabbitConstant.OPEN_ORDER_LOAD_SCAN_ROUTING; WarehouseWaybillEntity waybillEntity = warehouseWaybillClient.findByWaybillId(waybillId); - if(Objects.isNull(waybillEntity)){ - log.warn("#############sendRabbitMessageOpenOrder: 运单信息不存在 waybillId={}",waybillId); + if (Objects.isNull(waybillEntity)) { + log.warn("#############sendRabbitMessageOpenOrder: 运单信息不存在 waybillId={}", waybillId); return; } JSONObject jsonObject = new JSONObject(); - jsonObject.put("waybillId",waybillId); - jsonObject.put("waybillNo",waybillEntity.getWaybillNo()); - jsonObject.put("advanceIds",advanceIds); + jsonObject.put("waybillId", waybillId); + jsonObject.put("waybillNo", waybillEntity.getWaybillNo()); + jsonObject.put("advanceIds", advanceIds); String jsonMsg = jsonObject.toJSONString(); String msgId = IdUtil.simpleUUID(); @@ -4587,7 +4678,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL Long fromWarehouseId = carsLoadScanEntity.getFromWarehouseId(); String fromWarehouseName = null; BasicdataWarehouseEntity fromWarehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(fromWarehouseId); - if(!Objects.isNull(fromWarehouseEntity)){ + if (!Objects.isNull(fromWarehouseEntity)) { fromWarehouseName = fromWarehouseEntity.getName(); } @@ -4623,8 +4714,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL List<String> orderPackageCodes = new ArrayList<>(); orderPackageCodes.add(scanCode); - String content = "包件在 "+warehouseName+"取消装车,配载计划目的仓 "+carsLoadScanEntity.getFinalNodeName(); - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseName, WorkNodeEnums.CANCEL_INITIAL_WAREHOUSE_LOADING.getCode(),content ); + String content = "包件在 " + warehouseName + "取消装车,配载计划目的仓 " + carsLoadScanEntity.getFinalNodeName(); + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseName, WorkNodeEnums.CANCEL_INITIAL_WAREHOUSE_LOADING.getCode(), content); } else { if (StringUtil.isNotBlank(trayCode)) { @@ -5082,13 +5173,13 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL } updateNumByLoadId(loadId); - try{ + try { List<String> orderPackageCodes = new ArrayList<>(); orderPackageCodes.add(orderPackageCode); - String content = "包件在 "+warehouseName+"卸车,卸车方式:"+ IncomingTypeEnum.getValue(incomingType); - packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(),AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()),AuthUtil.getNickName(),orderPackageCodes,warehouseId,warehouseName, WorkNodeEnums.UNLOAD_INCOMING_WAREHOUSE.getCode(),content ); - }catch (Exception e){ + String content = "包件在 " + warehouseName + "卸车,卸车方式:" + IncomingTypeEnum.getValue(incomingType); + packageTrackLogAsyncService.addPackageTrackLog(AuthUtil.getTenantId(), AuthUtil.getUserId(), Func.firstLong(AuthUtil.getDeptId()), AuthUtil.getNickName(), orderPackageCodes, warehouseId, warehouseName, WorkNodeEnums.UNLOAD_INCOMING_WAREHOUSE.getCode(), content); + } catch (Exception e) { log.warn("#########3卸车存入日志失败"); } @@ -5152,12 +5243,12 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL if (enterNun > num) { log.warn("#############unloadZero: 零担信息卸车数量大于装车件数 enterNun={} num={}", enterNun, num); return R.fail(405, "零担信息卸车数量大于装车件数"); - }else{ + } else { Integer difficute = num - enterNun; DistributionStockArticleEntity stockArticleEntity = distributionStockArticleClient.findStockArticleByOrderCodeAndWarehouseId(orderCode, fromWarehouseId); Long orderId = stockArticleEntity.getId(); - distributionStockArticleClient.addHandQuantity(orderId,difficute); + distributionStockArticleClient.addHandQuantity(orderId, difficute); } carsLoadScanEntity.setUnloadNum(enterNun); diff --git a/blade-service/logpm-warehouse/src/main/resources/application-dev.yml b/blade-service/logpm-warehouse/src/main/resources/application-dev.yml index d0f017ede..8f88cdad8 100644 --- a/blade-service/logpm-warehouse/src/main/resources/application-dev.yml +++ b/blade-service/logpm-warehouse/src/main/resources/application-dev.yml @@ -68,3 +68,14 @@ spring: url: ${blade.datasource.warehouse.slave.url} username: ${blade.datasource.warehouse.slave.username} password: ${blade.datasource.warehouse.slave.password} +xxl: + job: + accessToken: '' + admin: + addresses: http://127.0.0.1:7009/xxl-job-admin + executor: + appname: logpm-factory-xxljob + ip: 127.0.0.1 + logpath: ../data/applogs/logpm-factory-xxljob/jobhandler + logretentiondays: -1 + port: 7018 diff --git a/blade-service/logpm-warehouse/src/main/resources/application-prod.yml b/blade-service/logpm-warehouse/src/main/resources/application-prod.yml index 76e5005e2..71e9f4a80 100644 --- a/blade-service/logpm-warehouse/src/main/resources/application-prod.yml +++ b/blade-service/logpm-warehouse/src/main/resources/application-prod.yml @@ -55,3 +55,14 @@ spring: acknowledge-mode: manual template: mandatory: true +xxl: + job: + accessToken: '' + admin: + addresses: http://172.16.128.147:7009/xxl-job-admin + executor: + appname: logpm-factory-xxljob + ip: 127.0.0.1 + logpath: ../data/applogs/logpm-factory-xxljob/jobhandler + logretentiondays: -1 + port: 7018 diff --git a/blade-service/logpm-warehouse/src/main/resources/application-test.yml b/blade-service/logpm-warehouse/src/main/resources/application-test.yml index 9331c9492..28a10b0df 100644 --- a/blade-service/logpm-warehouse/src/main/resources/application-test.yml +++ b/blade-service/logpm-warehouse/src/main/resources/application-test.yml @@ -55,3 +55,14 @@ spring: acknowledge-mode: manual template: mandatory: true +xxl: + job: + accessToken: '' + admin: + addresses: http://127.0.0.1:7009/xxl-job-admin + executor: + appname: logpm-factory-xxljob + ip: 127.0.0.1 + logpath: ../data/applogs/logpm-factory-xxljob/jobhandler + logretentiondays: -1 + port: 7018 diff --git a/blade-service/logpm-warehouse/src/main/resources/application.yml b/blade-service/logpm-warehouse/src/main/resources/application.yml index 5c4495fc1..70efb75b7 100644 --- a/blade-service/logpm-warehouse/src/main/resources/application.yml +++ b/blade-service/logpm-warehouse/src/main/resources/application.yml @@ -10,23 +10,6 @@ swagger: - org.springblade - com.logpm -#oss配置 -oss: - enabled: true - name: minio - tenant-mode: false - endpoint: http://127.0.0.1:9000 - access-key: D99KGE6ZTQXSATTJWU24 - secret-key: QyVqGnhIQQE734UYSUFlGOZViE6+ZlDEfUG3NjhJ - bucket-name: bladex - -#blade配置 -blade: - #本地文件上传 - file: - remote-mode: true - upload-domain: http://localhost:8999 - remote-path: /usr/share/nginx/html logging: config: classpath:logback.xml @@ -37,15 +20,5 @@ spring: allow-circular-references: true -xxl: - job: - accessToken: '' - admin: - addresses: http://127.0.0.1:7009/xxl-job-admin - executor: - appname: logpm-factory-xxljob - ip: 127.0.0.1 - logpath: ../data/applogs/logpm-factory-xxljob/jobhandler - logretentiondays: -1 - port: 7018 +