Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Game ¶
type Game struct {
bun.BaseModel `bun:"table:games"`
Id int64 `bun:"id,pk,autoincrement"`
UserId int64 `bun:"user_id,notnull"`
WordId int `bun:"word_id,notnull"`
GuessLimit int8 `bun:"guess_limit,notnull"`
IsPlaying bool `bun:"is_playing,notnull,default:true"`
IsWon sql.NullBool `bun:"is_won"`
CreatedAt time.Time `bun:"created_at,notnull"`
UpdatedAt time.Time `bun:"updated_at,notnull"`
Guesses []*Guess `bun:"rel:has-many,join:id=game_id"`
Word *Word `bun:"rel:belongs-to,join:word_id=id"`
}
type User ¶
type User struct {
bun.BaseModel `bun:"table:users"`
Id int64 `bun:"id,pk,autoincrement"`
Name string `bun:"name,notnull"`
Email string `bun:"email,notnull,unique"`
EmailVerifiedAt bun.NullTime `bun:"email_verified_at"`
Password string `bun:"password,notnull"`
CreatedAt time.Time `bun:"created_at,notnull"`
UpdatedAt time.Time `bun:"updated_at,notnull"`
}
func (*User) IsPasswordMatch ¶
Click to show internal directories.
Click to hide internal directories.