ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ILIAS\User\Presentation\AdminTabs Class Reference
+ Collaboration diagram for ILIAS\User\Presentation\AdminTabs:

Public Member Functions

 __construct (private readonly \ilTabsGUI $tabs_gui, private readonly Language $lng, private readonly \ilCtrl $ctrl, private readonly \ilAccess $access, private readonly int $ref_id)
 
 initializeTabs ()
 

Private Member Functions

 addAccountsTab ()
 
 addSettingsTab ()
 
 addProfileTab ()
 
 addExportTab ()
 
 addPermissionsTab ()
 
 addExtendedSearchTab ()
 
 activateTab ()
 
 initializeSubTabs ()
 
 addSettingsSubTabs ()
 
 addProfileSubTabs ()
 
 activateSettingsSubTab ()
 
 activateProfileSubTab ()
 
 accessToPermissionsGranted ()
 
 readAccessToAccountsGranted ()
 
 editSettingsAccessGranted ()
 
 checkCmdClassInArray (array $class_array)
 

Private Attributes

const TAB_ID_ACCOUNTS = 'accounts'
 
const TAB_ID_EXTENDED_SEARCH = 'search_user_extended'
 
const TAB_ID_SETTINGS = 'settings'
 
const TAB_ID_PROFILE = 'profile'
 
const TAB_ID_EXPORT = 'export'
 
const TAB_ID_PERMISSIONS = 'perm_settings'
 
const SUBTAB_ID_SETTINGS_AMIN = 'admin_settings'
 
const SUBTAB_ID_SETTINGS_USER = 'user_settings'
 
const SUBTAB_ID_SETTINGS_NEW_ACCOUNT_MAIL = 'new_account_mail'
 
const SUBTAB_ID_SETTINGS_STARTING_POINTS = 'starting_points'
 
const SUBTAB_ID_PROFILE_FIELDS = 'fields'
 
const SUBTAB_ID_PROFILE_INFO = 'profile_info'
 
const CMD_CLASSES_WITH_SETTINGS_SUBTABS
 
const CMD_CLASSES_WITH_PROFILE_SUBTABS
 

Detailed Description

Definition at line 31 of file AdminTabs.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\User\Presentation\AdminTabs::__construct ( private readonly \ilTabsGUI  $tabs_gui,
private readonly Language  $lng,
private readonly \ilCtrl  $ctrl,
private readonly \ilAccess  $access,
private readonly int  $ref_id 
)

Definition at line 60 of file AdminTabs.php.

66 {
67 }

Member Function Documentation

◆ accessToPermissionsGranted()

ILIAS\User\Presentation\AdminTabs::accessToPermissionsGranted ( )
private

Definition at line 291 of file AdminTabs.php.

291 : bool
292 {
293 return $this->access->checkAccess(
294 'edit_permission',
295 '',
296 $this->ref_id
297 );
298 }

References ILIAS\Repository\access().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ activateProfileSubTab()

ILIAS\User\Presentation\AdminTabs::activateProfileSubTab ( )
private

Definition at line 279 of file AdminTabs.php.

279 : void
280 {
281 switch ($this->ctrl->getNextClass()) {
282 case strtolower(ProfileFieldsConfigurationGUI::class):
283 $this->tabs_gui->activateSubTab(self::SUBTAB_ID_PROFILE_FIELDS);
284 break;
285 case strtolower(ProfileSettingsGUI::class):
286 $this->tabs_gui->activateSubTab(self::SUBTAB_ID_PROFILE_INFO);
287 break;
288 }
289 }

References ILIAS\Repository\ctrl().

Referenced by ILIAS\User\Presentation\AdminTabs\activateTab().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ activateSettingsSubTab()

ILIAS\User\Presentation\AdminTabs::activateSettingsSubTab ( )
private

Definition at line 261 of file AdminTabs.php.

261 : void
262 {
263 switch ($this->ctrl->getNextClass()) {
264 case strtolower(AdminSettingsGUI::class):
265 $this->tabs_gui->activateSubTab(self::SUBTAB_ID_SETTINGS_AMIN);
266 break;
267 case strtolower(UserSettingsConfigurationGUI::class):
268 $this->tabs_gui->activateSubTab(self::SUBTAB_ID_SETTINGS_USER);
269 break;
270 case strtolower(NewAccountMailSettingsGUI::class):
271 $this->tabs_gui->activateSubTab(self::SUBTAB_ID_SETTINGS_NEW_ACCOUNT_MAIL);
272 break;
273 case strtolower(StartingPointSettingsGUI::class):
274 $this->tabs_gui->activateSubTab(self::SUBTAB_ID_SETTINGS_STARTING_POINTS);
275 break;
276 }
277 }

References ILIAS\Repository\ctrl().

Referenced by ILIAS\User\Presentation\AdminTabs\activateTab().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ activateTab()

ILIAS\User\Presentation\AdminTabs::activateTab ( )
private

Definition at line 162 of file AdminTabs.php.

162 : void
163 {
164 if ($this->checkCmdClassInArray(self::CMD_CLASSES_WITH_SETTINGS_SUBTABS)) {
165 $this->tabs_gui->activateTab(self::TAB_ID_SETTINGS);
166 $this->activateSettingsSubTab();
167 return;
168 }
169
170 if ($this->checkCmdClassInArray(self::CMD_CLASSES_WITH_PROFILE_SUBTABS)) {
171 $this->tabs_gui->activateTab(self::TAB_ID_PROFILE);
172 $this->activateProfileSubTab();
173 return;
174 }
175
176 switch ($this->ctrl->getCmdClass()) {
177 case strtolower(\ilObjUserFolderGUI::class):
178 $this->tabs_gui->activateTab(self::TAB_ID_ACCOUNTS);
179 break;
180 case strtolower(\ilRepositorySearchGUI::class):
181 $this->tabs_gui->activateTab(self::TAB_ID_EXTENDED_SEARCH);
182 break;
183 case strtolower(\ilExportGUI::class):
184 $this->tabs_gui->activateTab(self::TAB_ID_EXPORT);
185 break;
186 case strtolower(\ilPermissionGUI::class):
187 $this->tabs_gui->activateTab(self::TAB_ID_PERMISSIONS);
188 break;
189 }
190 }
checkCmdClassInArray(array $class_array)
Definition: AdminTabs.php:318

References ILIAS\User\Presentation\AdminTabs\activateProfileSubTab(), ILIAS\User\Presentation\AdminTabs\activateSettingsSubTab(), ILIAS\User\Presentation\AdminTabs\checkCmdClassInArray(), and ILIAS\Repository\ctrl().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addAccountsTab()

ILIAS\User\Presentation\AdminTabs::addAccountsTab ( )
private

Definition at line 90 of file AdminTabs.php.

90 : void
91 {
92 $this->tabs_gui->addTab(
93 self::TAB_ID_ACCOUNTS,
94 $this->lng->txt('usrf'),
95 $this->ctrl->getLinkTargetByClass(
96 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class],
97 'view'
98 )
99 );
100 }

References ILIAS\Repository\lng().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addExportTab()

ILIAS\User\Presentation\AdminTabs::addExportTab ( )
private

Definition at line 126 of file AdminTabs.php.

126 : void
127 {
128 $this->tabs_gui->addTab(
129 self::TAB_ID_EXPORT,
130 $this->lng->txt('export'),
131 $this->ctrl->getLinkTargetByClass(
132 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, \ilExportGUI::class],
133 'export'
134 )
135 );
136 }

References ILIAS\Repository\lng().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addExtendedSearchTab()

ILIAS\User\Presentation\AdminTabs::addExtendedSearchTab ( )
private

Definition at line 150 of file AdminTabs.php.

150 : void
151 {
152 $this->tabs_gui->addTab(
153 self::TAB_ID_EXTENDED_SEARCH,
154 $this->lng->txt('search_user_extended'),
155 $this->ctrl->getLinkTargetByClass(
156 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, \ilRepositorySearchGUI::class],
157 ''
158 )
159 );
160 }

References ILIAS\Repository\lng().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addPermissionsTab()

ILIAS\User\Presentation\AdminTabs::addPermissionsTab ( )
private

Definition at line 138 of file AdminTabs.php.

138 : void
139 {
140 $this->tabs_gui->addTab(
141 self::TAB_ID_PERMISSIONS,
142 $this->lng->txt('perm_settings'),
143 $this->ctrl->getLinkTargetByClass(
144 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, \ilPermissionGUI::class],
145 'perm'
146 )
147 );
148 }

References ILIAS\Repository\lng().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addProfileSubTabs()

ILIAS\User\Presentation\AdminTabs::addProfileSubTabs ( )
private

Definition at line 241 of file AdminTabs.php.

241 : void
242 {
243 $this->tabs_gui->addSubTab(
244 self::SUBTAB_ID_PROFILE_FIELDS,
245 $this->lng->txt('profile_fields'),
246 $this->ctrl->getLinkTargetByClass(
247 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, ProfileFieldsConfigurationGUI::class],
248 'show'
249 )
250 );
251 $this->tabs_gui->addSubTab(
252 self::SUBTAB_ID_PROFILE_INFO,
253 $this->lng->txt('user_profile_info'),
254 $this->ctrl->getLinkTargetByClass(
255 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, ProfileSettingsGUI::class],
256 ''
257 )
258 );
259 }

References ILIAS\Repository\lng().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeSubTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addProfileTab()

ILIAS\User\Presentation\AdminTabs::addProfileTab ( )
private

Definition at line 114 of file AdminTabs.php.

114 : void
115 {
116 $this->tabs_gui->addTab(
117 self::TAB_ID_PROFILE,
118 $this->lng->txt('profile'),
119 $this->ctrl->getLinkTargetByClass(
120 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, ProfileFieldsConfigurationGUI::class],
121 'show'
122 )
123 );
124 }

References ILIAS\Repository\lng().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addSettingsSubTabs()

ILIAS\User\Presentation\AdminTabs::addSettingsSubTabs ( )
private

Definition at line 205 of file AdminTabs.php.

205 : void
206 {
207 $this->tabs_gui->addSubTab(
208 self::SUBTAB_ID_SETTINGS_AMIN,
209 $this->lng->txt('administrative_settings'),
210 $this->ctrl->getLinkTargetByClass(
211 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, AdminSettingsGUI::class],
212 'show'
213 )
214 );
215 $this->tabs_gui->addSubTab(
216 self::SUBTAB_ID_SETTINGS_USER,
217 $this->lng->txt('user_settings'),
218 $this->ctrl->getLinkTargetByClass(
219 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, UserSettingsConfigurationGUI::class],
220 'show'
221 )
222 );
223 $this->tabs_gui->addSubTab(
224 self::SUBTAB_ID_SETTINGS_NEW_ACCOUNT_MAIL,
225 $this->lng->txt('registration_user_new_account_mail'),
226 $this->ctrl->getLinkTargetByClass(
227 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, NewAccountMailSettingsGUI::class],
228 'show'
229 )
230 );
231 $this->tabs_gui->addSubTab(
232 self::SUBTAB_ID_SETTINGS_STARTING_POINTS,
233 $this->lng->txt('starting_points'),
234 $this->ctrl->getLinkTargetByClass(
235 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, StartingPointSettingsGUI::class],
236 'startingPoints'
237 )
238 );
239 }

References ILIAS\Repository\lng().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeSubTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addSettingsTab()

ILIAS\User\Presentation\AdminTabs::addSettingsTab ( )
private

Definition at line 102 of file AdminTabs.php.

102 : void
103 {
104 $this->tabs_gui->addTab(
105 self::TAB_ID_SETTINGS,
106 $this->lng->txt('settings'),
107 $this->ctrl->getLinkTargetByClass(
108 [\ilAdministrationGUI::class, \ilObjUserFolderGUI::class, AdminSettingsGUI::class],
109 'show'
110 )
111 );
112 }

References ILIAS\Repository\lng().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ checkCmdClassInArray()

ILIAS\User\Presentation\AdminTabs::checkCmdClassInArray ( array  $class_array)
private

Definition at line 318 of file AdminTabs.php.

318 : bool
319 {
320 $cmd_class = $this->ctrl->getNextClass();
321 return array_filter(
322 $class_array,
323 static fn(string $class): bool => $cmd_class === strtolower($class)
324 ) !== [];
325 }

References ILIAS\Repository\ctrl().

Referenced by ILIAS\User\Presentation\AdminTabs\activateTab(), and ILIAS\User\Presentation\AdminTabs\initializeSubTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ editSettingsAccessGranted()

ILIAS\User\Presentation\AdminTabs::editSettingsAccessGranted ( )
private

Definition at line 309 of file AdminTabs.php.

309 : bool
310 {
311 return $this->access->checkRbacOrPositionPermissionAccess(
312 'write',
314 $this->ref_id
315 );
316 }

References ILIAS\Repository\access(), and ilObjUserFolder\ORG_OP_EDIT_USER_ACCOUNTS.

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ initializeSubTabs()

ILIAS\User\Presentation\AdminTabs::initializeSubTabs ( )
private

Definition at line 192 of file AdminTabs.php.

192 : void
193 {
194 if ($this->checkCmdClassInArray(self::CMD_CLASSES_WITH_SETTINGS_SUBTABS)) {
195 $this->addSettingsSubTabs();
196 return;
197 }
198
199 if ($this->checkCmdClassInArray(self::CMD_CLASSES_WITH_PROFILE_SUBTABS)) {
200 $this->addProfileSubTabs();
201 return;
202 }
203 }

References ILIAS\User\Presentation\AdminTabs\addProfileSubTabs(), ILIAS\User\Presentation\AdminTabs\addSettingsSubTabs(), and ILIAS\User\Presentation\AdminTabs\checkCmdClassInArray().

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ initializeTabs()

ILIAS\User\Presentation\AdminTabs::initializeTabs ( )

Definition at line 69 of file AdminTabs.php.

References ILIAS\User\Presentation\AdminTabs\accessToPermissionsGranted(), ILIAS\User\Presentation\AdminTabs\activateTab(), ILIAS\User\Presentation\AdminTabs\addAccountsTab(), ILIAS\User\Presentation\AdminTabs\addExportTab(), ILIAS\User\Presentation\AdminTabs\addExtendedSearchTab(), ILIAS\User\Presentation\AdminTabs\addPermissionsTab(), ILIAS\User\Presentation\AdminTabs\addProfileTab(), ILIAS\User\Presentation\AdminTabs\addSettingsTab(), ILIAS\User\Presentation\AdminTabs\editSettingsAccessGranted(), ILIAS\User\Presentation\AdminTabs\initializeSubTabs(), and ILIAS\User\Presentation\AdminTabs\readAccessToAccountsGranted().

+ Here is the call graph for this function:

◆ readAccessToAccountsGranted()

ILIAS\User\Presentation\AdminTabs::readAccessToAccountsGranted ( )
private

Definition at line 300 of file AdminTabs.php.

300 : bool
301 {
302 return $this->access->checkRbacOrPositionPermissionAccess(
303 'read',
305 $this->ref_id
306 );
307 }

References ILIAS\Repository\access(), and ilObjUserFolder\ORG_OP_EDIT_USER_ACCOUNTS.

Referenced by ILIAS\User\Presentation\AdminTabs\initializeTabs().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ CMD_CLASSES_WITH_PROFILE_SUBTABS

const ILIAS\User\Presentation\AdminTabs::CMD_CLASSES_WITH_PROFILE_SUBTABS
private
Initial value:
= [
ProfileFieldsConfigurationGUI::class,
ProfileSettingsGUI::class
]

Definition at line 55 of file AdminTabs.php.

◆ CMD_CLASSES_WITH_SETTINGS_SUBTABS

const ILIAS\User\Presentation\AdminTabs::CMD_CLASSES_WITH_SETTINGS_SUBTABS
private
Initial value:
= [
AdminSettingsGUI::class,
UserSettingsConfigurationGUI::class,
NewAccountMailSettingsGUI::class,
StartingPointSettingsGUI::class
]

Definition at line 48 of file AdminTabs.php.

◆ SUBTAB_ID_PROFILE_FIELDS

const ILIAS\User\Presentation\AdminTabs::SUBTAB_ID_PROFILE_FIELDS = 'fields'
private

Definition at line 45 of file AdminTabs.php.

◆ SUBTAB_ID_PROFILE_INFO

const ILIAS\User\Presentation\AdminTabs::SUBTAB_ID_PROFILE_INFO = 'profile_info'
private

Definition at line 46 of file AdminTabs.php.

◆ SUBTAB_ID_SETTINGS_AMIN

const ILIAS\User\Presentation\AdminTabs::SUBTAB_ID_SETTINGS_AMIN = 'admin_settings'
private

Definition at line 40 of file AdminTabs.php.

◆ SUBTAB_ID_SETTINGS_NEW_ACCOUNT_MAIL

const ILIAS\User\Presentation\AdminTabs::SUBTAB_ID_SETTINGS_NEW_ACCOUNT_MAIL = 'new_account_mail'
private

Definition at line 42 of file AdminTabs.php.

◆ SUBTAB_ID_SETTINGS_STARTING_POINTS

const ILIAS\User\Presentation\AdminTabs::SUBTAB_ID_SETTINGS_STARTING_POINTS = 'starting_points'
private

Definition at line 43 of file AdminTabs.php.

◆ SUBTAB_ID_SETTINGS_USER

const ILIAS\User\Presentation\AdminTabs::SUBTAB_ID_SETTINGS_USER = 'user_settings'
private

Definition at line 41 of file AdminTabs.php.

◆ TAB_ID_ACCOUNTS

const ILIAS\User\Presentation\AdminTabs::TAB_ID_ACCOUNTS = 'accounts'
private

Definition at line 33 of file AdminTabs.php.

◆ TAB_ID_EXPORT

const ILIAS\User\Presentation\AdminTabs::TAB_ID_EXPORT = 'export'
private

Definition at line 37 of file AdminTabs.php.

◆ TAB_ID_EXTENDED_SEARCH

const ILIAS\User\Presentation\AdminTabs::TAB_ID_EXTENDED_SEARCH = 'search_user_extended'
private

Definition at line 34 of file AdminTabs.php.

◆ TAB_ID_PERMISSIONS

const ILIAS\User\Presentation\AdminTabs::TAB_ID_PERMISSIONS = 'perm_settings'
private

Definition at line 38 of file AdminTabs.php.

◆ TAB_ID_PROFILE

const ILIAS\User\Presentation\AdminTabs::TAB_ID_PROFILE = 'profile'
private

Definition at line 36 of file AdminTabs.php.

◆ TAB_ID_SETTINGS

const ILIAS\User\Presentation\AdminTabs::TAB_ID_SETTINGS = 'settings'
private

Definition at line 35 of file AdminTabs.php.


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