riku
2025-05-30 c2e36c45578e63ad17c5e258c92d62d9ae03dadb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import { $http } from './index';
 
/**
 * 走航设备相关接口API
 */
export default {
  fethchDevice({ type }) {
    let params = type ? `?&type=${type}` : '';
    return $http.get(`air/device/type${params}`).then((res) => res.data);
  },
 
  putNewDevice(device) {
    return $http.put(`air/device/create`, device).then((res) => res.data);
  },
 
  deleteDevice(deviceCode) {
    let params = `deviceCode=${deviceCode}`;
    return $http.delete(`air/device/delete?${params}`).then((res) => res.data);
  }
};