ManualControl

This commit is contained in:
2025-10-13 10:39:51 +08:00
parent b4d31d3133
commit 9b6548c1b4
4 changed files with 87 additions and 12 deletions

View File

@@ -20,6 +20,12 @@ type UpdateDeviceRequest struct {
Properties map[string]interface{} `json:"properties,omitempty"`
}
// ManualControlDeviceRequest 定义了手动控制设备时需要传入的参数
type ManualControlDeviceRequest struct {
// Action 不传表示这是一个传感器, 会触发一次采集
Action *string `json:"action" binding:"oneof=on off"`
}
// CreateAreaControllerRequest 定义了创建区域主控时需要传入的参数
type CreateAreaControllerRequest struct {
Name string `json:"name" binding:"required"`