Permissions
extends DefaultHandler
in package
Table of Contents
- EVENT_REGISTER_TARGETS = 'register-targets'
- $data : mixed
- $fancyValue : mixed
- $value : mixed
- $_dirty : array<string|int, mixed>
- getDbValue() : array<string|int, mixed>
- getDirty() : array<string|int, mixed>
- getTargets() : array<string|int, mixed>
- Get the targets this field handler applies to, can be modified through an event
- getTemplate() : string|null
- hasFancyValue() : bool
- isDirty() : bool
- _getTargets() : array<string|int, mixed>
- buildDirty() : array<string|int, mixed>
- Build dirty values
- findPermission() : array<string|int, mixed>|null
- Find a permission and its section
- findPermissionLabel() : string|null
- Find a permission label
- labelledPermissions() : array<string|int, mixed>
- Get permissions section + label for an array of permission handles
Constants
EVENT_REGISTER_TARGETS
public
mixed
EVENT_REGISTER_TARGETS
= 'register-targets'
Properties
$data
public
mixed
$data
Tags
$fancyValue
public
mixed
$fancyValue
$value
public
mixed
$value
$_dirty
protected
array<string|int, mixed>
$_dirty
Methods
getDbValue()
public
getDbValue(string $valueKey) : array<string|int, mixed>
Parameters
- $valueKey : string
Tags
Return values
array<string|int, mixed> —getDirty()
public
getDirty(FieldHandler $handler) : array<string|int, mixed>
Parameters
- $handler : FieldHandler
Tags
Return values
array<string|int, mixed> —getTargets()
Get the targets this field handler applies to, can be modified through an event
public
static getTargets() : array<string|int, mixed>
Return values
array<string|int, mixed> —getTemplate()
public
static getTemplate() : string|null
Tags
Return values
string|null —hasFancyValue()
public
hasFancyValue() : bool
Tags
Return values
bool —isDirty()
public
isDirty(FieldHandler $handler) : bool
Parameters
- $handler : FieldHandler
Tags
Return values
bool —_getTargets()
protected
static _getTargets() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed> —buildDirty()
Build dirty values
protected
buildDirty(array<string|int, mixed> $newPerms, array<string|int, mixed> $oldPerms) : array<string|int, mixed>
Parameters
- $newPerms : array<string|int, mixed>
- $oldPerms : array<string|int, mixed>
Return values
array<string|int, mixed> —findPermission()
Find a permission and its section
protected
findPermission(string $perm) : array<string|int, mixed>|null
Parameters
- $perm : string
Return values
array<string|int, mixed>|null —findPermissionLabel()
Find a permission label
protected
findPermissionLabel(string $perm, array<string|int, mixed> $perms) : string|null
Parameters
- $perm : string
- $perms : array<string|int, mixed>
Return values
string|null —labelledPermissions()
Get permissions section + label for an array of permission handles
protected
labelledPermissions(array<string|int, mixed> $perms) : array<string|int, mixed>
Parameters
- $perms : array<string|int, mixed>