import request from '@/utils/request'

// 获取工单列表数据
export function getOrderLists(params) {
  return request({
    url: 'callcenterapi/api/BusOrder/getlistbypage',
    method: 'get',
    params
  })
}

// 获取工单数据
export function getOrder(ordercode) {
  return request({
    url: 'callcenterapi/api/BusOrder/getsingle',
    method: 'get',
    params: {
      ordercode
    }
  })
}

// 添加工单数据
export function addOrder(data) {
  return request({
    url: 'callcenterapi/api/BusOrder/add',
    method: 'post',
    data
  })
}

// 编辑工单数据
export function editOrder(data) {
  return request({
    url: 'callcenterapi/api/BusOrder/update',
    method: 'post',
    data
  })
}

// 删除工单数据
export function deleteOrder(ids) {
  return request({
    url: 'callcenterapi/api/BusOrder/delete',
    method: 'post',
    data: {
      ids
    }
  })
}
