|
@@ -18,7 +18,7 @@ type DeviceCommand struct {
|
|
|
Name string `gorm:"column:name;size:200" json:"name"` // 名称
|
|
Name string `gorm:"column:name;size:200" json:"name"` // 名称
|
|
|
Command string `gorm:"column:command;size:200" json:"command"` // 指令
|
|
Command string `gorm:"column:command;size:200" json:"command"` // 指令
|
|
|
DataType string `gorm:"column:data_type;size:100" json:"data_type"` // 数据类型
|
|
DataType string `gorm:"column:data_type;size:100" json:"data_type"` // 数据类型
|
|
|
- Data DeviceCommandDatas `gorm:"foreignkey:CommandId" json:"data"` // 数据
|
|
|
|
|
|
|
+ Data DeviceCommandDatas `gorm:"foreignkey:command_id" json:"data"` // 数据
|
|
|
CommandType int `gorm:"column:command_type" json:"command_type"` // 指令类型
|
|
CommandType int `gorm:"column:command_type" json:"command_type"` // 指令类型
|
|
|
}
|
|
}
|
|
|
|
|
|