diff --git a/blade-service/logpm-factory/src/main/java/com/logpm/factory/mt/service/impl/MtFactoryDataServiceImpl.java b/blade-service/logpm-factory/src/main/java/com/logpm/factory/mt/service/impl/MtFactoryDataServiceImpl.java index 748016f19..5f1e2ba67 100644 --- a/blade-service/logpm-factory/src/main/java/com/logpm/factory/mt/service/impl/MtFactoryDataServiceImpl.java +++ b/blade-service/logpm-factory/src/main/java/com/logpm/factory/mt/service/impl/MtFactoryDataServiceImpl.java @@ -49,8 +49,7 @@ public class MtFactoryDataServiceImpl implements IMtFactoryDataService { private final IMtFactoryOrderService mtFactoryOrderService; private final IMtPackageInfoService mtPackageInfoService; - private final IAdvanceDetailClient advanceDetailClient; - private final IWarehouseClient warehouseClient; + private final BladeRedis bladeRedis; @@ -124,7 +123,7 @@ public class MtFactoryDataServiceImpl implements IMtFactoryDataService { } } //判断是否有新的包件 - if (packageInfos.size() == 0) { + if (packageInfos.isEmpty()) { //如果没有新增包件就直接下一条数据 log.info("##################dealWithData: 没有新增包件,所以当前数据不保存 invoiceOrderCode={}", invoiceOrderCode); continue; diff --git a/blade-service/logpm-factory/src/main/java/com/logpm/factory/oupai/service/impl/OuPaiFactoryServiceImpl.java b/blade-service/logpm-factory/src/main/java/com/logpm/factory/oupai/service/impl/OuPaiFactoryServiceImpl.java index 8e0490e1a..da4713187 100644 --- a/blade-service/logpm-factory/src/main/java/com/logpm/factory/oupai/service/impl/OuPaiFactoryServiceImpl.java +++ b/blade-service/logpm-factory/src/main/java/com/logpm/factory/oupai/service/impl/OuPaiFactoryServiceImpl.java @@ -101,6 +101,10 @@ public class OuPaiFactoryServiceImpl implements IOuPaiFactoryService { QueryWrapper queryWrapper = new QueryWrapper<>(); queryWrapper.eq("oid",orderPackageCode); FactoryPackageEntity packageEntity = factoryPackageService.getOne(queryWrapper); + if(Objects.isNull(packageEntity)) { + log.error("############oid 查询数据失败: {}",orderPackageCode); + return orderPackageCode; + } packageEntity.setPackageStatus(5); factoryPackageService.updateById(packageEntity);