import request from '@/utils/request'

// 查询设备告警列表
export function listWaring(query) {
    return request({
        url: '/device/waring/list',
        method: 'get',
        params: query
    })
}

// 查询设备告警详细
export function getWaring(id) {
    return request({
        url: '/device/waring/' + id,
        method: 'get'
    })
}

// 新增设备告警
export function addWaring(data) {
    return request({
        url: '/device/waring',
        method: 'post',
        data: data
    })
}

// 修改设备告警
export function updateWaring(data) {
    return request({
        url: '/device/waring',
        method: 'put',
        data: data
    })
}

// 删除设备告警
export function delWaring(id) {
    return request({
        url: '/device/waring/' + id,
        method: 'delete'
    })
}
