From 7e383f6e5190b36fd7b929a131d9a3c0a0b370f8 Mon Sep 17 00:00:00 2001 From: ziming Date: Wed, 2 Jul 2025 11:00:03 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A2=84=E8=AD=A626?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- internal/data/repoimpl/product.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/data/repoimpl/product.go b/internal/data/repoimpl/product.go index 336d490..5f92646 100644 --- a/internal/data/repoimpl/product.go +++ b/internal/data/repoimpl/product.go @@ -38,8 +38,8 @@ func (r *ProductRepoImpl) FindWarningBudget(ctx context.Context, fun func(ctx co nowTime := time.Now().Format(time.DateTime) result := r.db.DB(ctx). - Where("start_time <= ?", nowTime). - Where("start_time <= ?", nowTime). + Where("start_time < ?", nowTime). + Where("end_time > ?", nowTime). Where("warning_budget > 0"). Where("warning_person IS NOT NULL"). FindInBatches(&results, 5, func(tx *gorm.DB, batch int) error {