fix: close platform admin final audit findings

This commit is contained in:
2026-07-27 12:02:08 +08:00
parent 0ba4136e1a
commit 34e8b092b3
70 changed files with 1873 additions and 348 deletions

View File

@@ -7,11 +7,11 @@ import (
// DevDeviceBinding 对应 dev_device_binding保存设备授权绑定。
type DevDeviceBinding struct {
Entity
SmartCylinderValveID uint64 `gorm:"column:smart_cylinder_valve_id;not null;index" json:"smart_cylinder_valve_id"`
UserAccountID uint64 `gorm:"column:user_account_id;not null;index" json:"user_account_id"`
EffectiveAt time.Time `gorm:"column:effective_at;type:timestamptz;not null" json:"effective_at"`
ExpiredAt *time.Time `gorm:"column:expired_at;type:timestamptz" json:"expired_at"`
Entity // 公共实体字段
SmartCylinderValveID uint64 `gorm:"column:smart_cylinder_valve_id;not null;index" json:"smart_cylinder_valve_id"` // smart_cylinder_valve_id 业务字段
UserAccountID uint64 `gorm:"column:user_account_id;not null;index" json:"user_account_id"` // user_account_id 业务字段
EffectiveAt time.Time `gorm:"column:effective_at;type:timestamptz;not null" json:"effective_at"` // effective_at 业务字段
ExpiredAt *time.Time `gorm:"column:expired_at;type:timestamptz" json:"expired_at"` // expired_at 业务字段
}
func init() { database.AppendMigrate(&DevDeviceBinding{}) }