import request from '@/utils/request'

// 查询线下订单列表
export function listStoreOrderOffline(query) {
  return request({
    url: '/hisStore/fsStoreOrderOfflineScrm/list',
    method: 'get',
    params: query
  })
}

// 查询线下订单详细
export function getStoreOrderOffline(orderId) {
  return request({
    url: '/hisStore/fsStoreOrderOfflineScrm/' + orderId,
    method: 'get'
  })
}
//查看电话
export function getPhone(orderId) {
  return request({
    url: '/hisStore/fsStoreOrderOfflineScrm/queryPhone/' + orderId,
    method: 'get'
  })
}

// 新增线下订单
export function addStoreOrderOffline(data) {
  return request({
    url: '/store/storeOrderOffline',
    method: 'post',
    data: data
  })
}

// 修改线下订单
export function updateStoreOrderOffline(data) {
  return request({
    url: '/store/storeOrderOffline',
    method: 'put',
    data: data
  })
}

// 删除线下订单
export function delStoreOrderOffline(orderId) {
  return request({
    url: '/hisStore/fsStoreOrderOfflineScrm/' + orderId,
    method: 'delete'
  })
}

// 导出线下订单
export function exportStoreOrderOffline(query) {
  return request({
    url: '/hisStore/fsStoreOrderOfflineScrm/export',
    method: 'get',
    params: query
  })
}


//审核订单
export function auditOrder(orderId) {
  return request({
    url: '/hisStore/fsStoreOrderOfflineScrm/auditOrder/' + orderId,
    method: 'post',
  })
}
