api/internal/provider/auth/model.go

22 lines
550 B
Go
Raw Normal View History

2025-07-07 17:45:58 +03:00
package auth
import (
"database/sql"
"time"
)
2025-09-09 23:17:41 +03:00
type Session struct {
2025-09-09 00:00:11 +03:00
Id uint `gorm:"primary_key"`
CreatedAt time.Time `gorm:"column:created_at"`
UpdatedAt sql.NullTime `gorm:"column:updated_at"`
DeletedAt sql.NullTime `gorm:"column:deleted_at"`
UserUuid string `gorm:"column:user_uuid"`
RefreshUuid string `gorm:"column:refresh_uuid"`
SessionUuid string `gorm:"column:session_uuid"`
Expires time.Time `gorm:"column:expires"`
2025-07-07 17:45:58 +03:00
}
2025-09-09 23:17:41 +03:00
func (Session) TableName() string {
return "sessions"
}