From 12d094a193e190bedb1fcf35ac024eaec3c77e9f Mon Sep 17 00:00:00 2001 From: zhaoqingang <zhaoqg0118@163.com> Date: 星期三, 19 二月 2025 12:03:45 +0800 Subject: [PATCH] merge --- models/accessRegularity.go | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/models/accessRegularity.go b/models/accessRegularity.go index 70e23d8..dfb3986 100644 --- a/models/accessRegularity.go +++ b/models/accessRegularity.go @@ -208,7 +208,7 @@ if !isCrossDay { // 鍒ゆ柇鏃堕棿鑼冨洿锛屽苟褰掑睘鍒版煇涓�澶� - if hour >= startHour && hour <= endHour { + if hour >= startHour && hour < endHour { key = t.Format("2006-01-02") } else { continue // 涓嶅湪缁熻鑼冨洿鍐� @@ -217,7 +217,7 @@ // 鍒ゆ柇鏃堕棿鑼冨洿锛屽苟褰掑睘鍒版煇涓�澶� if hour >= startHour { // 21:00-23:59 褰掑睘褰撳ぉ key = t.Format("2006-01-02") - } else if hour <= endHour { // 00:00-02:59 褰掑睘鍓嶄竴澶� + } else if hour < endHour { // 00:00-02:59 褰掑睘鍓嶄竴澶� key = t.AddDate(0, 0, -1).Format("2006-01-02") } else { continue // 涓嶅湪缁熻鑼冨洿鍐� -- Gitblit v1.8.0