16 lines
829 B
Go
16 lines
829 B
Go
package models
|
||
|
||
import "git.apinb.com/bsm-sdk/core/database"
|
||
|
||
// DevSmartCylinderValve 对应 dev_smart_cylinder_valve,保存智能瓶阀档案。
|
||
type DevSmartCylinderValve struct {
|
||
Entity
|
||
DeviceNo string `gorm:"column:device_no;type:varchar(64);not null;uniqueIndex" json:"device_no"`
|
||
Model string `gorm:"column:model;type:varchar(64);not null;default:''" json:"model"`
|
||
OnlineStatus string `gorm:"column:online_status;type:varchar(32);not null;default:'offline'" json:"online_status"`
|
||
OwnerIdentity string `gorm:"column:owner_identity;type:varchar(36);not null;default:'';index" json:"owner_identity"`
|
||
}
|
||
|
||
func init() { database.AppendMigrate(&DevSmartCylinderValve{}) }
|
||
func (table *DevSmartCylinderValve) TableName() string { return "dev_smart_cylinder_valve" }
|