role

package
v0.0.0-...-57b459a Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2021 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Role

type Role string

Role contains a list of permissions

const (
	Basic Role = "basic"

	SecuritySpecialist Role = "security_specialist"

	ShortLinkViewer Role = "short_link_viewer"
	ShortLinkEditor Role = "short_link_editor"

	ChangeLogViewer Role = "changelog_viewer"
	ChangeLogEditor Role = "changelog_editor"

	Admin Role = "admin"
)

func (Role) HasPermission

func (r Role) HasPermission(permission permission.Permission) bool

HasPermission checks whether a role grants the requested permission.

Jump to

Keyboard shortcuts

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