You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
57 lines
1.3 KiB
57 lines
1.3 KiB
import request from '@/utils/request'
|
|
|
|
// api地址
|
|
const api = {
|
|
todoCounts: 'order/todoCounts',
|
|
list: 'order/list',
|
|
detail: 'order/detail',
|
|
express: 'order/express',
|
|
cancel: 'order/cancel',
|
|
receipt: 'order/receipt',
|
|
pay: 'order/pay',
|
|
|
|
ordquery:'AgencyAddress/order/queryRrder' //订单查询
|
|
}
|
|
|
|
// 当前用户待处理的订单数量
|
|
export function todoCounts(param, option) {
|
|
return request.get(api.todoCounts, param, option)
|
|
}
|
|
|
|
// 我的订单列表
|
|
export function list(param, option) {
|
|
return request.get(api.list, param, option)
|
|
}
|
|
|
|
// 订单详情
|
|
export function detail(orderId, param) {
|
|
return request.get(api.detail, { orderId, ...param })
|
|
}
|
|
|
|
// 获取物流信息
|
|
export function express(orderId, param) {
|
|
return request.get(api.express, { orderId, ...param })
|
|
}
|
|
|
|
// 取消订单
|
|
export function cancel(orderId, data) {
|
|
return request.post(api.cancel, { orderId, ...data })
|
|
}
|
|
|
|
// 确认收货
|
|
export function receipt(orderId, data) {
|
|
return request.post(api.receipt, { orderId, ...data })
|
|
}
|
|
|
|
// 立即支付
|
|
export function pay(orderId, payType, param) {
|
|
return request.get(api.pay, { orderId, payType, ...param })
|
|
}
|
|
|
|
// order query
|
|
export function ordquery(data){
|
|
let option={header:{
|
|
"Content-Type":"application/x-www-form-urlencoded;charset=UTF-8"
|
|
}}
|
|
return request.post(api.ordquery,data,option)
|
|
}
|