Documentation
¶
Overview ¶
Package models 模型通用属性和方法
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BaseModel ¶
type BaseModel struct {
ID uint32 `gorm:"column:id;primaryKey;autoIncrement;" json:"id,omitempty"`
CreatedAt time.Time `gorm:"column:created_at;" json:"created_at,omitempty"`
UpdatedAt time.Time `gorm:"column:updated_at;" json:"updated_at,omitempty"`
}
BaseModel 模型基类
type RoleInfo ¶
type RoleInfo struct {
BaseModel
AppId int `gorm:"uniqueIndex:uni_uid_appId_serverId"`
Uid uint32 `gorm:"default:null;uniqueIndex:uni_uid_appId_serverId"`
PlatFormId string `gorm:""`
ChannelId string `gorm:""`
ServerId string `gorm:"uniqueIndex:uni_uid_appId_serverId"`
ServerName string `gorm:"type:varchar(255);default:null;"`
RoleId string `gorm:"type:int;"`
Role string `gorm:"type:varchar(64);default:null;"`
FirstPayDate time.Time `gorm:"default:null;"`
LastPayDate time.Time `gorm:"default:null;"`
LastLoginTime time.Time `gorm:"default:null;"`
PayTotal int `gorm:"default:0"`
PayCount int `gorm:"default:0"`
DistinctId string `gorm:""`
AccountId string `gorm:""`
GameVipLevel string `gorm:""`
GameUserLevel int `gorm:""`
DeletedAt gorm.DeletedAt `gorm:"index"`
}
func (*RoleInfo) GetStringUID ¶
func (*RoleInfo) GetTableName ¶
Click to show internal directories.
Click to hide internal directories.