Files
dtx_store/apis/interfaces/order.js
2022-06-11 11:06:05 +08:00

126 lines
1.8 KiB
JavaScript

/**
* Web唐明明
* 匆匆数载恍如梦,岁月迢迢华发增。
* 碌碌无为枉半生,一朝惊醒万事空。
* moduleName: 订单管理
*/
import { request } from '../index'
// 订单列表
const orders = data => {
return request({
url: 'mall/orders',
data
})
}
// 订单详情
const info = id => {
return request({
url: 'mall/orders/' + id
})
}
// 删除订单
const del = id => {
return request({
url: 'mall/orders/' + id,
method: 'DELETE'
})
}
// 取消订单
const cancel = id => {
return request({
url: 'mall/orders/' + id + '/cancel',
method: 'PUT'
})
}
// 签收订单
const sign = id => {
return request({
url: 'mall/orders/' + id + '/sign',
method: 'PUT'
})
}
// 物流查询
const logistic = id => {
return request({
url: 'mall/orders/' + id + '/logistic'
})
}
// 退货
const refund = (id,method,params) => {
return request({
url: 'mall/orders/' + id + '/refund',
method:method,
data:params
})
}
// 退货前置
const refundpre = (id) => {
return request({
url: 'mall/orders/' + id + '/refundpre'
})
}
// 货款、售后列表
const refunds = data => {
return request({
url: 'mall/refunds',
data
})
}
// 货款、售后详情
const refundsInfo = id => {
return request({
url: 'mall/refunds/'+id
})
}
// 货款、售后j 进度
const refundsLogs = id => {
return request({
url: 'mall/refunds/'+id+'/logs'
})
}
// 物流列表
const deliverpre = ()=> {
return request({
url: 'mall/refunds/deliverpre'
})
}
// 提交发货接口
const refundsDeliver = (id,data) => {
return request({
url: 'mall/refunds/'+id+'/deliver',
method:'post',
data
})
}
export {
orders,
info,
del,
cancel,
sign,
logistic,
refund,
refundpre,
refunds,
refundsInfo,
refundsLogs,
deliverpre,
refundsDeliver,
}