import request from '@/utils/request'

// 查询设备类型信息列表
export function listDevicetype(query) {
  return request({
    url: '/dms/devicetype/list',
    method: 'get',
    params: query
  })
}

// 查询设备类型信息详细
export function getDevicetype(deviceTypeId) {
  return request({
    url: '/dms/devicetype/' + deviceTypeId,
    method: 'get'
  })
}

// 新增设备类型信息
export function addDevicetype(data) {
  return request({
    url: '/dms/devicetype',
    method: 'post',
    data: data
  })
}

// 修改设备类型信息
export function updateDevicetype(data) {
  return request({
    url: '/dms/devicetype',
    method: 'put',
    data: data
  })
}

// 删除设备类型信息
export function delDevicetype(deviceTypeId) {
  return request({
    url: '/dms/devicetype/' + deviceTypeId,
    method: 'delete'
  })
}

//根据设备id查询设备类型信息

export function selectDevicetypeByDeviceId(query) {
  return request({
    url: '/dms/devicetype/selectDevicetypeByDeviceId',
    method: 'get',
    params: query
  })
}
