finance
黄伟 2 years ago
parent 1722e13510
commit b8f4236e46

@ -186,3 +186,14 @@ func (o *order) SubDetail(ctx context.Context, channelId, orderSn string) (reply
err = xClient.Call(context.WithValue(ctx, share.ReqMetaDataKey, map[string]string{"channelId": channelId}), "SubDetail", orderSn, &reply)
return
}
// Finish @Title 确认收货
func (o *order) Finish(ctx context.Context, channelId, orderSn string) error {
xClient, err := client.GetClient(o)
if err != nil {
return err
}
reply := 0
err = xClient.Call(context.WithValue(ctx, share.ReqMetaDataKey, map[string]string{"channelId": channelId}), "Finish", orderSn, &reply)
return err
}

@ -140,7 +140,9 @@ type ReplyOrderLists struct {
}
type OrderItem struct {
Id uint
OrderSubSn string
SourceOrderSn string
Status uint
CancelStatus uint
OrderFee decimal.Decimal
@ -160,3 +162,46 @@ func (o *order) Lists(ctx context.Context, args ArgsOrderLists) (reply ReplyOrde
err = xClient.Call(ctx, "Lists", args, &reply)
return
}
type ReplyOrderInfo struct {
Id uint
Status uint
CancelStatus uint
OrderSunSu string
SourceOrderSn string
CreatedAt int64
PayAt int64
CloseAt int64
FinishAt int64
OrderFee decimal.Decimal
FreightFee decimal.Decimal
Skus []OrderSkuItem
Customer Customer
ReceiverName string
ReceiverMobile string
Address string
}
type Customer struct {
Name string
Phone string
HopeStockOutAt int64 // 期望发货时间
}
type OrderSkuItem struct {
Img string
Name string
SkuId uint
Price decimal.Decimal
Quantity uint
}
// Info @Title 订单列表
func (o *order) Info(ctx context.Context, orderSubSn uint64) (reply ReplyOrderInfo, err error) {
xClient, err := client.GetClient(o)
if err != nil {
return ReplyOrderInfo{}, err
}
err = xClient.Call(ctx, "Info", orderSubSn, &reply)
return
}

Loading…
Cancel
Save