diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml index 14c789aac..40ba26b80 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml @@ -392,10 +392,11 @@ ldrp.reservation_id = lds.reservation_id ) goodsAllocation, ldrs.stock_article_status stockArticleState, - ( select sum(loaded_nub) FROM + ( select IFNULL(sum( loaded_nub ) ,0) FROM logpm_distribution_loadscan AS ldl WHERE ldl.order_id=ldrs.stock_article_id and ldl.scan_status != 1 + AND ldl.is_deleted = 0 and ldl.reservation_id = lds.reservation_id ) AS loadingNumber, ( select count(*) FROM 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 b67e3494b..ee55cbc4e 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 @@ -1148,6 +1148,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl parcelListEntityList = distributionParcelListClient.findEntityListByOrderCode(orderCode, fromWarehouseId); List ls = new ArrayList<>(); for (DistributionParcelListEntity parcelListEntity : parcelListEntityList) { @@ -1160,6 +1161,9 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl queryWrapper1 = new QueryWrapper<>(); + queryWrapper1.eq("waybill_no",stockArticleEntity.getWaybillNumber()) + .eq("order_code",stockArticleEntity.getWaybillNumber()); + TrunklineWaybillOrderEntity one = trunklineWaybillOrderService.getOne(queryWrapper1); + if(!Objects.isNull(one)){ + WarehouseWaybillEntity waybillEntity = warehouseWaybillClient.findByWaybillNo(stockArticleEntity.getWaybillNumber()); + Integer totalCount = waybillEntity.getTotalCount(); + Integer waybillStatusInt = Integer.parseInt(waybillEntity.getWaybillStatus()); + if(waybillStatusInt <= 30){ + Integer handleNumber = one.getHandleNumber(); + int total = handleNumber + unloadNum; + if(total < totalCount){ + waybillEntity.setWaybillStatus("50"); + one.setHandleNumber(total); + }else{ + waybillEntity.setWaybillStatus("60"); + one.setHandleNumber(totalCount); + } + warehouseWaybillClient.updateEntity(waybillEntity); + trunklineWaybillOrderService.updateById(one); + } + } + } } } else { Integer hQuantity = newStockArticleEntity.getHandQuantity() + unloadNum; @@ -1202,6 +1231,33 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl queryWrapper1 = new QueryWrapper<>(); + queryWrapper1.eq("waybill_no",stockArticleEntity.getWaybillNumber()) + .eq("order_code",stockArticleEntity.getWaybillNumber()); + TrunklineWaybillOrderEntity one = trunklineWaybillOrderService.getOne(queryWrapper1); + if(!Objects.isNull(one)){ + Integer totalCount = warehouseWaybillEntity.getTotalCount(); + Integer waybillStatusInt = Integer.parseInt(warehouseWaybillEntity.getWaybillStatus()); + if(waybillStatusInt <= 30){ + Integer handleNumber = one.getHandleNumber(); + int total = handleNumber + unloadNum; + if(total < totalCount){ + warehouseWaybillEntity.setWaybillStatus("50"); + one.setHandleNumber(total); + }else{ + warehouseWaybillEntity.setWaybillStatus("60"); + one.setHandleNumber(totalCount); + } + warehouseWaybillClient.updateEntity(warehouseWaybillEntity); + trunklineWaybillOrderService.updateById(one); + } + } + } + } } } @@ -2908,6 +2964,30 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl queryWrapper1 = new QueryWrapper<>(); + queryWrapper1.eq("waybill_id",waybillId) + .eq("order_code",waybillNo); + TrunklineWaybillOrderEntity one = trunklineWaybillOrderService.getOne(queryWrapper1); + if(!Objects.isNull(one)){ + Integer totalCount = waybillEntity.getTotalCount(); + Integer waybillStatusInt = Integer.parseInt(waybillEntity.getWaybillStatus()); + if(waybillStatusInt <= 30){ + Integer handleNumber = one.getHandleNumber(); + int total = handleNumber + enterNum; + if(total < totalCount){ + waybillEntity.setWaybillStatus("30"); + one.setHandleNumber(total); + }else{ + waybillEntity.setWaybillStatus("40"); + one.setHandleNumber(totalCount); + } + warehouseWaybillClient.updateEntity(waybillEntity); + trunklineWaybillOrderService.updateById(one); + } + } + trunklineCarsLoadingLogService.savaLoadingLog(warehouseId, warehouseName, loadId, loadCode, waybillId, waybillNo, orderCode, goodsName, difficult, 2, isData, isAbnormal, trayId, trayCode, trayName, fromWarehouseId, loadScanId, remark); diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.xml b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.xml index 073c0cd4e..a05695860 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.xml +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.xml @@ -245,15 +245,15 @@ and warehouse_id =#{param.warehouseId } and allocation_id =#{param.allocationId } and tray_id =#{param.trayId } - and order_code like concat('%',#{param.orderCode },'%') - and category_name like concat('%',#{param.categoryName },'%') - and material_code like concat('%',#{param.materialCode },'%') - and tray_code like concat('%',#{param.trayCode },'%') - and tray_name like concat('%',#{param.trayName },'%') - and brand_name like concat('%',#{param.brandName },'%') + and order_code like concat(#{param.orderCode },'%') + and category_name like concat(#{param.categoryName },'%') + and material_code like concat(#{param.materialCode },'%') + and tray_code like concat(#{param.trayCode },'%') + and tray_name like concat(#{param.trayName },'%') + and brand_name like concat(#{param.brandName },'%') and market_name like concat('%',#{param.marketName},'%') and material_name like concat('%',#{param.materialName},'%') - and position_code like concat('%',#{param.positionCode},'%') + and (position_code like concat('%',#{param.positionCode},'%') or grounding_position_code like concat('%',#{param.positionCode},'%')) and order_package_code =#{param.orderPackageCode } and inventory_user like concat('%',#{param.inventoryUser },'%') and inventory_time BETWEEN #{param.startTime } and #{param.endTime} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java index e683751f0..f07e674b0 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java @@ -263,16 +263,16 @@ public class TaskQuestServiceImpl extends BaseServiceImpl>>>>>>>>>> 警告 错误的包件数据类型 ,{}",i); + } else { + log.warn(">>>>>>>>>>> 警告 错误的包件数据类型 ,{}", i); return null; } @@ -312,13 +312,13 @@ public class TaskQuestServiceImpl extends BaseServiceImpl { QuestDetailVO questDetailVO = new QuestDetailVO(); BeanUtil.copyProperties(i, questDetailVO); + + + if (StringUtil.isNotBlank(questDetailVO.getGroundingPositionCode())) { + questDetailVO.setPositionCode(questDetailVO.getGroundingPositionCode()); + } if (!i.getQuestStatus().equals(0)) { R> listR = userSearchClient.listByUser(String.valueOf(i.getUpdateUser())); if (ObjectUtils.isNotNull(listR.getData())) { @@ -2988,11 +2993,11 @@ public class TaskQuestServiceImpl extends BaseServiceImpl extracted(Long questId, QuestDetailEntity questDetail) { - List taskQuestChildVOS = bladeRedis.get(RedisKeyConstant.TASK_QUEST_CHILD_KEY+questId); + List taskQuestChildVOS = bladeRedis.get(RedisKeyConstant.TASK_QUEST_CHILD_KEY + questId); if (taskQuestChildVOS == null) { taskQuestChildVOS = taskQuestChildService.selectlistByMasterId(questId); - if(taskQuestChildVOS!=null){ - bladeRedis.setEx(RedisKeyConstant.TASK_QUEST_CHILD_KEY+questId, taskQuestChildVOS, 1000L); + if (taskQuestChildVOS != null) { + bladeRedis.setEx(RedisKeyConstant.TASK_QUEST_CHILD_KEY + questId, taskQuestChildVOS, 1000L); } }