You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

18 lines
660 B

package data
import "time"
// User 用户
type User struct {
Uid string `gorm:"column:uid;primaryKey;" json:"uid"` // 用户id
Account string `gorm:"column:account" json:"account"` // 登录账号
Username string `gorm:"column:username" json:"username"` // 用户名
Password string `gorm:"column:password" json:"password"` // 密码
Avatar string `gorm:"column:avatar" json:"avatar"` // 头像
CreateAt *time.Time `gorm:"column:create_at" json:"createAt"` // 创建时间
UpdateAt *time.Time `gorm:"column:update_at" json:"updateAt"` // 更新时间
}
func (User) TableName() string {
return "t_user"
}