From 8f3ca4b1996850343c88d72cfa7d9d08686989ac Mon Sep 17 00:00:00 2001 From: ziming Date: Wed, 18 Jun 2025 10:47:33 +0800 Subject: [PATCH] =?UTF-8?q?=E8=84=9A=E6=9C=AC=E5=A2=9E=E5=8A=A0=E6=89=B9?= =?UTF-8?q?=E6=AC=A1=E5=8F=B7=E6=9F=A5=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- internal/biz/do/rds_mq.go | 2 ++ internal/data/repoimpl/order.go | 3 +++ 2 files changed, 5 insertions(+) diff --git a/internal/biz/do/rds_mq.go b/internal/biz/do/rds_mq.go index 6efb705..6daf51e 100644 --- a/internal/biz/do/rds_mq.go +++ b/internal/biz/do/rds_mq.go @@ -2,6 +2,7 @@ package do type WechatQuery struct { ProductNo string `json:"product_no"` + BatchNo string `json:"batch_no"` StartTime string `json:"start_time"` EndTime string `json:"end_time"` OrderNo string `json:"order_no"` @@ -9,6 +10,7 @@ type WechatQuery struct { type RdsWechatQuery struct { ProductNo string `json:"product_no"` + BatchNo string `json:"batch_no"` StartTime string `json:"start_time"` EndTime string `json:"end_time"` GoNum int `json:"go_num"` // 并发数 diff --git a/internal/data/repoimpl/order.go b/internal/data/repoimpl/order.go index ea74f08..ff2badd 100644 --- a/internal/data/repoimpl/order.go +++ b/internal/data/repoimpl/order.go @@ -38,6 +38,9 @@ func (p *OrderRepoImpl) FinSucByStockIdInBatches(ctx context.Context, req *do.We if req.ProductNo != "" { tx = tx.Where("product_no = ?", req.ProductNo) } + if req.BatchNo != "" { + tx = tx.Where("batch_no = ?", req.BatchNo) + } if req.StartTime != "" { tx = tx.Where("receive_success_time > ?", req.StartTime) }