import request from '@/utils/request'

// 获取订单列表
export function getList(params) {
  return request({
    url: '/order/list',
    method: 'get',
    params
  })
}

// 编辑备注
export function saveRemark(params) {
  return request({
    url: '/order/remark',
    method: 'post',
    params
  })
}

// 获取订单详情
export function getOrderDetail(params) {
  return request({
    url: '/order/detail',
    method: 'get',
    params
  })
}

// 取消订单
export function cancelOrder(params) {
  return request({
    url: '/order/cancel',
    method: 'post',
    params
  })
}

// 确认收款
export function confirmOrder(params) {
  return request({
    url: '/order/ack',
    method: 'post',
    params
  })
}

// 修改价格
export function changePrice(params) {
  return request({
    url: '/order/price/update',
    method: 'post',
    params
  })
}

// 修改收货信息
export function changeReceiveInfo(params) {
  return request({
    url: '/order/rece/info/update',
    method: 'post',
    data: params
  })
}

// 发货
export function goodsDeliver(params) {
  return request({
    url: '/order/goods/deliver',
    method: 'post',
    params
  })
}

// 获取维权订单列表
export function getRefundList(params) {
  return request({
    url: '/order/refund/list',
    method: 'get',
    params
  })
}

// 编辑维权备注
export function saveRefundRemark(params) {
  return request({
    url: '/order/refund/remark',
    method: 'post',
    params
  })
}

// 变更维权处理状态
export function changeExamineStatus(params) {
  return request({
    url: '/order/refund/examine',
    method: 'post',
    params
  })
}

// 变更维权处理状态
export function receiveProd(params) {
  return request({
    url: '/order/refund/ack',
    method: 'post',
    params
  })
}

// 获取维权订单详情
export function getOrderRefundDetail(params) {
  return request({
    url: '/order/refund/refund/detail',
    method: 'get',
    params
  })
}

// 退款
export function orderRefund(params) {
  return request({
    url: '/order/detail/refund',
    method: 'post',
    params
  })
}

// 理赔
export function orderCompensate(params) {
  return request({
    url: '/order/cliaims/refund',
    method: 'post',
    params
  })
}

// 获取理赔列表
export function getCompensateList(params) {
  return request({
    url: '/order/cliaims/list',
    method: 'get',
    params
  })
}

// 卖家批量设置备注
export function batchRemark(params) {
  return request({
    url: '/order/batch/remark',
    method: 'post',
    data: params
  })
}

export function getWebsiteList(params) {
  return request({
    url: '/websit/list',
    method: 'get',
    params
  })
}

// 修改快递单号
export function editLogistics(params) {
  return request({
    url: '/order/express/update',
    method: 'post',
    params
  })
}

// 获取地区树
export function getRegion(params) {
  return request({
    url: '/common/region/list',
    method: 'get',
    params
  })
}

// 修改收货地址
export function editAddress(params) {
  return request({
    url: '/order/rece/info/update',
    method: 'post',
    data: params
  })
}

// 获取工单
export function getWorkOrder(params) {
  return request({
    url: '/order/work/list',
    method: 'get',
    params
  })
}

// 新增标签
export function changeShow(params) {
  return request({
    url: '/order/comment/show',
    method: 'post',
    params
  })
}

// 获取工单
export function getWorkOrderLink(params) {
  return request({
    url: '/common/gf/login',
    method: 'get',
    params
  })
}