Documentation
¶
Index ¶
- Variables
- func GetAuthToken(r *http.Request) string
- func GetSessionInfo(r *http.Request) auth.SessionInfo
- func GetSessionUserID(r *http.Request) int
- func HasAuthToken(r *http.Request) bool
- func Init(router *httprouter.Router)
- type CalendarEvent
- type CalendarHWEvent
- type CalendarScheduleItem
- type Notification
- type RouteContext
Constants ¶
This section is empty.
Variables ¶
View Source
var DB *sql.DB
View Source
var MainRegistry data.SchoolRegistry
View Source
var RedisClient *redis.Client
View Source
var WebAuthnHandler *webauthn.WebAuthn
Functions ¶
func GetAuthToken ¶
func GetSessionInfo ¶
func GetSessionInfo(r *http.Request) auth.SessionInfo
func GetSessionUserID ¶
func HasAuthToken ¶
Types ¶
type CalendarEvent ¶
type CalendarEvent struct {
ID int `json:"id"`
Name string `json:"name"`
Start int `json:"start"`
End int `json:"end"`
Location string `json:"location"`
Desc string `json:"desc"`
UserID int `json:"userId"`
}
structs for data
type CalendarHWEvent ¶
type CalendarScheduleItem ¶
type CalendarScheduleItem struct {
ID int `json:"id"`
TermID int `json:"termId"`
ClassID int `json:"classId"`
Name string `json:"name"`
OwnerID int `json:"ownerId"`
OwnerName string `json:"ownerName"`
DayNumber int `json:"dayNumber"`
Block string `json:"block"`
BuildingName string `json:"buildingName"`
RoomNumber string `json:"roomNumber"`
Start int `json:"start"`
End int `json:"end"`
UserID int `json:"userId"`
}
type Notification ¶
type RouteContext ¶
A RouteContext contains information relevant to the current route
Click to show internal directories.
Click to hide internal directories.