|
|
@ -92,20 +92,62 @@ func (a *afterService) Receipt(ctx context.Context, args ArgsAfterServiceReceipt
|
|
|
|
return
|
|
|
|
return
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
type ArgsAfterServiceReject struct {
|
|
|
|
type ArgsAfterServiceClose struct {
|
|
|
|
|
|
|
|
Source source `json:"source"`
|
|
|
|
SourceAfsSn string `json:"sourceAfsSn"`
|
|
|
|
SourceAfsSn string `json:"sourceAfsSn"`
|
|
|
|
SourceSkuId string `json:"sourceSkuId"`
|
|
|
|
SourceSkuId string `json:"sourceSkuId"`
|
|
|
|
SourceOrderSN string `json:"sourceOrderSN"`
|
|
|
|
SourceOrderSn string `json:"sourceOrderSn"`
|
|
|
|
|
|
|
|
Result string `json:"result"`
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Close @Title 关闭售后单
|
|
|
|
|
|
|
|
func (a *afterService) Close(ctx context.Context, args ArgsAfterServiceClose) (err error) {
|
|
|
|
|
|
|
|
xClient, err := client.GetClient(a)
|
|
|
|
|
|
|
|
if err != nil {
|
|
|
|
|
|
|
|
return err
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
reply := 0
|
|
|
|
|
|
|
|
err = xClient.Call(ctx, "Close", args, &reply)
|
|
|
|
|
|
|
|
return
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
type ArgsAfterServiceRefund struct {
|
|
|
|
|
|
|
|
Source source `json:"source"`
|
|
|
|
|
|
|
|
SourceAfsSn string `json:"sourceAfsSn"`
|
|
|
|
|
|
|
|
SourceSkuId string `json:"sourceSkuId"`
|
|
|
|
|
|
|
|
SourceOrderSn string `json:"sourceOrderSn"`
|
|
|
|
|
|
|
|
Result string `json:"result"`
|
|
|
|
|
|
|
|
RefundFee decimal.Decimal `json:"refundFee"`
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Refund @Title 退款
|
|
|
|
|
|
|
|
func (a *afterService) Refund(ctx context.Context, args ArgsAfterServiceClose) (err error) {
|
|
|
|
|
|
|
|
xClient, err := client.GetClient(a)
|
|
|
|
|
|
|
|
if err != nil {
|
|
|
|
|
|
|
|
return err
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
reply := 0
|
|
|
|
|
|
|
|
err = xClient.Call(ctx, "Refund", args, &reply)
|
|
|
|
|
|
|
|
return
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
type ArgsAfterServiceNewOrder struct {
|
|
|
|
|
|
|
|
Source source `json:"source"`
|
|
|
|
|
|
|
|
SourceAfsSn string `json:"sourceAfsSn"`
|
|
|
|
|
|
|
|
SourceSkuId string `json:"sourceSkuId"`
|
|
|
|
|
|
|
|
SourceOrderSn string `json:"sourceOrderSn"`
|
|
|
|
|
|
|
|
Result string `json:"result"`
|
|
|
|
|
|
|
|
NewSourceOrderSn decimal.Decimal `json:"newSourceOrderSn"`
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Reject @Title 驳回
|
|
|
|
// NewOrder @Title 新订单
|
|
|
|
func (a *afterService) Reject(ctx context.Context, args ArgsAfterServiceReject) (err error) {
|
|
|
|
func (a *afterService) NewOrder(ctx context.Context, args ArgsAfterServiceNewOrder) (err error) {
|
|
|
|
xClient, err := client.GetClient(a)
|
|
|
|
xClient, err := client.GetClient(a)
|
|
|
|
if err != nil {
|
|
|
|
if err != nil {
|
|
|
|
return err
|
|
|
|
return err
|
|
|
|
}
|
|
|
|
}
|
|
|
|
reply := 0
|
|
|
|
reply := 0
|
|
|
|
err = xClient.Call(ctx, "Reject", args, &reply)
|
|
|
|
err = xClient.Call(ctx, "NewOrder", args, &reply)
|
|
|
|
return
|
|
|
|
return
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|