From 0ad499b45748b6639e2a8f494fca3dbeb1589637 Mon Sep 17 00:00:00 2001 From: sian Date: Thu, 20 Oct 2022 11:37:02 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- supplier/goods.go | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/supplier/goods.go b/supplier/goods.go index b5628d6..454836d 100644 --- a/supplier/goods.go +++ b/supplier/goods.go @@ -10,10 +10,13 @@ import ( type goods struct { } type GoodsSearch struct { - Name string // 商品名称 - CategoryId uint64 // 类目id - BrandName string // 品牌名 - Handle uint // 处理状态 1=待处理 2=入库 3=废弃 + Name string // 商品名称 + CategoryId uint64 // 类目id + BrandName string // 品牌名 + Handle uint // 处理状态 1=待处理 2=入库 3=废弃 + SkuId uint // 供应商skuId + MinSupplyPrice decimal.Decimal // 最小采购价 + MaxSupplyPrice decimal.Decimal // 最大采购价 } type ArgsGoodsList struct { Search GoodsSearch From 2b6ac8e200b000f98614591f85213cdc50b70a86 Mon Sep 17 00:00:00 2001 From: sian Date: Thu, 20 Oct 2022 15:26:16 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- supplier/goods.go | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/supplier/goods.go b/supplier/goods.go index 454836d..e6b7702 100644 --- a/supplier/goods.go +++ b/supplier/goods.go @@ -171,3 +171,18 @@ func (g *goods) ReHandle(ctx context.Context, goodsIds []uint) (reply []AdoptIte err = xClient.Call(ctx, "ReHandle", goodsIds, &reply) return } + +type ReplyByIdItem struct { + GoodsId uint `json:"goodsId"` + SourceName string `json:"sourceName"` +} + +// FindByIds @Title 根据商品Ids获取商品信息 +func (g *goods) FindByIds(ctx context.Context, goodsIds []uint) (reply []AdoptItem, err error) { + xClient, err := client.GetClient(g) + if err != nil { + return nil, err + } + err = xClient.Call(ctx, "FindByIds", goodsIds, &reply) + return +}