// Code generated by gorm.io/gen. DO NOT EDIT. // Code generated by gorm.io/gen. DO NOT EDIT. // Code generated by gorm.io/gen. DO NOT EDIT. package model import ( "time" ) const TableNameUserGamePasses = "user_game_passes" // UserGamePasses 用户游戏次数卡 type UserGamePasses struct { ID int64 `gorm:"column:id;primaryKey;autoIncrement:true;comment:主键ID" json:"id"` // 主键ID CreatedAt time.Time `gorm:"column:created_at;not null;default:CURRENT_TIMESTAMP(3);comment:创建时间" json:"created_at"` // 创建时间 UpdatedAt time.Time `gorm:"column:updated_at;not null;default:CURRENT_TIMESTAMP(3);comment:更新时间" json:"updated_at"` // 更新时间 UserID int64 `gorm:"column:user_id;not null;comment:用户ID" json:"user_id"` // 用户ID ActivityID int64 `gorm:"column:activity_id;comment:指定活动ID,NULL表示全局通用" json:"activity_id"` // 指定活动ID,NULL表示全局通用 Remaining int32 `gorm:"column:remaining;not null;comment:剩余次数" json:"remaining"` // 剩余次数 TotalGranted int32 `gorm:"column:total_granted;not null;comment:累计发放次数" json:"total_granted"` // 累计发放次数 TotalUsed int32 `gorm:"column:total_used;not null;comment:累计使用次数" json:"total_used"` // 累计使用次数 ExpiredAt time.Time `gorm:"column:expired_at;comment:过期时间,NULL表示永不过期" json:"expired_at"` // 过期时间,NULL表示永不过期 Source string `gorm:"column:source;default:admin;comment:来源: admin/purchase/task" json:"source"` // 来源: admin/purchase/task Remark string `gorm:"column:remark;comment:备注" json:"remark"` // 备注 } // TableName UserGamePasses's table name func (*UserGamePasses) TableName() string { return TableNameUserGamePasses }