From c578b6817b57a971c249e59c23917c79a7c64918 Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Fri, 28 Jun 2024 11:34:50 +0800 Subject: [PATCH] =?UTF-8?q?#=E9=99=90=E5=88=B6=E6=9F=A5=E8=AF=A2=E4=B8=80?= =?UTF-8?q?=E4=B8=AA=E6=9C=88=E5=86=85=E5=B7=A1=E6=A3=80=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hzinfo/inspect/offline/service/impl/InspectOfflineServiceImpl.java | 3 +++ 1 file changed, 3 insertions(+) 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("巡检用户数据不存在!");