jichaobo пре 2 година
родитељ
комит
2856df845b

+ 3 - 3
service-fire/service-fire-biz/src/main/java/com/usky/fire/service/impl/PatrolInspectionPlanSonServiceImpl.java

@@ -189,17 +189,17 @@ public class PatrolInspectionPlanSonServiceImpl extends AbstractCrudService<Patr
             throw new BusinessException("无效地点,请联系管理人员添加点位");
         }
         List<PatrolInspectionRecordPicture> recordPictureList = new ArrayList<>();
-        List<PatrolInspectionRecord> recordList = new ArrayList<>();
         if (planSonId != null && planSonId != 0) {
             LambdaQueryWrapper<PatrolInspectionRecord> query = Wrappers.lambdaQuery();
             query.eq(PatrolInspectionRecord::getSiteId, siteId)
                     .eq(PatrolInspectionRecord::getPlanSonId, planSonId);
-            recordList = patrolInspectionRecordMapper.selectList(query);
+            List<PatrolInspectionRecord> recordList = patrolInspectionRecordMapper.selectList(query);
+            siteList.get(0).setRemarks(recordList.get(0).getRemarks());
             LambdaQueryWrapper<PatrolInspectionRecordPicture> queryOne = Wrappers.lambdaQuery();
             queryOne.eq(PatrolInspectionRecordPicture::getRecordId, recordList.get(0).getId());
             recordPictureList = patrolInspectionRecordPictureService.list(queryOne);
         }
-        siteList.get(0).setRemarks(recordList.get(0).getRemarks());
+
         siteList.get(0).setRecordPictureList(recordPictureList);
         List<PatrolInspectionContentVo> contentList = this.contentList(siteList.get(0).getId());
         siteList.get(0).setContentCount(contentList.size());