Documentation ¶
Index ¶
- Variables
- func AliWriteRedis(cloud string, rlist model.AliRedis)
- func CreateToken(claims Claims) (string, error)
- func GenerateToken(Username string, Password string) (string, string, error)
- func GetPage(c *gin.Context) (int, int)
- func RefreshToken(tokenString string) (string, error)
- func ReturnDefaultModel(val string, list map[string]string) string
- func TxWriteRedis(cloud string, rlist model.TxL)
- func VerifyEmailFormat(email string) bool
- type Claims
- type UserInfo
- type UserJWTInfo
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func AliWriteRedis ¶
func RefreshToken ¶
func TxWriteRedis ¶
Types ¶
type Claims ¶
type Claims struct { UserId int `json:"userid"` UserName string `json:"username"` UserType string `json:"usertype"` // UserPhone int64 `json:"UserPhone"` // Password string `json:"Password"` // CreaTime time.Time `json:"CreaTime"` jwt.StandardClaims }
func ParseToken ¶
type UserInfo ¶
type UserInfo struct { Uid int UserName string Identity string // UserPhone int64 AvatarUrl string CreatedAt time.Time }
user info tbale
type UserJWTInfo ¶
user info tbale
func GetUserInfo ¶
func GetUserInfo(tokenString string) (UserJWTInfo, error)
Click to show internal directories.
Click to hide internal directories.