DatabaseUserPermissionCheck implements FormDataProviderInterface

Read onlyYes

Determine user permission for action and check them

Table of Contents

Interfaces

FormDataProviderInterface
Interface must be implemented by form data provider classes.

Methods

__construct()  : mixed
addData()  : array<string|int, mixed>
Set userPermissionOnPage to result array and check access rights.
getBackendUser()  : BackendUserAuthentication

Methods

__construct()

public __construct(EventDispatcherInterface $eventDispatcher, TcaSchemaFactory $schemaFactory) : mixed
Parameters
$eventDispatcher : EventDispatcherInterface
$schemaFactory : TcaSchemaFactory

addData()

Set userPermissionOnPage to result array and check access rights.

public addData(array<string|int, mixed> $result) : array<string|int, mixed>

A couple of different exceptions are thrown here:

  • If something weird happens a top level SPL exception is thrown. This indicates a non-recoverable error.
  • If user has no access to whatever should be done, an exception that extends from Form\Exception\AccessDeniedException is thrown. This can be caught by upper level controller code and can be translated to a specific error message that is shown to the user.
Parameters
$result : array<string|int, mixed>

Initialized result array

Tags
throws
AccessDeniedException
Return values
array<string|int, mixed>

Result filled with more data


        
On this page

Search results