From cee5e3458475e34555976a62b4eeb37d15b3a14d Mon Sep 17 00:00:00 2001 From: godLei6 <603785348@qq.com> Date: Wed, 16 Oct 2024 14:49:12 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E7=BB=86=E8=8A=82=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../internal/logic/productmanage/productInfoIndexLogic.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/service/dmsvr/internal/logic/productmanage/productInfoIndexLogic.go b/service/dmsvr/internal/logic/productmanage/productInfoIndexLogic.go index 97484d3c..27971963 100644 --- a/service/dmsvr/internal/logic/productmanage/productInfoIndexLogic.go +++ b/service/dmsvr/internal/logic/productmanage/productInfoIndexLogic.go @@ -77,6 +77,9 @@ func (l *ProductInfoIndexLogic) ProductInfoIndex(in *dm.ProductInfoIndexReq) (*d if err != nil { return nil, err } + if pis == nil || len(*pis) == 0 { + return &dm.ProductInfoIndexResp{}, nil + } filter.ProductIDs = append(filter.ProductIDs, *pis...) } size, err = piDB.CountByFilter(l.ctx, filter)