DatabaseUserPermissionCheck

readonly class \TYPO3\CMS\Backend\Form\FormDataProvider\DatabaseUserPermissionCheck

Implements
FormDataProviderInterface

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
Set userPermissionOnPage to result array and check access rights.
getBackendUser()  : BackendUserAuthentication

Methods

__construct()

public __construct(EventDispatcherInterface $eventDispatcher) : mixed

Parameters

$eventDispatcher : EventDispatcherInterface

addData()

Set userPermissionOnPage to result array and check access rights.

public addData(array $result) : array

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

Initialized result array

Tags

throws
AccessDeniedException

Return values

array —

Result filled with more data

On this page