import request from '@/utils/request'

// 查询分类列表
export function list(query) {
  return request({
    url: `/device/manage/category/list`,
    method: 'get',
    params: query
  })
}

// 添加设备类型
export function create(data) {
  return request({
    url: `/device/manage/category/add`,
    method: 'post',
    data: data
  })
}

// 编辑设备类型
export function edit(data) {
  return request({
    url: `/device/manage/category/edit`,
    method: 'post',
    data: data
  })
}

// 删除
export function remove(id) {
  return request({
    url: `/device/manage/category/${id}`,
    method: 'delete'
  })
}