import request from '@/utils/request'

// 商品订单列表接口
export function getOrderLists(params) {
    return request({
        url: '/sale/manage/order/order-invoicing-list',
        method: 'get',
        params
    })
}
export function getOrderList(params) {
    return request({
        url: '/sale/manage/order/query-order-list',
        method: 'get',
        params
    })
}
// 查看商品订单列表接口
export function getFindOrderList(params) {
    return request({
        url: '/sale/manage/order/get-order-list',
        method: 'get',
        params
    })
}

//订单类型枚举
export function getOrderType(params) {
    return request({
        url: '/system/pub/enums/order-type',
        method: 'get',
        params
    })
}
//撤单类型枚举
export function getCancleType(params) {
    return request({
        url: 'system/pub/enums/cancel-the-order',
        method: 'get',
        params
    })
}

//出货明细汇总统计订单类型下拉选
export function getOrderTypeRepurchaseAll(params) {
    return request({
        url: '/system/pub/enums/order-business',
        method: 'get',
        params
    })
}



//伞下直推新增业绩-订单类型下拉选
export function getUnderAddOrderType(params) {
    return request({
        url: '/system/pub/enums/order-business',
        method: 'get',
        params
    })
}

//伞下直推新增业绩（新）订单类型下拉选
export function getUnderAddOrderTypeNew(params) {
    return request({
        url: '/system/pub/enums/orderUp-business',
        method: 'get',
        params
    })
}


//收益类型
export function getYieldType(params) {
  return request({
    url: '/system/manage/bd-bonus-items/list',
    method: 'get',
    params
  })
}
//收益状态
export function getYieldStatus(params) {
  return request({
    url: '/system/pub/enums/bonus-income-status',
    method: 'get',
    params
  })
}

//发货方式
export function getDeliveryList(params) {
    return request({
        url: '/system/pub/enums/delivery-list',
        method: 'get',
        params
    })
}



//支付方式
export function getOrderPayType(params) {
    return request({
        url: '/system/pub/enums/order-pay-type',
        method: 'get',
        params
    })
}

//查询自提清单
export function getOrderSelfList(data) {
    return request({
        url: '/sale/manage/order-business/self-list?pageNum=' + data.pageNum + '&pageSize=' + data.pageSize,
        method: 'post',
        data
    })
}

//自提清单-同意1/驳回3
export function selfApprove(data) {
    return request({
        url: '/sale/manage/order-business/self-approve',
        method: 'post',
        data
    })
}


//查询修改地址列表
export function getModifyAddress(params) {
    return request({
        url: '/member/manage/self-modify-address/list',
        method: 'get',
        params
    })
}

//自提清单-申请自提
export function saveSelfOrder(data) {
    return request({
        url: '/sale/manage/order-business/self-order',
        method: 'post',
        data
    })
}
//修改地址查询详情
export function queryPass(data) {
    return request({
        url: '/member/manage/self-modify-address/queryPass',
        method: 'post',
        data
    })
}

//修改地址驳回
export function rejectAddress(data) {
    return request({
        url: '/member/manage/self-modify-address/reject',
        method: 'post',
        data
    })
}

//订单添加开票备注
export function updateOrderRemarks(data) {
    return request({
        url: '/sale/manage/order/update-order-remarks',
        method: 'post',
        data
    })
}


