utils

package
v0.1.19 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// PermissionAdmin grants all permissions on a team
	PermissionAdmin = authz.AuthzAction("admin")
	// PermissionSuperAdmin grants all permissions
	PermissionSuperAdmin = authz.AuthzAction("superadmin")
	// PermissionCreate grants the ability to create
	PermissionCreate = authz.AuthzAction("create")
	// PermissionDelete grants the ability to delete
	PermissionDelete = authz.AuthzAction("delete")
	// PermissionEdit grants the ability to edit
	PermissionEdit = authz.AuthzAction("edit")
	// PermissionView grants the ability to read
	PermissionView = authz.AuthzAction("view")
)
View Source
const (
	// RoleAdmin grants all permissions on a team
	RoleAdmin = authz.AuthzAction("Admin")
	// RoleSuperAdmin grants all permissions
	RoleSuperAdmin = authz.AuthzAction("Super Admin")
	// RoleOwner grants all permissions
	RoleOwner = authz.AuthzAction("Owner")
	// Editor grants the ability to edit
	RoleEditor = authz.AuthzAction("Editor")
	// RoleViewer grants the ability to read
	RoleViewer = authz.AuthzAction("Viewer")
)
View Source
const (
	CreateDesignCommentUrlFormat = "/designs/%s/comments"
	CreateDesignUrlFormat        = "/designs/new?template=%s"
	CreateEnvironmentUrlFormat   = "/environments"
	CreateLensUrlFormat          = "/lenses"
	CreateProfileUrlFormat       = "/profiles/new"
	CreateTagUrlFormat           = "/tags/new"
	CreateTemplateUrlFormat      = "/templates/new"
	CreateWorkloadUrlFormat      = "/workloads/new"
	DeleteDesignUrlFormat        = "/designs/%s"
	DeleteEnvironmentUrlFormat   = "/environments/%s"
	DeleteLensUrlFormat          = "/lenses/%s"
	DeleteProfileUrlFormat       = "/profiles/%s"
	DeleteTagUrlFormat           = "/tags/%s"
	DeleteTemplateUrlFormat      = "/templates/%s"
	EditBodyUrlFormat            = "/designs/%s/body/edit"
	EditTitleUrlFormat           = "/designs/%s/title/edit"
	ListTagsUrlFormat            = "/tags"
	ListTemplatesUrlFormat       = "/templates"
	ListWorkflowsUrlFormat       = "/workflows"
	ShowDesigUrlFormat           = "/designs/%s"
	ShowProfileUrlFormat         = "/profiles/%s"
	ShowTemplateUrlFormat        = "/templates/%s"
)

Variables

This section is empty.

Functions

func BoolStr

func BoolStr(b bool) string

BoolStr converts the given bool to a string.

func IntStr

func IntStr(i int) string

IntStr converts the given int to a string.

func PtrStr

func PtrStr(s *string) string

PtrStr returns the value of the given string pointer.

func StrBool

func StrBool(s string) bool

StrBool converts the given string to a bool.

func StrInt

func StrInt(s string) int

StrInt converts the given string to an int.

func StrPtr

func StrPtr(s string) *string

StrPtr returns a pointer to the given string.

Types

This section is empty.

Jump to

Keyboard shortcuts

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