|
|
|
@ -121,14 +121,19 @@ func (o *order) Close(ctx context.Context, channelId string, orderSn string) (er
|
|
|
|
|
return xClient.Call(context.WithValue(ctx, share.ReqMetaDataKey, map[string]string{"channelId": channelId}), "Close", orderSn, &reply)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type ArgsOrderChannel struct {
|
|
|
|
|
OrderSn string // 订单编号
|
|
|
|
|
Reason string // 取消原因
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Cancel @Title 订单取消
|
|
|
|
|
func (o *order) Cancel(ctx context.Context, channelId string, orderSn string) (err error) {
|
|
|
|
|
func (o *order) Cancel(ctx context.Context, channelId string, args ArgsOrderChannel) (err error) {
|
|
|
|
|
reply := 0
|
|
|
|
|
xClient, err := client.GetClient(o)
|
|
|
|
|
if err != nil {
|
|
|
|
|
return
|
|
|
|
|
}
|
|
|
|
|
return xClient.Call(context.WithValue(ctx, share.ReqMetaDataKey, map[string]string{"channelId": channelId}), "Cancel", orderSn, &reply)
|
|
|
|
|
return xClient.Call(context.WithValue(ctx, share.ReqMetaDataKey, map[string]string{"channelId": channelId}), "Cancel", args, &reply)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type OrderListsSearch struct {
|
|
|
|
|