Documentation ¶
Overview ¶
Package jwtsession
@author: xwc1125
Index ¶
- Variables
- func ExtractClaims(c contextx.Context) jwtauth.MapClaims
- func Get(c contextx.Context, key string) interface{}
- func GetDeptId(c contextx.Context) int
- func GetDeptName(c contextx.Context) string
- func GetRoleId(c contextx.Context) int
- func GetRoleKey(c contextx.Context) string
- func GetRoleName(c contextx.Context) string
- func GetUserId(c contextx.Context) int
- func GetUserIdStr(c contextx.Context) string
- func GetUserName(c contextx.Context) string
Constants ¶
This section is empty.
Variables ¶
View Source
var ( JwtPayloadKey = "JWT_PAYLOAD" UserIDKey = "identity" UserNameKey = "user_name" RoleIDKey = "role_id" RoleKey = "role_key" RoleNameKey = "role_name" DeptIDKey = "dept_id" DeptNameKey = "dept_name" DataScopeKey = "data_scope_key" )
Functions ¶
func ExtractClaims ¶
ExtractClaims 从request中获取jwtauth.MapClaims
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.