Documentation ¶
Index ¶
- func BcryptCheck(password, hash string) bool
- func BcryptHash(password string) string
- func ClearToken(ctx *gin.Context)
- func ConvertLangToLangStr(lang riotmodel.LANG) string
- func ConvertLocStrToLocation(loCode string) riotmodel.LOCATION
- func ConvertLocationToLoHoSTR(loc riotmodel.LOCATION) (loCode, hostURL string)
- func ConvertLocationToRegionHost(loc riotmodel.LOCATION) string
- func ConvertQueToQueSTR(que riotmodel.QUECODE) string
- func ConvertRegionStrToArea(region string) riotmodel.AREA
- func ConvertSliceToStr(s []string) string
- func ConvertStrToSlice(str string) []string
- func ConvertVersionToIdx(version string) (uint, error)
- func GenerateRandomString(n int) string
- func GenerateRandomUA() string
- func GetClaims(ctx *gin.Context) (*request.CustomClaims, error)
- func GetCurMajorVersions() []string
- func GetIDbyIP(ip string) uint32
- func GetLocalIP() (string, error)
- func GetToken(ctx *gin.Context) string
- func GetUserID(ctx *gin.Context) uint
- func GetUserUuid(ctx *gin.Context) uuid.UUID
- func RemoveExtraLF(str string) string
- func RemoveHTMLTags(input string) string
- func SetToken(ctx *gin.Context, token string, maxAge int)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ClearToken ¶
func ConvertLangToLangStr ¶
func ConvertLocStrToLocation ¶
func ConvertQueToQueSTR ¶
func ConvertRegionStrToArea ¶
func ConvertSliceToStr ¶
func ConvertStrToSlice ¶
func ConvertVersionToIdx ¶
ConvertVersionToIdx return a 4 digit str xxyy (1401)
func GenerateRandomString ¶
func GenerateRandomUA ¶
func GenerateRandomUA() string
func GetCurMajorVersions ¶
func GetCurMajorVersions() []string
func GetUserUuid ¶
GetUserUuid 从Gin的Context中获取从jwt解析出来的用户UUID
func RemoveExtraLF ¶
func RemoveHTMLTags ¶
Types ¶
This section is empty.
Source Files ¶
Click to show internal directories.
Click to hide internal directories.