import request from '@/utils/request'

// 查询报修单列表
export function listRepairForm(query) {
  return request({
    url: '/business/repairForm/list',
    method: 'get',
    params: query
  })
}

// 查询报修单详细
export function getRepairForm(id) {
  return request({
    url: '/business/repairForm/' + id,
    method: 'get'
  })
}

// 新增报修单
export function addRepairForm(data) {
  return request({
    url: '/business/repairForm',
    method: 'post',
    data: data
  })
}

// 修改报修单
export function updateRepairForm(data) {
  return request({
    url: '/business/repairForm',
    method: 'put',
    data: data
  })
}

// 删除报修单
export function delRepairForm(id) {
  return request({
    url: '/business/repairForm/' + id,
    method: 'delete'
  })
}

// 作废报修单
export function abolishRepairForm(id) {
  return request({
    url: '/business/repairForm/abolish/' + id,
    method: 'put'
  })
}
