From 8f59a637b1a541a17c9d6d7e667489eca212a4b7 Mon Sep 17 00:00:00 2001 From: pengwei Date: Mon, 27 Oct 2025 10:30:30 +0800 Subject: [PATCH] =?UTF-8?q?fiex:=E6=89=A7=E6=B3=95=E5=8A=9E=E6=A1=88?= =?UTF-8?q?=E5=AE=9A=E6=97=B6=E4=BB=BB=E5=8A=A1=E6=97=B6=E9=97=B4=E8=8C=83?= =?UTF-8?q?=E5=9B=B4=E8=B0=83=E6=95=B4=EF=BC=8C=E5=AE=A1=E8=AE=A1=E7=9B=91?= =?UTF-8?q?=E7=9D=A3=E6=8E=92=E5=BA=8F=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/biutag/supervision/job/Job.java | 13 ++++++++----- .../biutag/supervision/mapper/NegativeMapper.java | 2 +- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/src/main/java/com/biutag/supervision/job/Job.java b/src/main/java/com/biutag/supervision/job/Job.java index 93ca6e5..bee125a 100644 --- a/src/main/java/com/biutag/supervision/job/Job.java +++ b/src/main/java/com/biutag/supervision/job/Job.java @@ -62,18 +62,21 @@ public class Job { } // 每日04:00更新基础数据 - @Scheduled(cron = "0 0 23 * * ?") + @Scheduled(cron = "0 0 4 * * ?") public void updateBaseData() { // 0秒 log.info("获取数据-------updateBaseData-----------"); - //LocalDateTime.now().minusDays(1).withHour(0).withMinute(0).withSecond(0).withNano(0).atZone(ZoneId.systemDefault()).toInstant() - //LocalDateTime.now().minusDays(1).withHour(23).withMinute(59).withSecond(59).atZone(ZoneId.systemDefault()).toInstant() + + LocalDateTime firstDay = LocalDate.now() .withDayOfYear(1) .atStartOfDay(); List happenTime = new ArrayList<>(); - Date start = Date.from(firstDay.atZone(ZoneId.systemDefault()).toInstant()); - Date end = Date.from(LocalDateTime.now().atZone(ZoneId.systemDefault()).toInstant()); +// Date start = Date.from(firstDay.atZone(ZoneId.systemDefault()).toInstant()); +// Date end = Date.from(LocalDateTime.now().atZone(ZoneId.systemDefault()).toInstant()); + Date start = Date.from(LocalDateTime.now().minusDays(1).withHour(0).withMinute(0).withSecond(0).withNano(0).atZone(ZoneId.systemDefault()).toInstant()); + Date end = Date.from(LocalDateTime.now().minusDays(1).withHour(23).withMinute(59).withSecond(59).atZone(ZoneId.systemDefault()).toInstant()); + happenTime.add(start); happenTime.add(end); businessDepartService.generate(happenTime); diff --git a/src/main/java/com/biutag/supervision/mapper/NegativeMapper.java b/src/main/java/com/biutag/supervision/mapper/NegativeMapper.java index 1ffa56e..9ab5637 100644 --- a/src/main/java/com/biutag/supervision/mapper/NegativeMapper.java +++ b/src/main/java/com/biutag/supervision/mapper/NegativeMapper.java @@ -249,7 +249,7 @@ public interface NegativeMapper extends BaseMapper { "LEFT JOIN negative_blame nb ON ng.id=nb.negativeId " + "WHERE sd.statistics_group_id=3 " + "GROUP BY sd.short_name " + - "ORDER BY totalPro DESC;") + "ORDER BY completedRate DESC;") List getSupervisionMapIconInfo(Date beginTime, Date endTime);