2026-07-27 00:18:42 +08:00
|
|
|
|
package models
|
|
|
|
|
|
|
|
|
|
|
|
import "git.apinb.com/bsm-sdk/core/database"
|
|
|
|
|
|
|
|
|
|
|
|
// DevSmartCylinderValve 对应 dev_smart_cylinder_valve,保存智能瓶阀档案。
|
|
|
|
|
|
type DevSmartCylinderValve struct {
|
2026-07-27 12:02:08 +08:00
|
|
|
|
Entity // 公共实体字段
|
|
|
|
|
|
DeviceNo string `gorm:"column:device_no;type:varchar(64);not null;uniqueIndex" json:"device_no"` // device_no 业务字段
|
|
|
|
|
|
Model string `gorm:"column:model;type:varchar(64);not null;default:''" json:"model"` // model 业务字段
|
|
|
|
|
|
OnlineStatus string `gorm:"column:online_status;type:varchar(32);not null;default:'offline'" json:"online_status"` // online_status 业务字段
|
|
|
|
|
|
OwnerIdentity string `gorm:"column:owner_identity;type:varchar(36);not null;default:'';index" json:"owner_identity"` // owner_identity 业务字段
|
2026-07-27 00:18:42 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
func init() { database.AppendMigrate(&DevSmartCylinderValve{}) }
|
|
|
|
|
|
func (table *DevSmartCylinderValve) TableName() string { return "dev_smart_cylinder_valve" }
|