feat(shipment): 添加同步商品功能
- 新增 ArgsSaleProductSync 结构体用于同步商品请求参数 - 在 saleProduct 服务中实现 Sync 方法,用于同步商品数据 - 通过 RPC 调用远程服务的 Sync 方法来实现商品同步
This commit is contained in:
parent
76284f0550
commit
08ba9559a9
@ -247,3 +247,18 @@ func (s *saleProduct) Delete(ctx context.Context, args ArgsSaleProductDelete) (e
|
||||
reply := 0
|
||||
return xClient.Call(ctx, "Delete", args, &reply)
|
||||
}
|
||||
|
||||
type ArgsSaleProductSync struct {
|
||||
ModifyId int64 // 订舱修改单id
|
||||
ShipmentSaleProductIds []int64 // 出运产品id
|
||||
}
|
||||
|
||||
// Sync @TITLE 同步商品
|
||||
func (s *saleProduct) Sync(ctx context.Context, args ArgsSaleProductSync) (err error) {
|
||||
xClient, err := client.GetClient(s)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
reply := 0
|
||||
return xClient.Call(ctx, "Sync", args, &reply)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user