-
-
Notifications
You must be signed in to change notification settings - Fork 9.1k
Expand file tree
/
Copy pathWxChannelOrderService.java
More file actions
326 lines (294 loc) · 9.22 KB
/
WxChannelOrderService.java
File metadata and controls
326 lines (294 loc) · 9.22 KB
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
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
package me.chanjar.weixin.channel.api;
import java.util.List;
import me.chanjar.weixin.channel.bean.base.AddressInfo;
import me.chanjar.weixin.channel.bean.base.WxChannelBaseResponse;
import me.chanjar.weixin.channel.bean.delivery.PackageAuditInfo;
import me.chanjar.weixin.channel.bean.delivery.DeliveryCompanyResponse;
import me.chanjar.weixin.channel.bean.delivery.DeliveryInfo;
import me.chanjar.weixin.channel.bean.order.ChangeOrderInfo;
import me.chanjar.weixin.channel.bean.order.DecodeSensitiveInfoResponse;
import me.chanjar.weixin.channel.bean.order.DeliveryUpdateParam;
import me.chanjar.weixin.channel.bean.order.OrderCompensationDeliveryParam;
import me.chanjar.weixin.channel.bean.order.OrderInfoResponse;
import me.chanjar.weixin.channel.bean.order.OrderListParam;
import me.chanjar.weixin.channel.bean.order.OrderListResponse;
import me.chanjar.weixin.channel.bean.order.OrderSearchParam;
import me.chanjar.weixin.channel.bean.order.PreShipmentChangeSkuResponse;
import me.chanjar.weixin.channel.bean.order.PresentSubOrderResponse;
import me.chanjar.weixin.channel.bean.order.PrivateNumberGetPhoneResponse;
import me.chanjar.weixin.channel.bean.order.RealNumberViewAuditResponse;
import me.chanjar.weixin.channel.bean.order.VirtualTelNumberResponse;
import me.chanjar.weixin.common.error.WxErrorException;
/**
* 视频号小店 订单服务接口
*
* @author <a href="https://github.com/lixize">Zeyes</a>
* @link <a href="https://developers.weixin.qq.com/doc/channels/API/order/order_status_graph.html">订单接口文档</a>
*/
public interface WxChannelOrderService {
/**
* 获取订单
*
* @param orderId 订单id
* @return 订单详情
*
* @throws WxErrorException 异常
*/
OrderInfoResponse getOrder(String orderId) throws WxErrorException;
/**
* 获取订单详情
*
* @param orderId 订单id
* @param encodeSensitiveInfo 是否编码敏感信息
* @return 订单详情
*
* @throws WxErrorException 异常
*/
OrderInfoResponse getOrder(String orderId, Boolean encodeSensitiveInfo) throws WxErrorException;
/**
* 获取订单列表
*
* @param param 搜索条件
* @return 订单列表
*
* @throws WxErrorException 异常
*/
OrderListResponse getOrders(OrderListParam param) throws WxErrorException;
/**
* 订单搜索
*
* @param param 搜索条件
* @return 订单列表
*
* @throws WxErrorException 异常
*/
OrderListResponse searchOrder(OrderSearchParam param) throws WxErrorException;
/**
* 更改订单价格
*
* @param orderId 订单id
* @param expressFee 运费价格(以分为单位)(不填不改)
* @param changeOrderInfos 改价列表
* @return 结果
*
* @throws WxErrorException 异常
*/
WxChannelBaseResponse updatePrice(String orderId, Integer expressFee, List<ChangeOrderInfo> changeOrderInfos)
throws WxErrorException;
/**
* 更改订单备注
*
* @param orderId 订单id
* @param merchantNotes 备注
* @return BaseResponse
*
* @throws WxErrorException 异常
*/
WxChannelBaseResponse updateRemark(String orderId, String merchantNotes) throws WxErrorException;
/**
* 更新订单地址
*
* @param orderId 订单id
* @param userAddress 用户地址
* @return BaseResponse
*
* @throws WxErrorException 异常
*/
WxChannelBaseResponse updateAddress(String orderId, AddressInfo userAddress) throws WxErrorException;
/**
* 修改物流信息 <br /> 发货完成的订单可以修改,最多修改1次 拆包发货的订单暂不允许修改物流 虚拟商品订单暂不允许修改物流
*
* @param param 物流信息
* @return BaseResponse
*
* @throws WxErrorException 异常
*/
WxChannelBaseResponse updateDelivery(DeliveryUpdateParam param) throws WxErrorException;
/**
* 同意用户修改收货地址请求
*
* @param orderId 订单id
* @return BaseResponse
*
* @throws WxErrorException 异常
*/
WxChannelBaseResponse acceptAddressModify(String orderId) throws WxErrorException;
/**
* 拒接用户修改收货地址请求
*
* @param orderId 订单id
* @return BaseResponse
*
* @throws WxErrorException 异常
*/
WxChannelBaseResponse rejectAddressModify(String orderId) throws WxErrorException;
/**
* 关闭订单 (需要订单状态为未付款状态)
*
* @param orderId 订单id
* @return BaseResponse
*/
WxChannelBaseResponse closeOrder(String orderId);
/**
* 获取快递公司列表-旧
*
* @return 快递公司列表
*
* @throws WxErrorException 异常
*/
DeliveryCompanyResponse listDeliveryCompany() throws WxErrorException;
/**
* 获取快递公司列表
*
* @param ewaybillOnly 是否仅返回支持电子面单功能的快递公司
* @return 快递公司列表
*
* @throws WxErrorException 异常
*/
DeliveryCompanyResponse listDeliveryCompany(Boolean ewaybillOnly) throws WxErrorException;
/**
* 订单发货
*
* @param orderId 订单id
* @param deliveryList 物流信息
* @return BaseResponse
*
* @throws WxErrorException 异常
*/
WxChannelBaseResponse deliveryOrder(String orderId, List<DeliveryInfo> deliveryList) throws WxErrorException;
/**
* 上传生鲜质检信息<br />
*
* 注意事项:<br />
* 1. 非生鲜质检的订单不能进行上传 <br />
* 2. 图片url必须用图片上传接口获取 {@link WxChannelBasicService#uploadImg(int, String)}<br />
*
* @param orderId 订单id
* @param items 商品打包信息
* @return BaseResponse
*
* @throws WxErrorException 异常
*/
WxChannelBaseResponse uploadFreshInspect(String orderId, List<PackageAuditInfo> items) throws WxErrorException;
/**
* 兑换虚拟号
*
* @param orderId 订单id
* @return 虚拟号信息
* @throws WxErrorException 异常
*/
VirtualTelNumberResponse getVirtualTelNumber(String orderId) throws WxErrorException;
/**
* 解码订单包含的敏感数据
*
* @param orderId 订单id
* @return 解码结果
* @throws WxErrorException 异常
*/
DecodeSensitiveInfoResponse decodeSensitiveInfo(String orderId) throws WxErrorException;
/**
* 礼物订单新增备注信息
*
* @param orderId 礼物订单ID
* @param note 备注内容
* @return BaseResponse
* @throws WxErrorException 异常
*/
WxChannelBaseResponse addPresentNote(String orderId, String note) throws WxErrorException;
/**
* 获取礼物单的子单列表
*
* @param orderId 礼物订单ID
* @return 子单列表
* @throws WxErrorException 异常
*/
PresentSubOrderResponse getPresentSubOrders(String orderId) throws WxErrorException;
/**
* 获取待发货前更换SKU待处理请求
*
* @param orderId 订单ID
* @return 换SKU信息
* @throws WxErrorException 异常
*/
PreShipmentChangeSkuResponse getPreShipmentChangeSku(String orderId) throws WxErrorException;
/**
* 同意待发货前更换SKU请求
*
* @param orderId 订单ID
* @return BaseResponse
* @throws WxErrorException 异常
*/
WxChannelBaseResponse approvePreShipmentChangeSku(String orderId) throws WxErrorException;
/**
* 拒绝待发货前更换SKU请求
*
* @param orderId 订单ID
* @param rejectReason 拒绝原因
* @return BaseResponse
* @throws WxErrorException 异常
*/
WxChannelBaseResponse rejectPreShipmentChangeSku(String orderId, String rejectReason) throws WxErrorException;
/**
* 申请查看订单真实号码
*
* @param orderId 订单ID
* @return BaseResponse
* @throws WxErrorException 异常
*/
WxChannelBaseResponse applyRealNumber(String orderId) throws WxErrorException;
/**
* 查看订单真实号审核状态
*
* @param orderId 订单ID
* @return 审核状态
* @throws WxErrorException 异常
*/
RealNumberViewAuditResponse getRealNumberViewAudit(String orderId) throws WxErrorException;
/**
* 订单再次申请虚拟号
*
* @param orderId 订单ID
* @return BaseResponse
* @throws WxErrorException 异常
*/
WxChannelBaseResponse applyVirtualNumberAgain(String orderId) throws WxErrorException;
/**
* 订单虚拟号延期
*
* @param orderId 订单ID
* @return BaseResponse
* @throws WxErrorException 异常
*/
WxChannelBaseResponse delayVirtualNumber(String orderId) throws WxErrorException;
/**
* 添加待认证的手机号
*
* @param phone 手机号
* @return BaseResponse
* @throws WxErrorException 异常
*/
WxChannelBaseResponse addPrivatePhone(String phone) throws WxErrorException;
/**
* 获取短信验证码
*
* @param phone 手机号
* @return BaseResponse
* @throws WxErrorException 异常
*/
WxChannelBaseResponse sendPrivatePhoneVerifyCode(String phone) throws WxErrorException;
/**
* 获取小店手机号认证状态
*
* @return 手机号认证状态
* @throws WxErrorException 异常
*/
PrivateNumberGetPhoneResponse getPrivatePhone() throws WxErrorException;
/**
* 订单补发货
*
* @param param 补发货参数
* @return BaseResponse
* @throws WxErrorException 异常
*/
WxChannelBaseResponse compensationDelivery(OrderCompensationDeliveryParam param) throws WxErrorException;
}