diff --git a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/offline/service/impl/InspectOfflineServiceImpl.java b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/offline/service/impl/InspectOfflineServiceImpl.java index 378ce44..8fd6d64 100644 --- a/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/offline/service/impl/InspectOfflineServiceImpl.java +++ b/hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/offline/service/impl/InspectOfflineServiceImpl.java @@ -334,9 +334,12 @@ public class InspectOfflineServiceImpl implements IOfflineDataService { List fileJson = new ArrayList<>(); // 查询当天数据(条件) String currentDate = DateUtil.formatDateTime(DateUtil.now()); + Calendar calendar = Calendar.getInstance(); + calendar.add(Calendar.MONTH,-1); // 巡检任务ID集合 List taskUsers = this.taskUserService.list(new LambdaQueryWrapper() {{ eq(TaskUserEntity::getUserId, user.getUserId()); + ge(TaskUserEntity::getCreateTime, DateUtil.format(calendar.getTime(),DateUtil.PATTERN_DATE)); }}); if(CollectionUtil.isEmpty(taskUsers)){ throw new ServiceException("巡检用户数据不存在!");