import request from '@/utils/request'

// 查询装置区域管理列表
export function listDevice(query) {
  return request({
    url: '/invoice/device/list',
    method: 'get',
    params: query
  })
}

export function listRegionalHead() {
  return request({
    url: '/invoice/device/listRegionalHead',
    method: 'get',
  })
}

// 查询装置区域下拉列表数据
export function selectDevice(query) {
  return request({
    url: '/invoice/device/select',
    method: 'get',
    params: query
  })
}

// 查询装置区域管理详细
export function getDevice(id) {
  return request({
    url: '/invoice/device/' + id,
    method: 'get'
  })
}

// 新增装置区域管理
export function addDevice(data) {
  return request({
    url: '/invoice/device',
    method: 'post',
    data: data
  })
}

// 修改装置区域管理
export function updateDevice(data) {
  return request({
    url: '/invoice/device',
    method: 'put',
    data: data
  })
}

// 删除装置区域管理
export function delDevice(id) {
  return request({
    url: '/invoice/device/' + id,
    method: 'delete'
  })
}

// 导出装置区域管理
export function exportDevice(query) {
  return request({
    url: '/invoice/device/export',
    method: 'get',
    params: query
  })
}
