/**
 *  手太欠
 *  5g获客星光网 - 商城首页
 */

import {req} from "../request"

const index  		= data => req({url: "orders", data: data}) //全部订单
const unpaid 		= () => req({url: "orders/unpaid"}) //待付款
const paid   		= () => req({url: "orders/paid"}) //待发货
const delive 		= () => req({url: "orders/delivered"}) //待收货
const refund 		= () => req({url: "orders/refunds"}) //退款
const cancel 		= (orderId) => req({url: "orders/cancel/" + orderId}) //取消订单
const orders 		= (orderId) => req({url: "orders/" + orderId}) //订单-详情
const paymen 		= (orderId) => req({url: "payments/order/" + orderId}) //订单支付-详情
const sign   		= (orderId) => req({url: "orders/sign/" + orderId}) //订单签收
const goosRefund 	= (orderId) => req({url: "orders/refund/" + orderId}) //订单退货
const formRefund 	= (orderId,data) => req({url: "orders/refund/" + orderId, method: "POST", data: data}) //订单退货-提交

export default({
	index,
	unpaid,
	paid,
	delive,
	refund,
	cancel,
	orders,
	paymen,
	sign,
	refund,
	goosRefund,
	formRefund
})