添加入库接口

finance
杨赟 2 years ago
parent 138a9c44ac
commit 07e4350f78

@ -14,6 +14,9 @@ const (
SkuHandleNone = 1 // 未处理
SkuHandleStart = 2 // 开始处理
SkuJdStatusUp = 1 // 京东上架
SkuJdStatusDown = 2 // 京东下架
)
type sku struct {
@ -131,8 +134,15 @@ func (s *sku) Discard(ctx context.Context, skuIds []uint) error {
return client.GetClient(s).Call(ctx, "Discard", skuIds, &reply)
}
type AdoptItem struct {
Id uint `json:"id"`
JdSkuId uint64 `json:"jdSkuId"`
Name string `json:"name"`
Error string `json:"error"`
}
// Adopt @Title 入库
func (s *sku) Adopt(ctx context.Context, skuIds []uint) error {
reply := 0
return client.GetClient(s).Call(ctx, "Adopt", skuIds, &reply)
func (s *sku) Adopt(ctx context.Context, skuIds []uint) (reply AdoptItem, err error) {
err = client.GetClient(s).Call(ctx, "Adopt", skuIds, &reply)
return
}

Loading…
Cancel
Save