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 4770ad406..9035047be 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 @@ -4849,13 +4849,13 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl distrilbutionBillPackageEntities = distrilbutionBillPackageMapper.selectList(distrilbutionBillStockEntityLambdaQueryWrapper); - Set ids = new HashSet(); - for (DistrilbutionBillPackageEntity distrilbutionBillPackageEntity : distrilbutionBillPackageEntities) { - ids.add(distrilbutionBillPackageEntity.getParceListId()); - } // 得到所以的订单列表 - List distributionParcelListEntities = distributionParcelListMapper.selectBatchIds(ids); + List distributionParcelListEntities = null; + if (!distrilbutionBillPackageEntities.isEmpty()) { + List ids = distrilbutionBillPackageEntities.stream().map(DistrilbutionBillPackageEntity::getParceListId).collect(Collectors.toList()); + distributionParcelListEntities = distributionParcelListMapper.selectBatchIds(ids); + } Map map = new HashMap<>(); map.put("自提单号", distrilbutionBillLadingEntity.getPickupBatch()); @@ -4864,7 +4864,9 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl