PermissionsManager
class PermissionsManager
Class PermissionsManager manages updating permissions, removing and additional admin functions
Properties
| array | $errors | Errors are kept in an array and can be used later if validation fails and we want to know why | |
| string | $message | This is a message that we can store why the validation failed | |
| $messages | Validation messages |
Methods
Construct a new permission manager
Create rules for a new permission
Create rules to edit a permission
Validates and updates a permission with the given input
Validates and updates a permission with the given input
Destroys a permission by retrieving current config contents and unsetting the key (condition) then saving the updated contents
Details
at line 43
__construct(FileManager $ConfigFileManager, Framework $Framework)
Construct a new permission manager
at line 68
array
createRules()
Create rules for a new permission
at line 80
array
updateRules()
Create rules to edit a permission
at line 93
bool
storePermission(array $input)
Validates and updates a permission with the given input
at line 126
bool
updatePermission($input)
Validates and updates a permission with the given input
at line 163
boolean
destroyPermission(string $condition)
Destroys a permission by retrieving current config contents and unsetting the key (condition) then saving the updated contents