Documentation
¶
Overview ¶
Package member 会员管理
Index ¶
- type Config
- type Module
- func (m *Module) AddSecurityLog(tx *orm.Tx, uid int64, content, ip, ua string) error
- func (m *Module) AddSecurityLogWithContext(tx *orm.Tx, uid int64, ctx *web.Context, content web.LocaleStringer) error
- func (m *Module) CurrentUser(ctx *web.Context) *user.User
- func (m *Module) Middleware(next web.HandlerFunc, method, path, router string) web.HandlerFunc
- func (m *Module) URLPrefix() string
- func (m *Module) UserModule() *user.Module
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// User 用户相关的配置
User *user.Config `json:"user" xml:"user" yaml:"user"`
// 上传接口的相关配置
Upload *upload.Config `json:"upload" xml:"upload" yaml:"upload"`
}
func (*Config) SanitizeConfig ¶
func (c *Config) SanitizeConfig() *web.FieldError
type Module ¶
type Module struct {
// contains filtered or unexported fields
}
Module 不带权限功能的会员管理模块
func (*Module) AddSecurityLog ¶
AddSecurityLog 记录一条安全日志
func (*Module) AddSecurityLogWithContext ¶
func (m *Module) AddSecurityLogWithContext(tx *orm.Tx, uid int64, ctx *web.Context, content web.LocaleStringer) error
AddSecurityLogWithContext 从 web.Context 中记录一条安全日志
func (*Module) CurrentUser ¶
CurrentUser 获取当前登录的用户信息
func (*Module) Middleware ¶
func (m *Module) Middleware(next web.HandlerFunc, method, path, router string) web.HandlerFunc
Middleware 验证是否登录
func (*Module) UserModule ¶
Click to show internal directories.
Click to hide internal directories.