utils

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 26, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateToken

func GenerateToken(id uint) (string, error)

签发用户token

Types

type Claims

type Claims struct {
	Id uint `json:"id"`
	jwt.StandardClaims
}

func ParseToken

func ParseToken(token string) (*Claims, error)

验证用户token

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL