Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Base ¶
Base defines the web handler module.
func (*Base) Handler ¶
func (w *Base) Handler( tmpl string, dataGetter func(*gin.Context) (interface{}, *Error), ) gin.HandlerFunc
Handler returns a gin handler rendering tmpl with data from dataGetter and 200 status code.
func (*Base) UnAuthHandler ¶
func (w *Base) UnAuthHandler(tmpl string, dataGetter func(*gin.Context) (interface{}, *Error), ) gin.HandlerFunc
UnAuthHandler returns a gin handler rendering tmpl with data from dataGetter and 401 status code.
type Data ¶
type Data struct { Title string BinVersion string Ctx struct { Org, User string LoggedIn bool AuthEnabled bool } }
Data defines the base data.
Click to show internal directories.
Click to hide internal directories.