Documentation
¶
Index ¶
- type Application
- func (a *Application) CreateEmailLoginJWT(email string) *jwt.Token
- func (a *Application) CreateSessionJWT(email string) (*jwt.Token, time.Time)
- func (a *Application) GetAdminDietaryRestrictionsTemplate(r *http.Request) map[string]any
- func (a *Application) GetAdminTeamsTemplate(r *http.Request) map[string]any
- func (a *Application) GetArchiveTemplate(*http.Request) map[string]any
- func (a *Application) GetEmailLoginTemplate(r *http.Request) map[string]any
- func (a *Application) GetLoggedInTeacher(r *http.Request) (*database.Teacher, error)
- func (a *Application) GetParentSignFormsTemplate(r *http.Request) map[string]any
- func (a *Application) GetStudentConfirmInfoTemplate(r *http.Request) map[string]any
- func (a *Application) GetTeacherAddMemberTemplate(r *http.Request) map[string]any
- func (a *Application) GetTeacherCreateAccountTemplate(r *http.Request) map[string]any
- func (a *Application) GetTeacherSchoolInfoTemplate(r *http.Request) map[string]any
- func (a *Application) GetTeacherTeamEditTemplate(r *http.Request) map[string]any
- func (a *Application) GetTeacherTeamsTemplate(r *http.Request) map[string]any
- func (a *Application) GetVolunteerScanTemplate(r *http.Request) map[string]any
- func (a *Application) HandleAdminEmailLogin(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleAdminLogin(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleGetParentEmailConfirmationLink(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleGetStudentEmailConfirmationLink(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleKattisParticipantsExport(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleKattisTeamsExport(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleParentSignForms(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleResendParentEmail(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleResendStudentEmail(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleSendCTFdPassword(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleSendEmailConfirmationReminders(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleSendParentReminders(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleSendQRCodes(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleStudentConfirmEmail(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleTeacherAddMember(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleTeacherCreateAccount(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleTeacherDeleteMember(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleTeacherEmailLogin(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleTeacherLogin(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleTeacherLogout(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleTeacherSchoolInfo(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleTeacherTeamEdit(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleVolunteerCheckIn(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleVolunteerEmailLogin(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleVolunteerLogin(w http.ResponseWriter, r *http.Request)
- func (a *Application) HandleZoomBreakoutExport(w http.ResponseWriter, r *http.Request)
- func (a *Application) SendEmail(log zerolog.Logger, subject string, to *mail.Email, ...) error
- func (a *Application) ServeTemplate(logger *zerolog.Logger, templateName string, ...) func(w http.ResponseWriter, r *http.Request)
- func (a *Application) ServeTemplateExtra(logger *zerolog.Logger, templateName string, ...) func(w http.ResponseWriter, r *http.Request, extraData map[string]any)
- func (a *Application) Start()
- type CompetitionResult
- type Issuer
- type Link
- type WinningTeam
- type YearInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Application ¶
type Application struct { Log *zerolog.Logger DB *database.Database EmailRegex *regexp.Regexp Config config.Configuration ConfirmEmailRenderer func(w http.ResponseWriter, r *http.Request, extraData map[string]any) TeacherLoginRenderer func(w http.ResponseWriter, r *http.Request, extraData map[string]any) EmailLoginRenderer func(w http.ResponseWriter, r *http.Request, extraData map[string]any) StudentConfirmInfoRenderer func(w http.ResponseWriter, r *http.Request, extraData map[string]any) TeamAddMemberRenderer func(w http.ResponseWriter, r *http.Request, extraData map[string]any) TeacherCreateAccountRenderer func(w http.ResponseWriter, r *http.Request, extraData map[string]any) SendGridClient *sendgrid.Client }
func NewApplication ¶
func NewApplication(log *zerolog.Logger, db *database.Database) *Application
func (*Application) CreateEmailLoginJWT ¶
func (a *Application) CreateEmailLoginJWT(email string) *jwt.Token
func (*Application) CreateSessionJWT ¶
func (a *Application) CreateSessionJWT(email string) (*jwt.Token, time.Time)
func (*Application) GetAdminDietaryRestrictionsTemplate ¶
func (a *Application) GetAdminDietaryRestrictionsTemplate(r *http.Request) map[string]any
func (*Application) GetAdminTeamsTemplate ¶
func (a *Application) GetAdminTeamsTemplate(r *http.Request) map[string]any
func (*Application) GetArchiveTemplate ¶
func (a *Application) GetArchiveTemplate(*http.Request) map[string]any
func (*Application) GetEmailLoginTemplate ¶
func (a *Application) GetEmailLoginTemplate(r *http.Request) map[string]any
func (*Application) GetLoggedInTeacher ¶
func (*Application) GetParentSignFormsTemplate ¶
func (a *Application) GetParentSignFormsTemplate(r *http.Request) map[string]any
func (*Application) GetStudentConfirmInfoTemplate ¶
func (a *Application) GetStudentConfirmInfoTemplate(r *http.Request) map[string]any
func (*Application) GetTeacherAddMemberTemplate ¶
func (a *Application) GetTeacherAddMemberTemplate(r *http.Request) map[string]any
func (*Application) GetTeacherCreateAccountTemplate ¶
func (a *Application) GetTeacherCreateAccountTemplate(r *http.Request) map[string]any
func (*Application) GetTeacherSchoolInfoTemplate ¶
func (a *Application) GetTeacherSchoolInfoTemplate(r *http.Request) map[string]any
func (*Application) GetTeacherTeamEditTemplate ¶
func (a *Application) GetTeacherTeamEditTemplate(r *http.Request) map[string]any
func (*Application) GetTeacherTeamsTemplate ¶
func (a *Application) GetTeacherTeamsTemplate(r *http.Request) map[string]any
func (*Application) GetVolunteerScanTemplate ¶
func (a *Application) GetVolunteerScanTemplate(r *http.Request) map[string]any
func (*Application) HandleAdminEmailLogin ¶
func (a *Application) HandleAdminEmailLogin(w http.ResponseWriter, r *http.Request)
func (*Application) HandleAdminLogin ¶
func (a *Application) HandleAdminLogin(w http.ResponseWriter, r *http.Request)
func (*Application) HandleGetParentEmailConfirmationLink ¶
func (a *Application) HandleGetParentEmailConfirmationLink(w http.ResponseWriter, r *http.Request)
func (*Application) HandleGetStudentEmailConfirmationLink ¶
func (a *Application) HandleGetStudentEmailConfirmationLink(w http.ResponseWriter, r *http.Request)
func (*Application) HandleKattisParticipantsExport ¶
func (a *Application) HandleKattisParticipantsExport(w http.ResponseWriter, r *http.Request)
func (*Application) HandleKattisTeamsExport ¶
func (a *Application) HandleKattisTeamsExport(w http.ResponseWriter, r *http.Request)
func (*Application) HandleParentSignForms ¶
func (a *Application) HandleParentSignForms(w http.ResponseWriter, r *http.Request)
func (*Application) HandleResendParentEmail ¶
func (a *Application) HandleResendParentEmail(w http.ResponseWriter, r *http.Request)
func (*Application) HandleResendStudentEmail ¶
func (a *Application) HandleResendStudentEmail(w http.ResponseWriter, r *http.Request)
func (*Application) HandleSendCTFdPassword ¶
func (a *Application) HandleSendCTFdPassword(w http.ResponseWriter, r *http.Request)
func (*Application) HandleSendEmailConfirmationReminders ¶
func (a *Application) HandleSendEmailConfirmationReminders(w http.ResponseWriter, r *http.Request)
func (*Application) HandleSendParentReminders ¶
func (a *Application) HandleSendParentReminders(w http.ResponseWriter, r *http.Request)
func (*Application) HandleSendQRCodes ¶
func (a *Application) HandleSendQRCodes(w http.ResponseWriter, r *http.Request)
func (*Application) HandleStudentConfirmEmail ¶
func (a *Application) HandleStudentConfirmEmail(w http.ResponseWriter, r *http.Request)
func (*Application) HandleTeacherAddMember ¶
func (a *Application) HandleTeacherAddMember(w http.ResponseWriter, r *http.Request)
func (*Application) HandleTeacherCreateAccount ¶
func (a *Application) HandleTeacherCreateAccount(w http.ResponseWriter, r *http.Request)
func (*Application) HandleTeacherDeleteMember ¶
func (a *Application) HandleTeacherDeleteMember(w http.ResponseWriter, r *http.Request)
func (*Application) HandleTeacherEmailLogin ¶
func (a *Application) HandleTeacherEmailLogin(w http.ResponseWriter, r *http.Request)
func (*Application) HandleTeacherLogin ¶
func (a *Application) HandleTeacherLogin(w http.ResponseWriter, r *http.Request)
func (*Application) HandleTeacherLogout ¶
func (a *Application) HandleTeacherLogout(w http.ResponseWriter, r *http.Request)
func (*Application) HandleTeacherSchoolInfo ¶
func (a *Application) HandleTeacherSchoolInfo(w http.ResponseWriter, r *http.Request)
func (*Application) HandleTeacherTeamEdit ¶
func (a *Application) HandleTeacherTeamEdit(w http.ResponseWriter, r *http.Request)
func (*Application) HandleVolunteerCheckIn ¶
func (a *Application) HandleVolunteerCheckIn(w http.ResponseWriter, r *http.Request)
func (*Application) HandleVolunteerEmailLogin ¶
func (a *Application) HandleVolunteerEmailLogin(w http.ResponseWriter, r *http.Request)
func (*Application) HandleVolunteerLogin ¶
func (a *Application) HandleVolunteerLogin(w http.ResponseWriter, r *http.Request)
func (*Application) HandleZoomBreakoutExport ¶
func (a *Application) HandleZoomBreakoutExport(w http.ResponseWriter, r *http.Request)
func (*Application) ServeTemplate ¶
func (*Application) ServeTemplateExtra ¶
func (*Application) Start ¶
func (a *Application) Start()
type CompetitionResult ¶
type CompetitionResult struct { Name string Shortname string Teams []WinningTeam }
type Issuer ¶
type Issuer string
const ( IssuerEmailLogin Issuer = "email_login" IssuerSessionToken Issuer = "session_token" IssuerStudentVerify Issuer = "student_verify" IssuerSignForms Issuer = "sign_forms" IssuerAdminLogin Issuer = "admin_login" IssuerStudentQRCode Issuer = "student_qrcode" IssuerVolunteerLogin Issuer = "volunteer_login" )
type WinningTeam ¶
Source Files
¶
Click to show internal directories.
Click to hide internal directories.