Files
venue_web/src/api/device.js
2024-02-01 21:39:06 +08:00

42 lines
781 B
JavaScript

import http from '@/utils/http'
/**
* 查询门禁设备
*/
export function find(id) {
return http.get('/device/' + id)
}
export function reconnect(id) {
return http.post('/device/reconnect/' + id)
}
export function adminEnter(id) {
return http.post('/device/admin/enter/' + id)
}
export function adminOut(id, pwd) {
return http.post('/device/admin/out/' + id, { 'password': pwd })
}
export function uploadLog(id) {
return http.post('/device/upload/log/' + id)
}
export function checkAlive(id) {
return http.post('/device/checkAlive/' + id)
}
/**
* 删除门禁设备
*/
export function remove(ids) {
return http.post('/device/delete', { 'id[]': ids })
}
/**
* 保存门禁设备
*/
export function save(params) {
return http.post('/device', params)
}