context

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TokenContextKey = "token-context"
)

Variables

This section is empty.

Functions

func GetTokenFromContext added in v1.0.1

func GetTokenFromContext(ginContext *gin.Context) (string, bool)

func GetUserAssignedGroups

func GetUserAssignedGroups(ginContext *gin.Context) []string

func GetUserFromContext

func GetUserFromContext(ginContext *gin.Context) (models.User, bool)

func SetContext

func SetContext(ginContext *gin.Context, user models.User) error

func SetTokenContext added in v1.0.1

func SetTokenContext(ginContext *gin.Context, token string) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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