-
Notifications
You must be signed in to change notification settings - Fork 9
/
OrderSuccessRequest.go
121 lines (116 loc) · 4.54 KB
/
OrderSuccessRequest.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
package wdk
import (
"sync"
)
// OrderSuccessRequest 结构体
type OrderSuccessRequest struct {
// 子单列表
SubInfoList []OrderDeliveryBO `json:"sub_info_list,omitempty" xml:"sub_info_list>order_delivery_bo,omitempty"`
// 外部订单号
OutOrderId string `json:"out_order_id,omitempty" xml:"out_order_id,omitempty"`
// 订单来源
OrderSource string `json:"order_source,omitempty" xml:"order_source,omitempty"`
// 下单终端
OrderTerminal string `json:"order_terminal,omitempty" xml:"order_terminal,omitempty"`
// 一级渠道
FirstChannel string `json:"first_channel,omitempty" xml:"first_channel,omitempty"`
// 二级渠道
SecondChannel string `json:"second_channel,omitempty" xml:"second_channel,omitempty"`
// 渠道店
ShopId string `json:"shop_id,omitempty" xml:"shop_id,omitempty"`
// 经营店id
StoreId string `json:"store_id,omitempty" xml:"store_id,omitempty"`
// 创单时间
OrderCreateTime string `json:"order_create_time,omitempty" xml:"order_create_time,omitempty"`
// 支付时间
PayTime string `json:"pay_time,omitempty" xml:"pay_time,omitempty"`
// 期望送达时间
ExpectArriveTime string `json:"expect_arrive_time,omitempty" xml:"expect_arrive_time,omitempty"`
// 订单支付信息
PayInfos string `json:"pay_infos,omitempty" xml:"pay_infos,omitempty"`
// 卖家昵称
SellerNick string `json:"seller_nick,omitempty" xml:"seller_nick,omitempty"`
// 是否是主单 1-是;0-不是
IsMain int64 `json:"is_main,omitempty" xml:"is_main,omitempty"`
// 是否是子单 1-是;0-不是
IsDetail int64 `json:"is_detail,omitempty" xml:"is_detail,omitempty"`
// 业务类型 2-表示生鲜门店;3-表示B2C
BusinessType int64 `json:"business_type,omitempty" xml:"business_type,omitempty"`
// 子业务类型
SubBusinessType int64 `json:"sub_business_type,omitempty" xml:"sub_business_type,omitempty"`
// 订单渠道 2-表示线上;3-表示线下
OrderChannel int64 `json:"order_channel,omitempty" xml:"order_channel,omitempty"`
// 配送类型 1-表示预约配送;2-表示现场购买
DeliverType int64 `json:"deliver_type,omitempty" xml:"deliver_type,omitempty"`
// 送达类型 1-表示及时达;2-表示定时达;3-表示极速达;4-表示无需配送
ArriveType int64 `json:"arrive_type,omitempty" xml:"arrive_type,omitempty"`
// 订单状态
OrderStatus int64 `json:"order_status,omitempty" xml:"order_status,omitempty"`
// 订单原价(分为单位)
OriginFee int64 `json:"origin_fee,omitempty" xml:"origin_fee,omitempty"`
// 支付金额(分为单位)
PayFee int64 `json:"pay_fee,omitempty" xml:"pay_fee,omitempty"`
// 优惠金额(分为单位)
DiscountFee int64 `json:"discount_fee,omitempty" xml:"discount_fee,omitempty"`
// 运费(分为单位)
PostFee int64 `json:"post_fee,omitempty" xml:"post_fee,omitempty"`
// 打包费(分为单位)
PackageFee int64 `json:"package_fee,omitempty" xml:"package_fee,omitempty"`
// 平台折扣费(分为单位)
PlatformDiscountFee int64 `json:"platform_discount_fee,omitempty" xml:"platform_discount_fee,omitempty"`
// 商家折扣费(分为单位)
MerchantDiscountFee int64 `json:"merchant_discount_fee,omitempty" xml:"merchant_discount_fee,omitempty"`
// 买家信息
BuyerInfo *OrderPayInfoBO `json:"buyer_info,omitempty" xml:"buyer_info,omitempty"`
// 订单配送信息
DeliveryInfo *OrderBuyerInfoBO `json:"delivery_info,omitempty" xml:"delivery_info,omitempty"`
// 卖家id
SellerId int64 `json:"seller_id,omitempty" xml:"seller_id,omitempty"`
// 订单来源
OrderFrom int64 `json:"order_from,omitempty" xml:"order_from,omitempty"`
}
var poolOrderSuccessRequest = sync.Pool{
New: func() any {
return new(OrderSuccessRequest)
},
}
// GetOrderSuccessRequest() 从对象池中获取OrderSuccessRequest
func GetOrderSuccessRequest() *OrderSuccessRequest {
return poolOrderSuccessRequest.Get().(*OrderSuccessRequest)
}
// ReleaseOrderSuccessRequest 释放OrderSuccessRequest
func ReleaseOrderSuccessRequest(v *OrderSuccessRequest) {
v.SubInfoList = v.SubInfoList[:0]
v.OutOrderId = ""
v.OrderSource = ""
v.OrderTerminal = ""
v.FirstChannel = ""
v.SecondChannel = ""
v.ShopId = ""
v.StoreId = ""
v.OrderCreateTime = ""
v.PayTime = ""
v.ExpectArriveTime = ""
v.PayInfos = ""
v.SellerNick = ""
v.IsMain = 0
v.IsDetail = 0
v.BusinessType = 0
v.SubBusinessType = 0
v.OrderChannel = 0
v.DeliverType = 0
v.ArriveType = 0
v.OrderStatus = 0
v.OriginFee = 0
v.PayFee = 0
v.DiscountFee = 0
v.PostFee = 0
v.PackageFee = 0
v.PlatformDiscountFee = 0
v.MerchantDiscountFee = 0
v.BuyerInfo = nil
v.DeliveryInfo = nil
v.SellerId = 0
v.OrderFrom = 0
poolOrderSuccessRequest.Put(v)
}