ILIAS  release_8 Revision v8.24
ilADNTabHandling Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Collaboration diagram for ilADNTabHandling:

Public Member Functions

 __construct (int $ref_id)
 ilMMTabHandling constructor. More...
 
 initTabs (string $tab, string $subtab=null, bool $backtab=false)
 

Protected Attributes

ilCtrl $ctrl
 

Private Attributes

int $ref_id
 
ilRbacSystem $rbacsystem
 
ilTabsGUI $tabs
 
ilLanguage $lng
 
ilHelpGUI $help
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Class ilADNTabHandling

Author
Fabian Schmid fs@st.nosp@m.uder.nosp@m.-raim.nosp@m.ann..nosp@m.ch

Definition at line 23 of file class.ilADNTabHandling.php.

Constructor & Destructor Documentation

◆ __construct()

ilADNTabHandling::__construct ( int  $ref_id)

ilMMTabHandling constructor.

Definition at line 40 of file class.ilADNTabHandling.php.

41 {
42 global $DIC;
43
44 $this->ref_id = $ref_id;
45 $this->tabs = $DIC['ilTabs'];
46 $this->lng = $DIC->language();
47 $this->lng->loadLanguageModule('adn');
48 $this->ctrl = $DIC['ilCtrl'];
49 $this->rbacsystem = $DIC['rbacsystem'];
50 $this->help = $DIC->help();
51 }
global $DIC
Definition: feed.php:28

References $DIC, $ref_id, ILIAS\Repository\ctrl(), ILIAS\Repository\help(), ILIAS\Repository\lng(), and ILIAS\Repository\tabs().

+ Here is the call graph for this function:

Member Function Documentation

◆ initTabs()

ilADNTabHandling::initTabs ( string  $tab,
string  $subtab = null,
bool  $backtab = false 
)

Definition at line 53 of file class.ilADNTabHandling.php.

53 : void
54 {
55 $this->tabs->clearTargets(); // clears Help-ID
56
57 // Help Screen-ID
58 $this->help->setScreenIdComponent('adn');
59 $this->help->setScreenId($tab);
60 if (null !== $subtab) {
61 $this->help->setSubScreenId($subtab);
62 }
63
64 if ($this->rbacsystem->checkAccess('visible,read', $this->ref_id)) {
65 $this->tabs->addTab(
68 $this->ctrl->getLinkTargetByClass(ilObjAdministrativeNotificationGUI::class, ilObjAdministrativeNotificationGUI::TAB_MAIN)
69 );
70 /*
71 switch ($tab) {
72 case ilObjMainMenuGUI::TAB_MAIN:
73 $this->tabs->addSubTab(
74 ilMMTopItemGUI::CMD_VIEW_TOP_ITEMS,
75 $this->lng->txt(ilMMTopItemGUI::CMD_VIEW_TOP_ITEMS),
76 $this->ctrl->getLinkTargetByClass(ilMMTopItemGUI::class, ilMMTopItemGUI::CMD_VIEW_TOP_ITEMS)
77 );
78 $this->tabs->addSubTab(
79 ilMMSubItemGUI::CMD_VIEW_SUB_ITEMS,
80 $this->lng->txt(ilMMSubItemGUI::CMD_VIEW_SUB_ITEMS),
81 $this->ctrl->getLinkTargetByClass(ilMMSubItemGUI::class, ilMMSubItemGUI::CMD_VIEW_SUB_ITEMS)
82 );
83 $this->tabs->activateSubTab($subtab);
84 break;
85 }
86 if ($subtab === null) {
87 $subtab = ilMMTopItemGUI::CMD_VIEW_TOP_ITEMS;
88 }
89 $this->tabs->activateSubTab($subtab);*/
90 }
91 if ($this->rbacsystem->checkAccess('edit_permission', $this->ref_id)) {
92 $this->tabs->addTab(
93 'perm_settings',
94 $this->lng->txt('perm_settings'),
95 $this->ctrl->getLinkTargetByClass(array(ilObjAdministrativeNotificationGUI::class, ilPermissionGUI::class), 'perm')
96 );
97 }
98 if ($backtab) {
99 /* $this->tabs->clearTargets();
100 if ($calling_class == ilMMSubItemGUI::class) {
101 $this->tabs->setBackTarget($this->lng->txt('tab_back'), $this->ctrl->getLinkTargetByClass(ilMMSubItemGUI::class, $subtab));
102 } else {
103 $this->tabs->setBackTarget($this->lng->txt('tab_back'), $this->ctrl->getLinkTargetByClass(ilObjMainMenuGUI::class, $subtab));
104 }*/
105 }
106 $this->tabs->activateTab($tab);
107 }

References ILIAS\Repository\help(), ILIAS\Repository\lng(), ilObjAdministrativeNotificationGUI\TAB_MAIN, and ILIAS\Repository\tabs().

+ Here is the call graph for this function:

Field Documentation

◆ $ctrl

ilCtrl ilADNTabHandling::$ctrl
protected

Definition at line 33 of file class.ilADNTabHandling.php.

◆ $help

ilHelpGUI ilADNTabHandling::$help
private

Definition at line 35 of file class.ilADNTabHandling.php.

◆ $lng

ilLanguage ilADNTabHandling::$lng
private

Definition at line 31 of file class.ilADNTabHandling.php.

◆ $rbacsystem

ilRbacSystem ilADNTabHandling::$rbacsystem
private

Definition at line 27 of file class.ilADNTabHandling.php.

◆ $ref_id

int ilADNTabHandling::$ref_id
private

Definition at line 25 of file class.ilADNTabHandling.php.

Referenced by __construct().

◆ $tabs

ilTabsGUI ilADNTabHandling::$tabs
private

Definition at line 29 of file class.ilADNTabHandling.php.


The documentation for this class was generated from the following file: