Files
Blizzard bffdb3858b
Checks / verify (push) Failing after 2m37s
feat: 基础框架搭建完毕
2026-10-07 09:27:47 +08:00

28 lines
704 B
Go

package model
import (
"time"
)
type Credential struct {
ID string `db:"id"`
UserID string `db:"user_id"`
LoginName string `db:"login_name"`
PasswordHash string `db:"password_hash" json:"-"`
CreatedAt time.Time `db:"created_at"`
}
func (Credential) TableName() string { return "veyra_credential" }
type Session struct {
ID string `db:"id"`
UserID string `db:"user_id"`
TokenHash string `db:"token_hash" json:"-"`
Audience string `db:"audience"`
ExpiresAt time.Time `db:"expires_at"`
RevokedAt *time.Time `db:"revoked_at"`
CreatedAt time.Time `db:"created_at"`
}
func (Session) TableName() string { return "veyra_session" }