Documentation ¶
Index ¶
- Variables
- func AuthCheck(h echo.Handler) echo.HandlerFunc
- func CustomerDetail(c echo.Context) *modelCustomer.CustomerAndGroup
- func FuncMap() echo.MiddlewareFunc
- func IPFilter() echo.MiddlewareFuncd
- func Inviter(h echo.Handler) echo.HandlerFunc
- func JWT(skippers ...func(echo.Context) bool) echo.MiddlewareFuncd
- func NavigateList(ctx echo.Context, m *dbschema.OfficialCommonNavigate, navType string, ...) []*official.NavigateExt
- func OnlyLocal() echo.MiddlewareFuncd
- func RateLimiter() echo.MiddlewareFunc
- func SessionInfo(h echo.Handler) echo.HandlerFunc
- func SetFunc(ctx echo.Context) error
- func SetTheme(theme string) echo.MiddlewareFuncd
- func SkipCurrentURLPermCheck(h echo.Handler) echo.HandlerFunc
- func TrimPathSuffix(ignorePrefixes ...string) echo.MiddlewareFuncd
- func Use(m ...interface{})
- func UseTheme(fn func(echo.Context) *ntemplate.ThemeInfo) echo.MiddlewareFuncd
- type CurrencyGetter
- type FloatConverter
- type RenderData
- func (r *RenderData) Advert(idents ...string) interface{}
- func (r *RenderData) CaptchaForm(tmpl string, args ...interface{}) template.HTML
- func (r *RenderData) CaptchaFormWithType(typ string, tmpl string, args ...interface{}) template.HTML
- func (r *RenderData) CategoryList(limit int, ctype ...string) []*dbschema.OfficialCommonCategory
- func (r *RenderData) Currency() string
- func (r *RenderData) Customer() *dbschema.OfficialCustomer
- func (r *RenderData) CustomerDetail() *modelCustomer.CustomerAndGroup
- func (r *RenderData) CustomerNav(parentIDs ...uint) []*official.NavigateExt
- func (r *RenderData) Friendlink(limit int, categoryIds ...uint) []*dbschema.OfficialCommonFriendlink
- func (r *RenderData) FrontendNav(parentIDs ...uint) []*official.NavigateExt
- func (r *RenderData) Price(price float64) float64
- func (r *RenderData) PriceFormat(price float64) template.HTML
- func (r *RenderData) SQLQuery() *nsql.SQLQuery
- func (r *RenderData) SQLQueryLimit(offset int, limit int, linkID ...int) *nsql.SQLQuery
- func (r *RenderData) SkipLicenseCheck() bool
- func (r *RenderData) SoftwareName() string
- func (r *RenderData) SoftwareURL() string
- func (r *RenderData) SubCategoryList(parentId int, limit int, ctype ...string) []*dbschema.OfficialCommonCategory
- func (r *RenderData) TagList(group ...string) []*dbschema.OfficialCommonTags
- func (r *RenderData) ThemeInfo() *ntemplate.ThemeInfo
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Customer = sessdata.Customer URLFor = sessdata.URLFor )
View Source
var DefaultRenderDataWrapper = func(ctx echo.Context, data interface{}) interface{} { return NewRenderData(ctx, data) }
View Source
var Middlewares []interface{}
View Source
var TmplFuncGenerator = mwutils.TmplFuncGenerators{ `Currency`: func(ctx echo.Context) interface{} { return func(v float64, withFlags ...bool) interface{} { return xcommon.HTMLCurrency(ctx, v, withFlags...) } }, `CurrencySymbol`: func(ctx echo.Context) interface{} { return func() template.HTML { return xcommon.HTMLCurrencySymbol(ctx) } }, }
Functions ¶
func CustomerDetail ¶
func CustomerDetail(c echo.Context) *modelCustomer.CustomerAndGroup
func FuncMap ¶
func FuncMap() echo.MiddlewareFunc
func IPFilter ¶
func IPFilter() echo.MiddlewareFuncd
func NavigateList ¶
func NavigateList(ctx echo.Context, m *dbschema.OfficialCommonNavigate, navType string, parentIDs ...uint) []*official.NavigateExt
func OnlyLocal ¶
func OnlyLocal() echo.MiddlewareFuncd
func RateLimiter ¶
func RateLimiter() echo.MiddlewareFunc
func SessionInfo ¶
func SessionInfo(h echo.Handler) echo.HandlerFunc
func SkipCurrentURLPermCheck ¶
func SkipCurrentURLPermCheck(h echo.Handler) echo.HandlerFunc
func TrimPathSuffix ¶
func TrimPathSuffix(ignorePrefixes ...string) echo.MiddlewareFuncd
Types ¶
type CurrencyGetter ¶
type CurrencyGetter interface {
Currency() string
}
type FloatConverter ¶
type RenderData ¶
type RenderData struct { *echo.RenderData // contains filtered or unexported fields }
func NewRenderData ¶
func NewRenderData(ctx echo.Context, data interface{}) *RenderData
func (*RenderData) Advert ¶
func (r *RenderData) Advert(idents ...string) interface{}
func (*RenderData) CaptchaForm ¶
func (r *RenderData) CaptchaForm(tmpl string, args ...interface{}) template.HTML
func (*RenderData) CaptchaFormWithType ¶
func (r *RenderData) CaptchaFormWithType(typ string, tmpl string, args ...interface{}) template.HTML
func (*RenderData) CategoryList ¶
func (r *RenderData) CategoryList(limit int, ctype ...string) []*dbschema.OfficialCommonCategory
func (*RenderData) Currency ¶
func (r *RenderData) Currency() string
func (*RenderData) Customer ¶
func (r *RenderData) Customer() *dbschema.OfficialCustomer
func (*RenderData) CustomerDetail ¶
func (r *RenderData) CustomerDetail() *modelCustomer.CustomerAndGroup
func (*RenderData) CustomerNav ¶
func (r *RenderData) CustomerNav(parentIDs ...uint) []*official.NavigateExt
func (*RenderData) Friendlink ¶
func (r *RenderData) Friendlink(limit int, categoryIds ...uint) []*dbschema.OfficialCommonFriendlink
func (*RenderData) FrontendNav ¶
func (r *RenderData) FrontendNav(parentIDs ...uint) []*official.NavigateExt
func (*RenderData) Price ¶
func (r *RenderData) Price(price float64) float64
func (*RenderData) PriceFormat ¶
func (r *RenderData) PriceFormat(price float64) template.HTML
func (*RenderData) SQLQuery ¶
func (r *RenderData) SQLQuery() *nsql.SQLQuery
func (*RenderData) SQLQueryLimit ¶
func (*RenderData) SkipLicenseCheck ¶
func (r *RenderData) SkipLicenseCheck() bool
func (*RenderData) SoftwareName ¶
func (r *RenderData) SoftwareName() string
func (*RenderData) SoftwareURL ¶
func (r *RenderData) SoftwareURL() string
func (*RenderData) SubCategoryList ¶
func (r *RenderData) SubCategoryList(parentId int, limit int, ctype ...string) []*dbschema.OfficialCommonCategory
func (*RenderData) TagList ¶
func (r *RenderData) TagList(group ...string) []*dbschema.OfficialCommonTags
func (*RenderData) ThemeInfo ¶
func (r *RenderData) ThemeInfo() *ntemplate.ThemeInfo
Source Files ¶
Click to show internal directories.
Click to hide internal directories.