controllers

package
v0.0.0-...-870068e Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2026 License: AGPL-3.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIHandler

type APIHandler struct {
	DB          *db.Queries
	DBConn      *sql.DB
	AdminAPIKey string
}

APIHandler implements the generated oas.Handler and oas.SecurityHandler.

func (*APIHandler) CreateCinema

func (h *APIHandler) CreateCinema(ctx context.Context, req *oas.CinemaInput) (oas.CreateCinemaRes, error)

CreateCinema implements createCinema operation.

func (*APIHandler) CreateMovieLog

func (h *APIHandler) CreateMovieLog(ctx context.Context, req *oas.MovieLogInput) (oas.CreateMovieLogRes, error)

CreateMovieLog implements createMovieLog operation.

func (*APIHandler) DeleteCinema

func (h *APIHandler) DeleteCinema(ctx context.Context, params oas.DeleteCinemaParams) (oas.DeleteCinemaRes, error)

DeleteCinema implements deleteCinema operation.

func (*APIHandler) DeleteMovieLog

func (h *APIHandler) DeleteMovieLog(ctx context.Context, params oas.DeleteMovieLogParams) (oas.DeleteMovieLogRes, error)

DeleteMovieLog implements deleteMovieLog operation.

func (*APIHandler) GetCinema

func (h *APIHandler) GetCinema(ctx context.Context, params oas.GetCinemaParams) (oas.GetCinemaRes, error)

GetCinema implements getCinema operation.

func (*APIHandler) GetMovieLog

func (h *APIHandler) GetMovieLog(ctx context.Context, params oas.GetMovieLogParams) (oas.GetMovieLogRes, error)

GetMovieLog implements getMovieLog operation.

func (*APIHandler) HandleAdminAPIKey

func (h *APIHandler) HandleAdminAPIKey(ctx context.Context, operationName oas.OperationName, t oas.AdminAPIKey) (context.Context, error)

HandleAdminAPIKey implements oas.SecurityHandler. It checks both Bearer token and the datasite-admin-api-key cookie.

func (*APIHandler) ListCinemas

func (h *APIHandler) ListCinemas(ctx context.Context) (oas.ListCinemasRes, error)

ListCinemas implements listCinemas operation.

func (*APIHandler) ListMovieLogs

func (h *APIHandler) ListMovieLogs(ctx context.Context) (oas.ListMovieLogsRes, error)

ListMovieLogs implements listMovieLogs operation.

func (*APIHandler) NewError

func (h *APIHandler) NewError(ctx context.Context, err error) *oas.InternalErrorStatusCode

NewError implements oas.Handler convenient error handling.

func (*APIHandler) PatchCinema

func (h *APIHandler) PatchCinema(ctx context.Context, req *oas.CinemaPatch, params oas.PatchCinemaParams) (oas.PatchCinemaRes, error)

PatchCinema implements patchCinema operation.

func (*APIHandler) PatchMovieLog

PatchMovieLog implements patchMovieLog operation.

func (*APIHandler) QuerySql

func (h *APIHandler) QuerySql(ctx context.Context, req *oas.QueryRequest) (oas.QuerySqlRes, error)

QuerySql implements querySql operation.

func (*APIHandler) UpdateCinema

func (h *APIHandler) UpdateCinema(ctx context.Context, req *oas.CinemaInput, params oas.UpdateCinemaParams) (oas.UpdateCinemaRes, error)

UpdateCinema implements updateCinema operation.

func (*APIHandler) UpdateMovieLog

UpdateMovieLog implements updateMovieLog operation.

type AdminCinemasController

type AdminCinemasController struct {
	ServerSrc string
	DB        *db.Queries
}

func (*AdminCinemasController) Create

func (c *AdminCinemasController) Create() http.Handler

func (*AdminCinemasController) Delete

func (c *AdminCinemasController) Delete() http.Handler

func (*AdminCinemasController) Get

func (*AdminCinemasController) GetCreate

func (c *AdminCinemasController) GetCreate() http.Handler

func (*AdminCinemasController) List

func (*AdminCinemasController) Post

type AdminDashController

type AdminDashController struct {
	ServerSrc string
	DBConn    *sql.DB
}

func (*AdminDashController) Get

func (c *AdminDashController) Get() http.Handler

type AdminImportController

type AdminImportController struct {
	ServerSrc string
	DB        *db.Queries
	Movies    moviedb.MovieDB
}

func (*AdminImportController) Get

func (*AdminImportController) Post

type AdminMovieLogsController

type AdminMovieLogsController struct {
	ServerSrc string
	DB        *db.Queries
	Movies    moviedb.MovieDB
}

func (*AdminMovieLogsController) Create

func (*AdminMovieLogsController) Delete

func (*AdminMovieLogsController) Get

func (*AdminMovieLogsController) GetCreate

func (c *AdminMovieLogsController) GetCreate() http.Handler

func (*AdminMovieLogsController) List

func (*AdminMovieLogsController) Post

type HomeController

type HomeController struct {
	ServerSrc string
	DB        *db.Queries
	Movies    moviedb.MovieDB
}

func (*HomeController) ServeHTTP

func (c *HomeController) ServeHTTP(w http.ResponseWriter, r *http.Request)

type LoginController

type LoginController struct {
	ServerSrc string
}

func (*LoginController) Get

func (c *LoginController) Get() http.Handler

func (*LoginController) Post

func (c *LoginController) Post() http.Handler

type MovieLogController

type MovieLogController struct {
	ServerSrc string
	DB        *db.Queries
	Movies    moviedb.MovieDB
}

func (*MovieLogController) Get

func (c *MovieLogController) Get() http.Handler

Jump to

Keyboard shortcuts

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