From c332c80a23342630019f4ee6a43c9b78d70a8e69 Mon Sep 17 00:00:00 2001 From: H Vs Date: Mon, 14 Oct 2024 18:42:39 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4GetSampleTimeFromLastUpdate?= =?UTF-8?q?=E7=B2=BE=E5=BA=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- HealthMonitor.WebApi/Worker.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/HealthMonitor.WebApi/Worker.cs b/HealthMonitor.WebApi/Worker.cs index 952c4fe..0f74800 100644 --- a/HealthMonitor.WebApi/Worker.cs +++ b/HealthMonitor.WebApi/Worker.cs @@ -2611,10 +2611,10 @@ namespace HealthMonitor.WebApi private DateTime GetSampleTimeFromLastUpdate(DateTime lastUpdate,int interval) { DateTime nowInterval = lastUpdate; - if (nowInterval.Second > 0) - { - nowInterval = nowInterval.AddMinutes(1); - } + //if (nowInterval.Second > 0) + //{ + // nowInterval = nowInterval.AddMinutes(1); + //} // 计算last_update到上一间隔的分钟数 int minutesToSubtract = nowInterval.Minute % interval;