ts

package
v0.0.0-...-3930f21 Latest Latest
Warning

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

Go to latest
Published: Jan 25, 2021 License: GPL-3.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const REQUESTOR_MIDDLEWARE_NAME = "Requester-Middleware"

Variables

This section is empty.

Functions

func RequestIDLogMiddleware

func RequestIDLogMiddleware(app *TapeStatsApp) gin.HandlerFunc

Types

type RequestorInstance

type RequestorInstance struct {
	Log       zerolog.Logger
	TS        *TapeStatsApp
	RequestId string
}

func (*RequestorInstance) Data

func (ri *RequestorInstance) Data(overrides ...gin.H) gin.H

func (*RequestorInstance) OurData

func (ri *RequestorInstance) OurData() gin.H

type TapeStatsApp

type TapeStatsApp struct {
	DB  *pg.DB
	Log zerolog.Logger
}

func NewTapeStatsApp

func NewTapeStatsApp(log zerolog.Logger) (*TapeStatsApp, error)

func (*TapeStatsApp) AddRoutes

func (ts *TapeStatsApp) AddRoutes(r *gin.Engine)

func (*TapeStatsApp) Ctxer

func (ts *TapeStatsApp) Ctxer(c *gin.Context) (*RequestorInstance, error)

func (*TapeStatsApp) GetLogGinCtx

func (ts *TapeStatsApp) GetLogGinCtx(c *gin.Context) zerolog.Logger

func (*TapeStatsApp) GetRI

func (ts *TapeStatsApp) GetRI(c *gin.Context) *RequestorInstance

func (*TapeStatsApp) GetSetRI

func (ts *TapeStatsApp) GetSetRI(c *gin.Context) *RequestorInstance

func (*TapeStatsApp) GetTemplateContext

func (ts *TapeStatsApp) GetTemplateContext() template.FuncMap

func (*TapeStatsApp) IndexHandler

func (ts *TapeStatsApp) IndexHandler(c *gin.Context)

func (*TapeStatsApp) LoadRecordHandler

func (ts *TapeStatsApp) LoadRecordHandler(c *gin.Context)

func (*TapeStatsApp) LoadUnparsedHandler

func (ts *TapeStatsApp) LoadUnparsedHandler(c *gin.Context)

func (*TapeStatsApp) MigrationsRun

func (ts *TapeStatsApp) MigrationsRun(args ...string) error

func (*TapeStatsApp) PingHandler

func (ts *TapeStatsApp) PingHandler(c *gin.Context)

func (*TapeStatsApp) RegisterAccountHandler

func (ts *TapeStatsApp) RegisterAccountHandler(c *gin.Context)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳