game/common/model/user/userResources.go

20 lines
649 B
Go
Raw Normal View History

2025-06-02 01:07:35 +08:00
package user
// 玩家账户表
type UserResources struct {
2025-06-04 13:08:58 +08:00
ID uint `gorm:"primarykey;autoIncrement" json:"id"`
2025-06-02 01:07:35 +08:00
accountId uint `gorm:"type:bigint;uniqueIndex;not null"` // 帐号id
Nickname string `gorm:"type:varchar(32);uniqueIndex;not null"` // 昵称
AvatarUrl string `gorm:"type:varchar(255)"` // 头像
AvatarFrame string `gorm:"type:varchar(255)"` // 头像框
VipExp int32 `gorm:"type:int"` // vip经验值
}
func (u UserResources) GetId() uint {
return u.ID
}
2025-06-04 01:56:38 +08:00
func (u UserResources) TableName() string {
return "user_resources"
}