feat:deviceLog and deviceSimulator

This commit is contained in:
alwayssuper
2025-01-06 16:39:22 +08:00
parent b71fa84af3
commit c9e00d97eb
6 changed files with 143 additions and 142 deletions

View File

@ -69,7 +69,7 @@ export interface SimulatorDataVO {
deviceKey: string
type: string
subType: string
reportTime: string
reportTime: number // 时间戳
content: string // 存储 JSON 字符串
}
@ -151,5 +151,9 @@ export const DeviceApi = {
// 模拟设备
simulatorDevice: async (data: SimulatorDataVO) => {
return await request.post({ url: `/iot/device/data/simulator`, data })
},
//查询设备日志分页
getDeviceLogPage: async (params: any) => {
return await request.get({ url: `/iot/device/data/log/page`, params })
}
}

View File

@ -17,6 +17,13 @@ export interface ThingModelData {
service?: ThingModelService // 服务
}
/**
* IoT 模拟设备
*/
export interface SimulatorData extends ThingModelData {
simulateValue?: string | number // 用于存储模拟值
}
/**
* ThingModelProperty 类型
*/