 /*
  * 手太欠
  * 愿这世界都如故事里一样 美好而动人~
*/

import { req } from "../request"

// 订单首页
const list = data => req({
    url : "mall/orders",
    data: data
})

// 订单详情
const goodsDet = (order_no) => req({
    url : "mall/orders/" + order_no
})

// 订单取消
const goodsCancel = (order_no) => req({
    url : "mall/orders/" + order_no + "/cancel",
    method: "PUT"
})

// 订单删除
const goodsDel = (order_no) => req({
    url : "mall/orders/" + order_no,
    method: "DELETE"
})

// 订单签收
const goodsSign = (order_no) => req({
    url : "mall/orders/" + order_no + "/sign",
    method: "PUT"
})

// 快递100-免费
const kuaiDi = (data) => req({
    url : "mall/orders/express",
    data: data
})

export default ({
    list,
    goodsDet,
    goodsCancel,
    goodsDel,
    goodsSign,
    kuaiDi
})