Add the initial project blueprint, Go backend skeleton, frontend app shell, database schema draft, and local development/deployment files.
24 lines
433 B
Go
24 lines
433 B
Go
package auth
|
|
|
|
import "time"
|
|
|
|
type User struct {
|
|
ID string `json:"id"`
|
|
Username string `json:"username"`
|
|
IsAdmin bool `json:"isAdmin"`
|
|
CreatedAt time.Time `json:"createdAt"`
|
|
LastLoginAt time.Time `json:"lastLoginAt"`
|
|
}
|
|
|
|
func DemoUser() User {
|
|
now := time.Now().UTC()
|
|
return User{
|
|
ID: "user-demo",
|
|
Username: "demo",
|
|
IsAdmin: true,
|
|
CreatedAt: now,
|
|
LastLoginAt: now,
|
|
}
|
|
}
|
|
|