From bfda75bb84bd3cccbac784a927866b2fe7f54e03 Mon Sep 17 00:00:00 2001 From: huangjiajun <582604932@qq.com> Date: Thu, 4 Jul 2024 22:40:39 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/db/db_order_goods_make_stock.go | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/app/db/db_order_goods_make_stock.go b/app/db/db_order_goods_make_stock.go index 607ecb4..41d4887 100644 --- a/app/db/db_order_goods_make_stock.go +++ b/app/db/db_order_goods_make_stock.go @@ -18,7 +18,13 @@ func GetOrderGoodsMakeStockByIpad(eg *xorm.Engine, param map[string]string) (*[] sess.And("wait_baking_num >0") } if param["state"] == "3" { - sess.And("wait_sorting_num >0") + var goods []model.OrderGoods + eg.Where("goods_type=0 and state=1").Find(&goods) + ids := []int64{-1} + for _, v := range goods { + ids = append(ids, v.SkuId) + } + sess.And("wait_sorting_num >0").In("sku_id", ids) } if param["keyword"] != "" { sess.And("goods_title like ?", "%"+param["keyword"]+"%")