xiongchao 3 vuotta sitten
vanhempi
commit
c5a0a185f4

+ 8 - 0
platform-service/src/main/java/com/platform/service/check/impl/CheckJobServiceImpl.java

@@ -354,7 +354,15 @@ public class CheckJobServiceImpl extends BaseServiceImpl<CheckJobMapper, CheckJo
                 if(!find){
                     CheckJob checkJob = new CheckJob();
                     checkJob.setSbId(standard.getSbId());
+
+                    // 有可能设备已经删除了,继续执行其他的
+                    if(StringUtils.isBlank(standard.getSbId())){
+                        continue;
+                    }
                     SbInfo sbInfo = sbInfoService.getModelById(standard.getSbId());
+                    if(sbInfo == null){
+                        continue;
+                    }
                     if(standard.getCheckUserType() == null){
                         if(standard.getPeriodType()< CheckPlanPeriodTypeEnum.WEEK.getValue()){
                             checkJob.setCheckUserId(sbInfo.getSaveUser());