import send_request from '../utils/send_request';

/**
 * 获取订单列表
 * @returns
 */
export function getOrderList(params) {
    return send_request({
        url: '/shop/order/manage/getOrderList',
        method: 'GET',
        params: params,
    });
};

/**
 * 获取订单详情
 * @returns
 */
export function getOrderDetail(params) {
    return send_request({
        url: '/shop/order/miniprogram/orderDetail',
        method: 'GET',
        params: params,
    });
};

/**
 * 订单发货
 * @returns
 */
export function deliverOrder(params) {
    return send_request({
        url: '/shop/order/manage/deliverOrder',
        method: 'POST',
        useQS: true,
        params: params,
    });
};

/**
 * 关闭订单
 * @returns
 */
export function withdrawOrder(params) {
    return send_request({
        url: '/shop/order/manage/cancelOrder',
        method: 'POST',
        useQS: true,
        params: params,
    });
};

/**
 * 导出订单列表
 * @returns
 */
export function exportOrderList(params) {
    return send_request({
        url: '/shop/order/manage/exportOrderList',
        method: 'GET',
        params: params,
    });
};
