From 6425196115fd9e7f031af2f59535334c532cb63c Mon Sep 17 00:00:00 2001 From: Yared Yemane Date: Wed, 20 Aug 2025 15:56:50 +0300 Subject: [PATCH] report query fixes --- internal/web_server/cron.go | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/internal/web_server/cron.go b/internal/web_server/cron.go index d75fc7d..59a4f13 100644 --- a/internal/web_server/cron.go +++ b/internal/web_server/cron.go @@ -135,10 +135,10 @@ func SetupReportCronJobs(ctx context.Context, reportService *report.Service, out spec string period string }{ - { - spec: "*/60 * * * * *", // Every 5 minutes - period: "5min", - }, + // { + // spec: "*/60 * * * * *", // Every 5 minutes + // period: "5min", + // }, { spec: "0 0 0 * * *", // Daily at midnight period: "daily", @@ -161,9 +161,9 @@ func SetupReportCronJobs(ctx context.Context, reportService *report.Service, out var from, to time.Time switch period { - case "5min": - from = now.Add(-5 * time.Minute) - to = now + // case "5min": + // from = now.Add(-5 * time.Minute) + // to = now case "daily": from = time.Date(now.Year(), now.Month(), now.Day()-1, 0, 0, 0, 0, now.Location()) to = time.Date(now.Year(), now.Month(), now.Day()-1, 23, 59, 59, 0, now.Location())