import request from '@/utils/request'
/*
 **大华相关接口
 */

//查询
export function deviceList(params) {
    return request({
        url: `/device/list`,
        method: 'get',
        params: params
    })
}
//新增
export function deviceAdd(params) {
    return request({
        url: `/device`,
        method: 'post',
        data: params
    })
}
//编辑
export function deviceEdit(data) {
    return request({
        url: `/device`,
        method: 'put',
        data
    })
}
//删除
export function deviceRemove(params) {
    return request({
        url: `/device/` + params,
        method: 'delete',
    })
}


//大华设备列表获取
export function getLocalDeviceList(params) {
    return request({
        url: `/dhController/getLocalDeviceList`,
        method: 'post',
        params: params
    })
}


//设备下属单元信息获取 顺序2 单元
export function getLocalUnitNodes(params) {
    return request({
        url: `/dhController/getLocalUnitNodes`,
        method: 'post',
        params: params
    })
}


//单元下属通道信息获取 顺序3 通道
export function getLocalChannel(params) {
    return request({
        url: `/dhController/getLocalChannel`,
        method: 'post',
        params: params
    })
}