auth

package
v0.0.0-...-b9c356b Latest Latest
Warning

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

Go to latest
Published: May 24, 2024 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAdminID

func GetAdminID(r *ghttp.Request) uint64

GetAdminID 获取管理员ID

func GetAdminName

func GetAdminName(r *ghttp.Request) string

GetAdminName 获取用户名

func GetRoleID

func GetRoleID(r *ghttp.Request) uint64

GetRoleID 获取管理员角色

func GetUserID

func GetUserID(r *ghttp.Request) uint64

GetUserID 获取前端用户ID

func RoleColumnPermission

func RoleColumnPermission(roleID string) (re map[string]interface{}, err error)

RoleColumnPermission 获取会员的列表字段权限

func RoleMenu

func RoleMenu(r *ghttp.Request) (re menu.ListModel)

RoleMenu 角色对应的菜单

func RolePermission

func RolePermission(roleID string) (re []string, err error)

RolePermission 获取权限

func SetUserAuth

func SetUserAuth(r *ghttp.Request, admin *entity.Admin)

SetUserAuth 设置用户权限信息

func ValidateAuth

func ValidateAuth(r *ghttp.Request) (admin *entity.Admin, err error)

ValidateAuth 鉴权

func ValidatePermission

func ValidatePermission(r *ghttp.Request) bool

ValidatePermission 校验权限

func ValidateRefresh

func ValidateRefresh(r *ghttp.Request) (admin *entity.Admin, err error)

ValidateRefresh 校验刷新Token

func ValidateSign

func ValidateSign(r *ghttp.Request) bool

ValidateSign 校验验签

Types

This section is empty.

Jump to

Keyboard shortcuts

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