Documentation
¶
Index ¶
- Constants
- func Auth() func(c *gin.Context)
- func Cors() gin.HandlerFunc
- func ErrLogMsg(c *gin.Context) []zap.Field
- func GetToken(header http.Header) (string, errcode.Err)
- func GetTokenContent(c *gin.Context) (*model.Content, bool)
- func GinLogger() gin.HandlerFunc
- func LogBody() gin.HandlerFunc
- func MustAccount() gin.HandlerFunc
- func MustUser() gin.HandlerFunc
- func ParseHeader(accessToken string) (*token.Payload, string, errcode.Err)
- func Recovery(stack bool) gin.HandlerFunc
Constants ¶
View Source
const Body = "body"
Variables ¶
This section is empty.
Functions ¶
func GetTokenContent ¶
GetTokenContent 从当前上下文中获取保存的content内容
func ParseHeader ¶
ParseHeader 获取并解析header中token 返回 payload,token,err
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.