ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
class.ilGlobalUnitConfigurationGUI.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
25{
26 public const REQUEST_PARAM_SUB_CONTEXT = 'context';
27
28 protected function getDefaultCommand(): string
29 {
30 return 'showGlobalUnitCategories';
31 }
32
33 public function getUnitCategoryOverviewCommand(): string
34 {
35 return 'showGlobalUnitCategories';
36 }
37
38 public function isCRUDContext(): bool
39 {
40 return true;
41 }
42
43 public function getUniqueId(): string
44 {
45 return $this->repository->getConsumerId() . '_global';
46 }
47
48 protected function showGlobalUnitCategories(): void
49 {
50 global $DIC;
51
52 $ilToolbar = $DIC->toolbar();
53 $rbacsystem = $DIC->rbac()->system();
54
55 if ($rbacsystem->checkAccess('write', $this->request->getRefId())) {
56 $ilToolbar->addButton($this->lng->txt('un_add_category'), $this->ctrl->getLinkTarget($this, 'showUnitCategoryCreationForm'));
57 }
58
59 parent::showGlobalUnitCategories();
60 }
61
62 protected function showUnitCategories(array $categories): void
63 {
65 $table->setData($categories);
66
67 $this->tpl->setContent($table->getHTML());
68 }
69}
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Class ilGlobalUnitConfigurationGUI.
Class ilUnitConfigurationGUI.
global $DIC
Definition: shib_login.php:26