router

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 18, 2024 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const AuthCookieName = "Auth"

Variables

This section is empty.

Functions

This section is empty.

Types

type AppRouter

type AppRouter struct {
	App    core.App
	Router *echo.Echo
}

func NewAppRouter

func NewAppRouter(e *core.ServeEvent) *AppRouter

func (*AppRouter) CreateTask

func (ar *AppRouter) CreateTask(c echo.Context) error

func (*AppRouter) GetError

func (ar *AppRouter) GetError(c echo.Context) error

func (*AppRouter) GetHome

func (ar *AppRouter) GetHome(c echo.Context) error

func (*AppRouter) GetLogin

func (ar *AppRouter) GetLogin(c echo.Context) error

GetLogin returns the login page.

func (*AppRouter) ListDelete

func (ar *AppRouter) ListDelete(c echo.Context) error

func (*AppRouter) LoadAuthContextFromCookie

func (ar *AppRouter) LoadAuthContextFromCookie() echo.MiddlewareFunc

func (*AppRouter) Login

func (ar *AppRouter) Login(c echo.Context, identifier string, password string) error

Login handles the login logic.

func (*AppRouter) PostLogin

func (ar *AppRouter) PostLogin(c echo.Context) error

PostLogin handles the form validation and authentication.

func (*AppRouter) PostLogout

func (ar *AppRouter) PostLogout(c echo.Context) error

PostLogout logs the user out by clearing the authentication cookie.

func (*AppRouter) PostRegister

func (ar *AppRouter) PostRegister(c echo.Context) error

func (*AppRouter) Register

func (ar *AppRouter) Register(c echo.Context, email, username, password, passwordRepeat string) error

Register handles the registration of new users.

func (*AppRouter) SetupRoutes

func (ar *AppRouter) SetupRoutes(live bool) error

func (*AppRouter) ToggleArchive

func (ar *AppRouter) ToggleArchive(c echo.Context) error

func (*AppRouter) ToggleTask

func (ar *AppRouter) ToggleTask(c echo.Context) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL