‪TYPO3CMS  ‪main
PermissionController.php
Go to the documentation of this file.
1 <?php
2 
3 declare(strict_types=1);
4 
5 /*
6  * This file is part of the TYPO3 CMS project.
7  *
8  * It is free software; you can redistribute it and/or modify it under
9  * the terms of the GNU General Public License, either version 2
10  * of the License, or any later version.
11  *
12  * For the full copyright and license information, please read the
13  * LICENSE.txt file that was distributed with this source code.
14  *
15  * The TYPO3 project - inspiring people to share!
16  */
17 
19 
20 use Psr\Http\Message\ResponseFactoryInterface;
21 use Psr\Http\Message\ResponseInterface;
22 use Psr\Http\Message\ServerRequestInterface;
31 use TYPO3\CMS\Backend\Utility\BackendUtility;
36 use TYPO3\CMS\Core\Imaging\IconSize;
43 
51 #[AsController]
53 {
54  private const ‪SESSION_PREFIX = 'tx_Beuser_';
55  private const ‪DEPTH_LEVELS = [1, 2, 3, 4, 10];
56  private const ‪RECURSIVE_LEVELS = 10;
57 
58  protected int ‪$id = 0;
59  protected string ‪$returnUrl = '';
60  protected int ‪$depth;
61  protected array ‪$pageInfo = [];
62 
63  public function ‪__construct(
64  protected readonly ‪ModuleTemplateFactory $moduleTemplateFactory,
65  protected readonly ‪PageRenderer $pageRenderer,
66  protected readonly ‪IconFactory $iconFactory,
67  protected readonly ‪UriBuilder $uriBuilder,
68  protected readonly ResponseFactoryInterface $responseFactory,
69  protected readonly ‪BackendViewFactory $backendViewFactory,
70  ) {}
71 
72  public function ‪handleRequest(ServerRequestInterface $request): ResponseInterface
73  {
74  $parsedBody = $request->getParsedBody();
75  $queryParams = $request->getQueryParams();
76  $backendUser = $this->‪getBackendUser();
77  $lang = $this->‪getLanguageService();
78 
79  // determine depth parameter
80  $this->depth = (int)($parsedBody['depth'] ?? $queryParams['depth'] ?? 0);
81  if (!$this->depth) {
82  $this->depth = (int)$backendUser->getSessionData(self::SESSION_PREFIX . 'depth');
83  } else {
84  $backendUser->setAndSaveSessionData(self::SESSION_PREFIX . 'depth', $this->depth);
85  }
86 
87  // determine id parameter
88  $this->id = (int)($parsedBody['id'] ?? $queryParams['id'] ?? 0);
89  $pageRecord = BackendUtility::getRecord('pages', $this->id);
90  // Check if a page with the given id exists, otherwise fall back
91  if ($pageRecord === null) {
92  $this->id = 0;
93  }
94 
95  $this->returnUrl = GeneralUtility::sanitizeLocalUrl((string)($parsedBody['returnUrl'] ?? $queryParams['returnUrl'] ?? ''));
96  $this->pageInfo = BackendUtility::readPageAccess($this->id, ' 1=1') ?: [
97  'title' => ‪$GLOBALS['TYPO3_CONF_VARS']['SYS']['sitename'],
98  'uid' => 0,
99  'pid' => 0,
100  ];
101 
102  $action = (string)($parsedBody['action'] ?? $queryParams['action'] ?? 'index');
103 
104  if ($action === 'update') {
105  // Update returns a redirect. No further fiddling with view here, return directly.
106  return $this->‪updateAction($request);
107  }
108 
109  $view = $this->moduleTemplateFactory->create($request);
110  if ($backendUser->workspace !== 0) {
111  $this->‪addFlashMessage(
112  $lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:WorkspaceWarningText'),
113  $lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:WorkspaceWarning'),
114  ContextualFeedbackSeverity::WARNING
115  );
116  }
117  $this->‪registerDocHeaderButtons($view, $action);
118  $view->setTitle(
119  $this->‪getLanguageService()->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:mlang_tabs_tab'),
120  $this->id !== 0 && !empty($this->pageInfo['title']) ? $this->pageInfo['title'] : ''
121  );
122  $view->getDocHeaderComponent()->setMetaInformation($this->pageInfo);
123 
124  if ($action === 'edit') {
125  return $this->‪editAction($view, $request);
126  }
127  return $this->‪indexAction($view, $request);
128  }
129 
130  public function ‪handleAjaxRequest(ServerRequestInterface $request): ResponseInterface
131  {
132  $parsedBody = $request->getParsedBody();
133  $conf = [
134  'page' => $parsedBody['page'] ?? null,
135  'who' => $parsedBody['who'] ?? null,
136  'mode' => $parsedBody['mode'] ?? null,
137  'bits' => (int)($parsedBody['bits'] ?? 0),
138  'permissions' => (int)($parsedBody['permissions'] ?? 0),
139  'action' => $parsedBody['action'] ?? null,
140  'ownerUid' => (int)($parsedBody['ownerUid'] ?? 0),
141  'username' => $parsedBody['username'] ?? null,
142  'groupUid' => (int)($parsedBody['groupUid'] ?? 0),
143  'groupname' => $parsedBody['groupname'] ?? '',
144  'editLockState' => (int)($parsedBody['editLockState'] ?? 0),
145  'new_owner_uid' => (int)($parsedBody['newOwnerUid'] ?? 0),
146  'new_group_uid' => (int)($parsedBody['newGroupUid'] ?? 0),
147  ];
148 
149  // Basic test for required value
150  if ($conf['page'] <= 0) {
151  return $this->‪htmlResponse('This script cannot be called directly', 500);
152  }
153 
154  // Initialize view and always assign current page id
155  $view = $this->backendViewFactory->create($request);
156  $view->assign('pageId', $conf['page']);
157 
158  // Initialize TCE for execution of updates
159  $tce = GeneralUtility::makeInstance(DataHandler::class);
160  // Determine the action to execute
161  switch ($conf['action'] ?? '') {
162  case 'show_change_owner_selector':
163  $template = 'Permission/ChangeOwnerSelector';
164  $users = BackendUtility::getUserNames();
165  $view->assignMultiple([
166  'elementId' => 'o_' . $conf['page'],
167  'ownerUid' => $conf['ownerUid'],
168  'username' => $conf['username'],
169  'users' => $users,
170  'addCurrentUser' => !isset($users[$conf['ownerUid']]),
171  ]);
172  break;
173  case 'show_change_group_selector':
174  $template = 'Permission/ChangeGroupSelector';
175  $groups = BackendUtility::getGroupNames();
176  $view->assignMultiple([
177  'elementId' => 'g_' . $conf['page'],
178  'groupUid' => $conf['groupUid'],
179  'groupname' => $conf['groupname'],
180  'groups' => $groups,
181  'addCurrentGroup' => !isset($groups[$conf['groupUid']]),
182  ]);
183  break;
184  case 'toggle_edit_lock':
185  // Initialize requested lock state
186  $editLockState = $conf['editLockState'] ? 0 : 1;
187 
188  // Execute TCE Update
189  $tce->start([
190  'pages' => [
191  $conf['page'] => [
192  'editlock' => $editLockState,
193  ],
194  ],
195  ], []);
196  $tce->process_datamap();
197 
198  // Setup view
199  $template = 'Permission/ToggleEditLock';
200  $view->assignMultiple([
201  'elementId' => 'el_' . $conf['page'],
202  'editLockState' => $editLockState,
203  ]);
204  break;
205  case 'change_owner':
206  // Check if new owner uid is given (also accept 0 => [not set])
207  if ($conf['new_owner_uid'] < 0) {
208  return $this->‪htmlResponse('An error occurred: No page owner uid specified', 500);
209  }
210 
211  // Execute TCE Update
212  $tce->start([
213  'pages' => [
214  $conf['page'] => [
215  'perms_userid' => $conf['new_owner_uid'],
216  ],
217  ],
218  ], []);
219  $tce->process_datamap();
220 
221  // Setup and render view
222  $template = 'Permission/ChangeOwner';
223  $view->assignMultiple([
224  'userId' => $conf['new_owner_uid'],
225  'username' => BackendUtility::getUserNames(
226  'username',
227  ' AND uid = ' . $conf['new_owner_uid']
228  )[$conf['new_owner_uid']]['username'] ?? '',
229  ]);
230  break;
231  case 'change_group':
232  // Check if new group uid is given (also accept 0 => [not set])
233  if ($conf['new_group_uid'] < 0) {
234  return $this->‪htmlResponse('An error occurred: No page group uid specified', 500);
235  }
236 
237  // Execute TCE Update
238  $tce->start([
239  'pages' => [
240  $conf['page'] => [
241  'perms_groupid' => $conf['new_group_uid'],
242  ],
243  ],
244  ], []);
245  $tce->process_datamap();
246 
247  // Setup and render view
248  $template = 'Permission/ChangeGroup';
249  $view->assignMultiple([
250  'groupId' => $conf['new_group_uid'],
251  'groupname' => BackendUtility::getGroupNames(
252  'title',
253  ' AND uid = ' . $conf['new_group_uid']
254  )[$conf['new_group_uid']]['title'] ?? '',
255  ]);
256  break;
257  default:
258  // Initialize permissions state
259  if ($conf['mode'] === 'delete') {
260  $conf['permissions'] -= $conf['bits'];
261  } else {
262  $conf['permissions'] += $conf['bits'];
263  }
264 
265  // Execute TCE Update
266  $tce->start([
267  'pages' => [
268  $conf['page'] => [
269  'perms_' . $conf['who'] => $conf['permissions'],
270  ],
271  ],
272  ], []);
273  $tce->process_datamap();
274 
275  // Setup and render view
276  $template = 'Permission/ChangePermission';
277  $view->assignMultiple([
278  'permission' => $conf['permissions'],
279  'scope' => $conf['who'],
280  ]);
281  }
282 
283  return $this->‪htmlResponse($view->render($template));
284  }
285 
286  public function ‪indexAction(‪ModuleTemplate $view, ServerRequestInterface $request): ResponseInterface
287  {
288  $view->‪assignMultiple([
289  'currentId' => $this->id,
290  'viewTree' => $this->‪getTree(),
291  'beUsers' => BackendUtility::getUserNames(),
292  'beGroups' => BackendUtility::getGroupNames(),
293  'depth' => $this->depth,
294  'depthBaseUrl' => $this->uriBuilder->buildUriFromRoute('permissions_pages', [
295  'id' => $this->id,
296  'depth' => '${value}',
297  'action' => 'index',
298  ]),
299  'returnUrl' => (string)$this->uriBuilder->buildUriFromRoute('permissions_pages', [
300  'id' => $this->id,
301  'depth' => $this->depth,
302  'action' => 'index',
303  ]),
304  ]);
305 
306  return $view->‪renderResponse('Permission/Index');
307  }
308 
309  public function ‪editAction(‪ModuleTemplate $view, ServerRequestInterface $request): ResponseInterface
310  {
311  $lang = $this->‪getLanguageService();
312  $selectNone = $lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:selectNone');
313  $selectUnchanged = $lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:selectUnchanged');
314 
315  // Owner selector
316  $beUserDataArray = [0 => $selectNone];
317  foreach (BackendUtility::getUserNames() as ‪$uid => $row) {
318  $beUserDataArray[‪$uid] = $row['username'] ?? '';
319  }
320  $beUserDataArray[-1] = $selectUnchanged;
321 
322  // Group selector
323  $beGroupDataArray = [0 => $selectNone];
324  foreach (BackendUtility::getGroupNames() as ‪$uid => $row) {
325  $beGroupDataArray[‪$uid] = $row['title'] ?? '';
326  }
327  $beGroupDataArray[-1] = $selectUnchanged;
328 
329  $view->‪assignMultiple([
330  'id' => $this->id,
331  'depth' => $this->depth,
332  'currentBeUser' => $this->pageInfo['perms_userid'] ?? 0,
333  'beUserData' => $beUserDataArray,
334  'currentBeGroup' => $this->pageInfo['perms_groupid'] ?? 0,
335  'beGroupData' => $beGroupDataArray,
336  'pageInfo' => $this->pageInfo,
337  'returnUrl' => $this->returnUrl,
338  'recursiveSelectOptions' => $this->‪getRecursiveSelectOptions(),
339  'formAction' => (string)$this->uriBuilder->buildUriFromRoute('permissions_pages', [
340  'action' => 'update',
341  'id' => $this->id,
342  'depth' => $this->depth,
343  'returnUrl' => $this->returnUrl,
344  ]),
345  ]);
346 
347  return $view->‪renderResponse('Permission/Edit');
348  }
349 
350  protected function ‪updateAction(ServerRequestInterface $request): ResponseInterface
351  {
352  $data = (array)($request->getParsedBody()['data'] ?? []);
353  $mirror = (array)($request->getParsedBody()['mirror'] ?? []);
354 
355  $dataHandlerInput = [];
356  // Prepare the input data for data handler
357  $dataPages = $data['pages'] ?? null;
358  if (is_array($dataPages) && $dataPages !== []) {
359  foreach ($dataPages as $pageUid => $properties) {
360  // if the owner and group field shouldn't be touched, unset the option
361  if ((int)($properties['perms_userid'] ?? 0) === -1) {
362  unset($properties['perms_userid']);
363  }
364  if ((int)($properties['perms_groupid'] ?? 0) === -1) {
365  unset($properties['perms_groupid']);
366  }
367  $dataHandlerInput[$pageUid] = $properties;
368  if (!empty($mirror['pages'][$pageUid])) {
369  $mirrorPages = ‪GeneralUtility::intExplode(',', (string)$mirror['pages'][$pageUid]);
370  foreach ($mirrorPages as $mirrorPageUid) {
371  $dataHandlerInput[$mirrorPageUid] = $properties;
372  }
373  }
374  }
375  }
376 
377  $dataHandler = GeneralUtility::makeInstance(DataHandler::class);
378  $dataHandler->start(
379  [
380  'pages' => $dataHandlerInput,
381  ],
382  []
383  );
384  $dataHandler->process_datamap();
385 
386  return $this->responseFactory->createResponse(303)
387  ->withHeader('location', $this->returnUrl);
388  }
389 
390  protected function ‪registerDocHeaderButtons(‪ModuleTemplate $view, string $action): void
391  {
392  $buttonBar = $view->‪getDocHeaderComponent()->getButtonBar();
393  $lang = $this->‪getLanguageService();
394 
395  if ($action === 'edit') {
396  // CLOSE button:
397  if ($this->returnUrl !== '') {
398  $closeButton = $buttonBar->makeLinkButton()
399  ->setHref($this->returnUrl)
400  ->setTitle($lang->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:rm.closeDoc'))
401  ->setShowLabelText(true)
402  ->setIcon($this->iconFactory->getIcon('actions-close', IconSize::SMALL));
403  $buttonBar->addButton($closeButton);
404  }
405 
406  // SAVE button:
407  $saveButton = $buttonBar->makeInputButton()
408  ->setName('_save')
409  ->setValue('1')
410  ->setForm('PermissionControllerEdit')
411  ->setTitle($lang->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:rm.saveCloseDoc'))
412  ->setShowLabelText(true)
413  ->setIcon($this->iconFactory->getIcon('actions-document-save', IconSize::SMALL));
414  $buttonBar->addButton($saveButton, ‪ButtonBar::BUTTON_POSITION_LEFT, 2);
415  }
416 
417  if ($action === 'index' && count($this->‪getDepthOptions()) > 0) {
418  $viewModeItems = [];
419  $viewModeItems[] = GeneralUtility::makeInstance(DropDownHeader::class)
420  ->setLabel($lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:Depth'));
421  foreach ($this->‪getDepthOptions() as $value => $label) {
422  $viewModeItems[] = GeneralUtility::makeInstance(DropDownRadio::class)
423  ->setActive($this->depth === $value)
424  ->setLabel($label)
425  ->setHref((string)$this->uriBuilder->buildUriFromRoute('permissions_pages', [
426  'id' => $this->id,
427  'depth' => $value,
428  ]));
429  }
430  $viewModeButton = $buttonBar->makeDropDownButton()
431  ->setLabel($lang->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.view'))
432  ->setShowLabelText(true);
433  foreach ($viewModeItems as $viewModeItem) {
434  $viewModeButton->addItem($viewModeItem);
435  }
436  $buttonBar->addButton($viewModeButton, ‪ButtonBar::BUTTON_POSITION_RIGHT, 2);
437  }
438 
439  $shortcutButton = $buttonBar->makeShortcutButton()
440  ->setRouteIdentifier('permissions_pages')
441  ->setDisplayName($this->‪getShortcutTitle())
442  ->setArguments(['id' => $this->id, 'action' => $action]);
443  $buttonBar->addButton($shortcutButton);
444  }
445 
446  protected function ‪getTree(): array
447  {
448  $tree = GeneralUtility::makeInstance(PageTreeView::class);
449  $tree->init();
450  $tree->addField('perms_user', true);
451  $tree->addField('perms_group', true);
452  $tree->addField('perms_everybody', true);
453  $tree->addField('perms_userid', true);
454  $tree->addField('perms_groupid', true);
455  $tree->addField('hidden');
456  $tree->addField('fe_group');
457  $tree->addField('starttime');
458  $tree->addField('endtime');
459  $tree->addField('editlock');
460 
461  // Create the tree from $this->id
462  if ($this->id) {
463  $icon = $this->iconFactory->getIconForRecord('pages', $this->pageInfo, IconSize::SMALL);
464  } else {
465  $icon = $this->iconFactory->getIcon('apps-pagetree-root', IconSize::SMALL);
466  }
467  $iconMarkup = '<span title="' . BackendUtility::getRecordIconAltText($this->pageInfo, 'pages') . '">' . $icon->render() . '</span>';
468  $tree->tree[] = ['row' => ‪$this->pageInfo, 'HTML' => '', 'icon' => $iconMarkup];
469  $tree->getTree($this->id, $this->depth);
470 
471  return $tree->tree;
472  }
473 
474  protected function ‪getDepthOptions(): array
475  {
476  $depthOptions = [];
477  foreach (self::DEPTH_LEVELS as $depthLevel) {
478  $levelLabel = $depthLevel === 1 ? 'level' : 'levels';
479  $depthOptions[$depthLevel] = $depthLevel . ' ' . $this->‪getLanguageService()->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:' . $levelLabel);
480  }
481  return $depthOptions;
482  }
483 
487  protected function ‪getRecursiveSelectOptions(): array
488  {
489  $lang = $this->‪getLanguageService();
490  // Initialize tree object:
491  $tree = GeneralUtility::makeInstance(PageTreeView::class);
492  $tree->init();
493  $tree->addField('perms_userid', true);
494  $tree->makeHTML = 0;
495  // Make tree:
496  $tree->getTree($this->id, self::RECURSIVE_LEVELS);
497  $options = [
498  '' => $lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:selectNone'),
499  ];
500  // If there are a hierarchy of page ids, then...
501  if (!empty($tree->orig_ids_hierarchy) && ($this->getBackendUser()->user['uid'] ?? false)) {
502  // Init:
503  $labelRecursive = $lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:recursive');
504  $labelLevel = $lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:level');
505  $labelLevels = $lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:levels');
506  $labelPageAffected = $lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:page_affected');
507  $labelPagesAffected = $lang->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod_permission.xlf:pages_affected');
508  $theIdListArr = [];
509  // Traverse the number of levels we want to allow recursive
510  // setting of permissions for:
511  for ($a = self::RECURSIVE_LEVELS; $a > 0; $a--) {
512  if (is_array($tree->orig_ids_hierarchy[$a] ?? false)) {
513  foreach ($tree->orig_ids_hierarchy[$a] as $theId) {
514  $theIdListArr[] = $theId;
515  }
516  $lKey = self::RECURSIVE_LEVELS - $a + 1;
517  $pagesCount = count($theIdListArr);
518  $options[implode(',', $theIdListArr)] = $labelRecursive . ' ' . $lKey . ' ' . ($lKey === 1 ? $labelLevel : $labelLevels) .
519  ' (' . $pagesCount . ' ' . ($pagesCount === 1 ? $labelPageAffected : $labelPagesAffected) . ')';
520  }
521  }
522  }
523  return $options;
524  }
525 
529  protected function ‪addFlashMessage(string $message, string $title = '', ‪ContextualFeedbackSeverity $severity = ContextualFeedbackSeverity::INFO): void
530  {
531  $flashMessage = GeneralUtility::makeInstance(FlashMessage::class, $message, $title, $severity, true);
532  $flashMessageService = GeneralUtility::makeInstance(FlashMessageService::class);
533  $defaultFlashMessageQueue = $flashMessageService->getMessageQueueByIdentifier();
534  $defaultFlashMessageQueue->enqueue($flashMessage);
535  }
536 
540  protected function ‪getShortcutTitle(): string
541  {
542  return sprintf(
543  '%s: %s [%d]',
544  $this->‪getLanguageService()->sL('LLL:EXT:beuser/Resources/Private/Language/locallang_mod.xlf:mlang_tabs_tab'),
545  BackendUtility::getRecordTitle('pages', $this->pageInfo),
546  $this->id
547  );
548  }
549 
550  protected function ‪htmlResponse(string $html, int $code = 200): ResponseInterface
551  {
552  $response = $this->responseFactory->createResponse($code)
553  ->withHeader('Content-Type', 'text/html; charset=utf-8');
554  $response->getBody()->write($html);
555  return $response;
556  }
557 
559  {
560  return ‪$GLOBALS['BE_USER'];
561  }
562 
564  {
565  return ‪$GLOBALS['LANG'];
566  }
567 }
‪TYPO3\CMS\Core\DataHandling\DataHandler
Definition: DataHandler.php:94
‪TYPO3\CMS\Beuser\Controller\PermissionController
Definition: PermissionController.php:53
‪TYPO3\CMS\Beuser\Controller\PermissionController\$id
‪int $id
Definition: PermissionController.php:58
‪TYPO3\CMS\Backend\Template\Components\ButtonBar\BUTTON_POSITION_LEFT
‪const BUTTON_POSITION_LEFT
Definition: ButtonBar.php:37
‪TYPO3\CMS\Backend\Template\Components\ButtonBar
Definition: ButtonBar.php:33
‪TYPO3\CMS\Backend\Template\ModuleTemplate\assignMultiple
‪assignMultiple(array $values)
Definition: ModuleTemplate.php:103
‪TYPO3\CMS\Beuser\Controller\PermissionController\__construct
‪__construct(protected readonly ModuleTemplateFactory $moduleTemplateFactory, protected readonly PageRenderer $pageRenderer, protected readonly IconFactory $iconFactory, protected readonly UriBuilder $uriBuilder, protected readonly ResponseFactoryInterface $responseFactory, protected readonly BackendViewFactory $backendViewFactory,)
Definition: PermissionController.php:63
‪TYPO3\CMS\Backend\View\BackendViewFactory
Definition: BackendViewFactory.php:35
‪TYPO3\CMS\Beuser\Controller\PermissionController\getRecursiveSelectOptions
‪getRecursiveSelectOptions()
Definition: PermissionController.php:487
‪TYPO3\CMS\Backend\Template\ModuleTemplateFactory
Definition: ModuleTemplateFactory.php:33
‪TYPO3\CMS\Beuser\Controller\PermissionController\indexAction
‪indexAction(ModuleTemplate $view, ServerRequestInterface $request)
Definition: PermissionController.php:286
‪TYPO3\CMS\Beuser\Controller\PermissionController\$pageInfo
‪array $pageInfo
Definition: PermissionController.php:61
‪TYPO3\CMS\Beuser\Controller\PermissionController\RECURSIVE_LEVELS
‪const RECURSIVE_LEVELS
Definition: PermissionController.php:56
‪TYPO3\CMS\Backend\Template\ModuleTemplate\renderResponse
‪renderResponse(string $templateFileName='')
Definition: ModuleTemplate.php:122
‪TYPO3\CMS\Beuser\Controller
Definition: BackendUserController.php:18
‪TYPO3\CMS\Beuser\Controller\PermissionController\DEPTH_LEVELS
‪const DEPTH_LEVELS
Definition: PermissionController.php:55
‪TYPO3\CMS\Core\Imaging\IconFactory
Definition: IconFactory.php:34
‪TYPO3\CMS\Backend\Tree\View\PageTreeView
Definition: PageTreeView.php:28
‪TYPO3\CMS\Beuser\Controller\PermissionController\updateAction
‪updateAction(ServerRequestInterface $request)
Definition: PermissionController.php:350
‪TYPO3\CMS\Beuser\Controller\PermissionController\handleAjaxRequest
‪handleAjaxRequest(ServerRequestInterface $request)
Definition: PermissionController.php:130
‪TYPO3\CMS\Backend\Template\ModuleTemplate
Definition: ModuleTemplate.php:46
‪TYPO3\CMS\Core\Type\ContextualFeedbackSeverity
‪ContextualFeedbackSeverity
Definition: ContextualFeedbackSeverity.php:25
‪TYPO3\CMS\Beuser\Controller\PermissionController\$returnUrl
‪string $returnUrl
Definition: PermissionController.php:59
‪TYPO3\CMS\Core\Page\PageRenderer
Definition: PageRenderer.php:44
‪TYPO3\CMS\Beuser\Controller\PermissionController\registerDocHeaderButtons
‪registerDocHeaderButtons(ModuleTemplate $view, string $action)
Definition: PermissionController.php:390
‪TYPO3\CMS\Backend\Template\Components\Buttons\DropDown\DropDownRadio
Definition: DropDownRadio.php:54
‪TYPO3\CMS\Beuser\Controller\PermissionController\getDepthOptions
‪getDepthOptions()
Definition: PermissionController.php:474
‪TYPO3\CMS\Beuser\Controller\PermissionController\SESSION_PREFIX
‪const SESSION_PREFIX
Definition: PermissionController.php:54
‪TYPO3\CMS\Beuser\Controller\PermissionController\getBackendUser
‪getBackendUser()
Definition: PermissionController.php:558
‪TYPO3\CMS\Backend\Routing\UriBuilder
Definition: UriBuilder.php:44
‪TYPO3\CMS\Beuser\Controller\PermissionController\getLanguageService
‪getLanguageService()
Definition: PermissionController.php:563
‪TYPO3\CMS\Core\Authentication\BackendUserAuthentication
Definition: BackendUserAuthentication.php:62
‪TYPO3\CMS\Backend\Template\Components\Buttons\DropDown\DropDownHeader
Definition: DropDownHeader.php:30
‪TYPO3\CMS\Beuser\Controller\PermissionController\getTree
‪getTree()
Definition: PermissionController.php:446
‪TYPO3\CMS\Beuser\Controller\PermissionController\editAction
‪editAction(ModuleTemplate $view, ServerRequestInterface $request)
Definition: PermissionController.php:309
‪TYPO3\CMS\Beuser\Controller\PermissionController\getShortcutTitle
‪getShortcutTitle()
Definition: PermissionController.php:540
‪TYPO3\CMS\Backend\Template\ModuleTemplate\getDocHeaderComponent
‪getDocHeaderComponent()
Definition: ModuleTemplate.php:181
‪TYPO3\CMS\Core\Messaging\FlashMessage
Definition: FlashMessage.php:27
‪TYPO3\CMS\Webhooks\Message\$uid
‪identifier readonly int $uid
Definition: PageModificationMessage.php:35
‪$GLOBALS
‪$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['adminpanel']['modules']
Definition: ext_localconf.php:25
‪TYPO3\CMS\Beuser\Controller\PermissionController\$depth
‪int $depth
Definition: PermissionController.php:60
‪TYPO3\CMS\Beuser\Controller\PermissionController\addFlashMessage
‪addFlashMessage(string $message, string $title='', ContextualFeedbackSeverity $severity=ContextualFeedbackSeverity::INFO)
Definition: PermissionController.php:529
‪TYPO3\CMS\Backend\Attribute\AsController
Definition: AsController.php:25
‪TYPO3\CMS\Core\Localization\LanguageService
Definition: LanguageService.php:46
‪TYPO3\CMS\Beuser\Controller\PermissionController\htmlResponse
‪htmlResponse(string $html, int $code=200)
Definition: PermissionController.php:550
‪TYPO3\CMS\Core\Utility\GeneralUtility
Definition: GeneralUtility.php:52
‪TYPO3\CMS\Backend\Template\Components\ButtonBar\BUTTON_POSITION_RIGHT
‪const BUTTON_POSITION_RIGHT
Definition: ButtonBar.php:42
‪TYPO3\CMS\Core\Utility\GeneralUtility\intExplode
‪static list< int > intExplode(string $delimiter, string $string, bool $removeEmptyValues=false)
Definition: GeneralUtility.php:756
‪TYPO3\CMS\Core\Messaging\FlashMessageService
Definition: FlashMessageService.php:27
‪TYPO3\CMS\Beuser\Controller\PermissionController\handleRequest
‪handleRequest(ServerRequestInterface $request)
Definition: PermissionController.php:72