29 $controller=\get_class($this);
31 if (isset ( $resourceController )) {
33 if (
AclManager::isAllowed ( $role, $resourceController [
'resource'], $resourceController [
'permission'] )) {
38 Logger::alert(
'Router', $role.
' is not allowed for this resource',
'Acls',[$controller,$action]);
Ubiquity\exceptions$AclException This class is part of Ubiquity.
Abstract class for logging Ubiquity\log$Logger This class is part of Ubiquity.
static alert($context, $message, $part=null, $extra=null)
Ubiquity\security\acl$AclManager This class is part of Ubiquity.
static isAllowed(string $role, ?string $resource=' *', ?string $permission='ALL')
Check if access to resource is allowed for role with the permission.
static getPermissionMap()
To use with a controller with acls.
isValidRole($action, $role)
Returns True if access to the controller is allowed for $role.
isValid($action)
Returns True if access to the controller is allowed for the role returned by _getRole method.