ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
class.ilMailingListsGUI.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
21use ILIAS\Refinery\Factory as Refinery;
25
27{
28 private readonly \ILIAS\HTTP\GlobalHttpState $http;
29 private readonly Refinery $refinery;
31 private readonly ilCtrlInterface $ctrl;
32 private readonly ilLanguage $lng;
33 private readonly ilObjUser $user;
34 private readonly ilErrorHandling $error;
35 private readonly ilToolbarGUI $toolbar;
36 private readonly ilRbacSystem $rbacsystem;
37 private readonly ilFormatMail $umail;
38 private readonly ilMailingLists $mlists;
39 private StandardForm $form;
40 private readonly \ILIAS\UI\Factory $ui_factory;
41 private readonly \ILIAS\UI\Renderer $ui_renderer;
42 private readonly ilTabsGUI $tabs;
43
44 public function __construct()
45 {
46 global $DIC;
47
48 $this->tpl = $DIC->ui()->mainTemplate();
49 $this->ctrl = $DIC['ilCtrl'];
50 $this->lng = $DIC['lng'];
51 $this->rbacsystem = $DIC['rbacsystem'];
52 $this->user = $DIC['ilUser'];
53 $this->error = $DIC['ilErr'];
54 $this->toolbar = $DIC['ilToolbar'];
55 $this->http = $DIC->http();
56 $this->refinery = $DIC->refinery();
57 $this->ui_factory = $DIC->ui()->factory();
58 $this->ui_renderer = $DIC->ui()->renderer();
59 $this->tabs = $DIC->tabs();
60
61 $this->umail = new ilFormatMail($this->user->getId());
62 $this->mlists = new ilMailingLists($this->user);
63 $this->mlists->setCurrentMailingList($this->getQueryMailingListId());
64
65 $this->ctrl->saveParameter($this, 'mobj_id');
66 $this->ctrl->saveParameter($this, 'ref');
67
68 $this->lng->loadLanguageModule('mail');
69 }
70
71 public function getUnsafeGetCommands(): array
72 {
73 return [
74 'handleMailingListActions',
75 'handleMailingListMemberActions',
76 ];
77 }
78
79 public function getSafePostCommands(): array
80 {
81 return [];
82 }
83
84 private function getQueryMailingListId(): int
85 {
86 return $this->http->wrapper()->query()->retrieve(
87 'ml_id',
88 $this->refinery->byTrying([
89 $this->refinery->kindlyTo()->int(),
90 $this->refinery->always(
91 current(
92 $this->http->wrapper()->query()->retrieve(
93 'contact_mailinglist_list_ml_ids',
94 $this->refinery->byTrying([
95 $this->refinery->kindlyTo()->listOf($this->refinery->kindlyTo()->int()),
96 $this->refinery->always([0])
97 ])
98 )
99 ) ?: 0
100 )
101 ])
102 );
103 }
104
105 public function executeCommand(): bool
106 {
107 if (
108 !ilBuddySystem::getInstance()->isEnabled() ||
109 (
110 count(ilBuddyList::getInstanceByGlobalUser()->getLinkedRelations()) === 0 &&
111 !$this->mlists->hasAny()
112 )
113 ) {
114 $this->error->raiseError($this->lng->txt('msg_no_perm_read'), $this->error->MESSAGE);
115 }
116
117 $cmd = $this->ctrl->getCmd();
118 if ($cmd === null || $cmd === '' || !method_exists($this, $cmd . 'Command')) {
119 $cmd = 'showMailingLists';
120 }
121 $verified_command = $cmd . 'Command';
122
123 $this->$verified_command();
124
125 return true;
126 }
127
129 {
130 $action = $this->http->wrapper()->query()->retrieve(
131 'contact_mailinglist_members_action',
132 $this->refinery->byTrying([
133 $this->refinery->kindlyTo()->string(),
134 $this->refinery->always('')
135 ])
136 );
137 match ($action) {
138 'confirmDeleteMembers' => $this->confirmDeleteMembers(),
139 default => $this->ctrl->redirect($this, 'showMailingLists'),
140 };
141 }
142
143 private function handleMailingListActionsCommand(): void
144 {
145 $action = $this->http->wrapper()->query()->retrieve(
146 'contact_mailinglist_list_action',
147 $this->refinery->byTrying([
148 $this->refinery->kindlyTo()->string(),
149 $this->refinery->always('')
150 ])
151 );
152 match ($action) {
153 'mailToList' => $this->mailToList(),
154 'confirmDelete' => $this->confirmDelete(),
155 'showMembersList' => $this->showMembersListCommand(),
156 'showForm' => $this->showFormCommand(),
157 default => $this->ctrl->redirect($this, 'showMailingLists'),
158 };
159 }
160
164 private function getMailingListIdsFromRequest(): array
165 {
166 if ($this->http->wrapper()->query()->has('ml_id')) {
167 $ml_ids = [
168 $this->http->wrapper()->query()->retrieve('ml_id', $this->refinery->kindlyTo()->int())
169 ];
170 } elseif ($this->http->wrapper()->post()->has('ml_id')) {
171 $ml_ids = $this->http->wrapper()->post()->retrieve(
172 'ml_id',
173 $this->refinery->kindlyTo()->listOf(
174 $this->refinery->kindlyTo()->int()
175 )
176 );
177 } else {
178 $ml_ids = $this->http->wrapper()->query()->retrieve(
179 'contact_mailinglist_list_ml_ids',
180 $this->refinery->byTrying([
181 $this->refinery->kindlyTo()->listOf($this->refinery->kindlyTo()->string()),
182 $this->refinery->always([])
183 ])
184 );
185 }
186
187 return array_filter($ml_ids);
188 }
189
190 private function confirmDelete(): void
191 {
192 $ml_ids = $this->getMailingListIdsFromRequest();
193 if ($ml_ids === []) {
194 $this->tpl->setOnScreenMessage('info', $this->lng->txt('mail_select_one_entry'));
196 return;
197 }
198
199 if ((string) current($ml_ids) === 'ALL_OBJECTS') {
200 $entries = $this->mlists->getAll();
201 } else {
202 $entries = $this->mlists->getSelected(
203 array_map(intval(...), $ml_ids)
204 );
205 }
206
207 $c_gui = new ilConfirmationGUI();
208
209 $c_gui->setFormAction($this->ctrl->getFormAction($this, 'performDelete'));
210 $c_gui->setHeaderText($this->lng->txt('mail_sure_delete_entry'));
211 $c_gui->setCancel($this->lng->txt('cancel'), 'showMailingLists');
212 $c_gui->setConfirm($this->lng->txt('confirm'), 'performDelete');
213
214 foreach ($entries as $entry) {
215 $c_gui->addItem('ml_id[]', (string) $entry->getId(), $entry->getTitle());
216 }
217
218 $this->tpl->setTitle($this->lng->txt('mail_addressbook'));
219 $this->tpl->setContent($c_gui->getHTML());
220 $this->tpl->printToStdout();
221 }
222
223 public function performDeleteCommand(): void
224 {
225 if ($this->http->wrapper()->post()->has('ml_id')) {
226 $ml_ids = array_filter(
227 $this->http->wrapper()->post()->retrieve(
228 'ml_id',
229 $this->refinery->kindlyTo()->listOf(
230 $this->refinery->kindlyTo()->int()
231 )
232 )
233 );
234
235 $counter = 0;
236 foreach ($ml_ids as $id) {
237 if ($this->mlists->isOwner($id, $this->user->getId())) {
238 $this->mlists->get($id)->delete();
239 ++$counter;
240 }
241 }
242
243 if ($counter !== 0) {
244 $this->tpl->setOnScreenMessage(
245 $this->tpl::MESSAGE_TYPE_SUCCESS,
246 $this->lng->txt('mail_deleted_entry'),
247 true
248 );
249 }
250 } else {
251 $this->tpl->setOnScreenMessage(
252 $this->tpl::MESSAGE_TYPE_FAILURE,
253 $this->lng->txt('mail_delete_error'),
254 true
255 );
256 }
257
258 $this->ctrl->redirect($this, 'showMailingLists');
259 }
260
261 private function mailToList(): void
262 {
263 // check if current user may send mails
264 $mail = new ilMail($this->user->getId());
265 $mailing_allowed = $this->rbacsystem->checkAccess('internal_mail', $mail->getMailObjectReferenceId());
266
267 if (!$mailing_allowed) {
268 $this->tpl->setOnScreenMessage($this->tpl::MESSAGE_TYPE_FAILURE, $this->lng->txt('no_permission'));
269 return;
270 }
271
272 $ml_ids = $this->getMailingListIdsFromRequest();
273 if ($ml_ids === []) {
274 $this->tpl->setOnScreenMessage($this->tpl::MESSAGE_TYPE_INFO, $this->lng->txt('mail_select_one_entry'));
276 return;
277 }
278
279 if ((string) current($ml_ids) === 'ALL_OBJECTS') {
280 $entries = $this->mlists->getAll();
281 $ml_ids = [];
282 foreach ($entries as $entry) {
283 $ml_ids[] = $entry->getId();
284 }
285 } else {
286 $ml_ids = array_map(intval(...), $ml_ids);
287 }
288
289 $mail_data = $this->umail->retrieveFromStage();
290 $lists = [];
291 foreach ($ml_ids as $id) {
292 if ($this->mlists->isOwner($id, $this->user->getId()) &&
293 !$this->umail->existsRecipient('#il_ml_' . $id, (string) $mail_data['rcp_to'])) {
294 $lists['#il_ml_' . $id] = '#il_ml_' . $id;
295 }
296 }
297
298 if ($lists !== []) {
299 $mail_data = $this->umail->appendSearchResult(array_values($lists), 'to');
300 $this->umail->persistToStage(
301 (int) $mail_data['user_id'],
302 $mail_data['attachments'],
303 $mail_data['rcp_to'],
304 $mail_data['rcp_cc'],
305 $mail_data['rcp_bcc'],
306 $mail_data['m_subject'],
307 $mail_data['m_message'],
308 $mail_data['use_placeholders'],
309 $mail_data['tpl_ctx_id'],
310 $mail_data['tpl_ctx_params']
311 );
312 }
313
314 ilUtil::redirect('ilias.php?baseClass=ilMailGUI&type=search_res');
315 }
316
317 public function showMailingListsCommand(): void
318 {
319 $mail = new ilMail($this->user->getId());
320
321 $this->toolbar->addComponent(
322 $this->ui_factory->button()->standard(
323 $this->lng->txt('create'),
324 $this->ctrl->getLinkTarget($this, 'showForm')
325 )
326 );
327
328 $tbl = new MailingListsTable(
329 $this->mlists,
330 $this->ctrl,
331 $this->lng,
332 $this->ui_factory,
333 $this->http
334 );
335 $tbl->setMailingAllowed($this->rbacsystem->checkAccess('internal_mail', $mail->getMailObjectReferenceId()));
336
337 $this->tpl->setTitle($this->lng->txt('mail_addressbook'));
338 $this->tpl->setContent($this->ui_renderer->render($tbl->getComponent()));
339 $this->tpl->printToStdout();
340 }
341
342 private function cancelCommand(): void
343 {
344 if ($this->http->wrapper()->query()->has('ref') &&
345 $this->http->wrapper()->query()->retrieve('ref', $this->refinery->kindlyTo()->string()) === 'mail') {
346 $this->ctrl->returnToParent($this);
347 }
348
350 }
351
352 public function saveFormCommand(): void
353 {
354 if ($this->mlists->getCurrentMailingList() && $this->mlists->getCurrentMailingList()->getId()) {
355 if (!$this->mlists->isOwner($this->mlists->getCurrentMailingList()->getId(), $this->user->getId())) {
356 $this->error->raiseError($this->lng->txt('permission_denied'), $this->error->MESSAGE);
357 }
358
359 $this->ctrl->setParameter($this, 'ml_id', $this->mlists->getCurrentMailingList()->getId());
360 }
361 $this->initForm();
362
363 $form = $this->form->withRequest($this->http->request());
364
365 if (!$form->getError()) {
366 $data = $form->getData();
367 $this->mlists->getCurrentMailingList()->setTitle(
368 $data['title']
369 );
370 $this->mlists->getCurrentMailingList()->setDescription(
371 $data['description']
372 );
373
374 $this->tpl->setOnScreenMessage('success', $this->lng->txt('saved_successfully'), true);
375 if ($this->mlists->getCurrentMailingList()->getId() > 0) {
376 $this->mlists->getCurrentMailingList()->setChangedate(date('Y-m-d H:i:s'));
377 $this->mlists->getCurrentMailingList()->update();
378 $this->ctrl->redirect($this, 'showMailingLists');
379 } else {
380 $this->mlists->getCurrentMailingList()->setCreatedate(date('Y-m-d H:i:s'));
381 $this->mlists->getCurrentMailingList()->insert();
382
383 $this->ctrl->setParameter($this, 'ml_id', $this->mlists->getCurrentMailingList()->getId());
384 $this->ctrl->redirect($this, 'showMembersList');
385 }
386 }
387
388 $this->tpl->setTitle($this->lng->txt('mail_addressbook'));
389 $this->tpl->setContent($this->ui_renderer->render([
390 'mailing_lists' => $form
391 ]));
392 $this->tpl->printToStdout();
393 }
394
395 private function initForm(): void
396 {
397 $title = $this->ui_factory
398 ->input()
399 ->field()
400 ->text(
401 $this->lng->txt('title')
402 )
403 ->withRequired(true)
404 ->withValue(
405 $this->mlists->getCurrentMailingList() ? $this->mlists->getCurrentMailingList()->getTitle() : ''
406 );
407
408 $description = $this->ui_factory
409 ->input()
410 ->field()
411 ->textarea(
412 $this->lng->txt('description')
413 )
414 ->withValue(
415 $this->mlists->getCurrentMailingList() ? $this->mlists->getCurrentMailingList()->getDescription() : ''
416 );
417
418 $this->form = $this->ui_factory->input()->container()->form()->standard(
419 $this->ctrl->getFormAction($this, 'saveForm'),
420 [
421 'title' => $title,
422 'description' => $description
423 ]
424 );
425 }
426
427 private function showFormCommand(): void
428 {
429 if ($this->mlists->getCurrentMailingList() && $this->mlists->getCurrentMailingList()->getId()) {
430 if (!$this->mlists->isOwner($this->mlists->getCurrentMailingList()->getId(), $this->user->getId())) {
431 $this->error->raiseError($this->lng->txt('permission_denied'), $this->error->MESSAGE);
432 }
433
434 $this->ctrl->setParameter($this, 'ml_id', $this->mlists->getCurrentMailingList()->getId());
435 }
436 $this->initForm();
437
438 $this->tpl->setTitle($this->lng->txt('mail_addressbook'));
439 $this->tpl->setContent($this->ui_renderer->render([
440 'mailing_lists' => $this->form
441 ]));
442 $this->tpl->printToStdout();
443 }
444
445 private function showMembersListCommand(): void
446 {
447 if (!$this->mlists->getCurrentMailingList() || $this->mlists->getCurrentMailingList()->getId() === 0) {
449 return;
450 }
451
452 $this->tabs->clearTargets();
453 $this->tabs->setBackTarget(
454 $this->lng->txt('back'),
455 $this->ctrl->getLinkTarget($this, 'showMailingLists')
456 );
457
458 $this->ctrl->setParameter($this, 'ml_id', $this->mlists->getCurrentMailingList()->getId());
459
460 $available_usr_ids = array_diff(
461 array_map(
462 static function (ilBuddySystemRelation $relation): int {
463 return $relation->getBuddyUsrId();
464 },
465 ilBuddyList::getInstanceByGlobalUser()->getLinkedRelations()->toArray()
466 ),
467 array_map(
468 static function (array $entry): int {
469 return $entry['usr_id'];
470 },
471 $this->mlists->getCurrentMailingList()->getAssignedEntries()
472 ),
473 );
474
475 if ($available_usr_ids !== []) {
476 $this->toolbar->addComponent(
477 $this->ui_factory->button()->standard(
478 $this->lng->txt('add'),
479 $this->ctrl->getLinkTarget($this, 'showAssignmentForm')
480 )
481 );
482 }
483
484 $tbl = new MailingListsMembersTable(
485 $this->mlists->getCurrentMailingList(),
486 $this->ctrl,
487 $this->lng,
488 $this->ui_factory,
489 $this->http
490 );
491
492 $this->tpl->setTitle($this->lng->txt('mail_addressbook'));
493 $this->tpl->setContent($this->ui_renderer->render($tbl->getComponent()));
494 $this->tpl->printToStdout();
495 }
496
497 private function confirmDeleteMembers(): void
498 {
499 $requested_record_ids = $this->http->wrapper()->query()->retrieve(
500 'contact_mailinglist_members_entry_ids',
501 $this->refinery->byTrying([
502 $this->refinery->kindlyTo()->listOf($this->refinery->kindlyTo()->string()),
503 $this->refinery->always([])
504 ])
505 );
506
507 if ($requested_record_ids === []) {
508 $this->tpl->setOnScreenMessage('info', $this->lng->txt('mail_select_one_entry'));
509 $this->showMembersListCommand();
510 return;
511 }
512
513 if ((string) current($requested_record_ids) === 'ALL_OBJECTS') {
514 $assigned_entries = $this->mlists->getCurrentMailingList()->getAssignedEntries();
515 $requested_record_ids = [];
516 foreach ($assigned_entries as $entry) {
517 $requested_record_ids[] = $entry['a_id'];
518 }
519 } else {
520 $requested_record_ids = array_map(intval(...), $requested_record_ids);
521 }
522
523 $c_gui = new ilConfirmationGUI();
524 $this->ctrl->setParameter($this, 'ml_id', $this->mlists->getCurrentMailingList()->getId());
525 $c_gui->setFormAction($this->ctrl->getFormAction($this, 'performDeleteMembers'));
526 $c_gui->setHeaderText($this->lng->txt('mail_sure_remove_user'));
527 $c_gui->setCancel($this->lng->txt('cancel'), 'showMembersList');
528 $c_gui->setConfirm($this->lng->txt('confirm'), 'performDeleteMembers');
529
530 $assigned_entries = $this->mlists->getCurrentMailingList()->getAssignedEntries();
531 $usr_ids = array_map(static fn(array $entry): int => $entry['usr_id'], $assigned_entries);
532 $names = ilUserUtil::getNamePresentation($usr_ids, false, false, '', false, false, false);
533
534 foreach ($assigned_entries as $entry) {
535 if (in_array($entry['a_id'], $requested_record_ids, true)) {
536 $c_gui->addItem('a_id[]', (string) $entry['a_id'], $names[$entry['usr_id']]);
537 }
538 }
539
540 $this->tpl->setTitle($this->lng->txt('mail_addressbook'));
541 $this->tpl->setContent($c_gui->getHTML());
542 $this->tpl->printToStdout();
543 }
544
545 private function performDeleteMembersCommand(): void
546 {
547 if (!$this->mlists->isOwner($this->mlists->getCurrentMailingList()->getId(), $this->user->getId())) {
548 $this->error->raiseError($this->lng->txt('permission_denied'), $this->error->MESSAGE);
549 }
550
551 if ($this->http->wrapper()->post()->has('a_id') &&
552 ($requested_entry_ids = $this->http->wrapper()->post()->retrieve(
553 'a_id',
554 $this->refinery->kindlyTo()->listOf($this->refinery->kindlyTo()->int())
555 )) !== []) {
556 $assigned_entries = $this->mlists->getCurrentMailingList()->getAssignedEntries();
557 foreach ($requested_entry_ids as $id) {
558 if (isset($assigned_entries[$id])) {
559 $this->mlists->getCurrentMailingList()->deleteEntry($id);
560 }
561 }
562 $this->tpl->setOnScreenMessage(
563 $this->tpl::MESSAGE_TYPE_SUCCESS,
564 $this->lng->txt('mail_success_removed_user'),
565 true
566 );
567 } else {
568 $this->tpl->setOnScreenMessage(
569 $this->tpl::MESSAGE_TYPE_FAILURE,
570 $this->lng->txt('mail_delete_error'),
571 true
572 );
573 }
574
575 $this->ctrl->setParameter($this, 'ml_id', $this->mlists->getCurrentMailingList()->getId());
576 $this->ctrl->redirect($this, 'showMembersList');
577 }
578
579 private function getAssignmentForm(): ?StandardForm
580 {
581 $options = [];
582
583 $relations = ilBuddyList::getInstanceByGlobalUser()->getLinkedRelations();
585 array_keys($relations->toArray()),
586 false,
587 false,
588 '',
589 false,
590 false,
591 false
592 );
593 foreach ($relations as $relation) {
595 $options[$relation->getBuddyUsrId()] = $names[$relation->getBuddyUsrId()];
596 }
597
598 $assigned_entries = $this->mlists->getCurrentMailingList()->getAssignedEntries();
599 foreach ($assigned_entries as $assigned_entry) {
600 if (array_key_exists($assigned_entry['usr_id'], $options)) {
601 unset($options[$assigned_entry['usr_id']]);
602 }
603 }
604
605 if (count($options) > 0) {
606 $user_select = $this->ui_factory->input()->field()->select(
607 $this->lng->txt('mail_entry_of_contacts'),
608 $options
609 );
610
611 $this->ctrl->setParameter($this, 'ml_id', $this->mlists->getCurrentMailingList()->getId());
612 $form = $this->ui_factory->input()->container()->form()->standard(
613 $this->ctrl->getFormAction($this, 'saveAssignmentForm'),
614 ['usr_id' => $user_select]
615 );
616
617 return $form;
618 }
619
620 if (count($relations) > 0) {
621 $this->tpl->setOnScreenMessage(
622 $this->tpl::MESSAGE_TYPE_INFO,
623 $this->lng->txt('mail_mailing_lists_all_contact_entries_assigned'),
624 true
625 );
626
627 $this->ctrl->setParameter($this, 'ml_id', $this->mlists->getCurrentMailingList()->getId());
628 $this->ctrl->redirect($this, 'showMembersList');
629 }
630
631 $this->tpl->setOnScreenMessage(
632 $this->tpl::MESSAGE_TYPE_INFO,
633 $this->lng->txt('mail_mailing_lists_no_contact_entries'),
634 true
635 );
636
637 $this->ctrl->setParameter($this, 'ml_id', $this->mlists->getCurrentMailingList()->getId());
638 $this->ctrl->redirect($this, 'showMembersList');
639 }
640
641 private function saveAssignmentFormCommand(): void
642 {
643 if (!$this->mlists->isOwner($this->mlists->getCurrentMailingList()->getId(), $this->user->getId())) {
644 $this->error->raiseError($this->lng->txt('permission_denied'), $this->error->MESSAGE);
645 }
646
647 $form = $this->getAssignmentForm();
648 if (!$form) {
649 $this->showAssignmentFormCommand($form);
650 return;
651 }
652
653 $form = $form->withRequest($this->http->request());
654 if ($form->getError()) {
655 $this->showAssignmentFormCommand($form);
656 return;
657 }
658 $data = $form->getData();
659
660 if (
661 ilBuddyList::getInstanceByGlobalUser()->getRelationByUserId(
662 $this->refinery->kindlyTo()->int()->transform($data['usr_id'])
663 )->isLinked()
664 ) {
665 $this->mlists->getCurrentMailingList()->assignUser(
666 $this->refinery->kindlyTo()->int()->transform($data['usr_id'])
667 );
668 $this->tpl->setOnScreenMessage(
669 $this->tpl::MESSAGE_TYPE_SUCCESS,
670 $this->lng->txt('saved_successfully'),
671 true
672 );
673
674 $this->ctrl->setParameter($this, 'ml_id', $this->mlists->getCurrentMailingList()->getId());
675 $this->ctrl->redirect($this, 'showMembersList');
676 }
677
678 $this->showAssignmentFormCommand($form);
679 }
680
681 public function showAssignmentFormCommand(?StandardForm $form = null): void
682 {
683 if (!$this->mlists->getCurrentMailingList() || $this->mlists->getCurrentMailingList()->getId() === 0) {
684 $this->showMembersListCommand();
685 return;
686 }
687
688 if (!$this->mlists->isOwner($this->mlists->getCurrentMailingList()->getId(), $this->user->getId())) {
689 $this->error->raiseError($this->lng->txt('permission_denied'), $this->error->MESSAGE);
690 }
691
692 if (!$form instanceof StandardForm) {
693 $form = $this->getAssignmentForm();
694 }
695
696 $this->tpl->setTitle($this->lng->txt('mail_addressbook'));
697 $this->tpl->setContent($this->ui_renderer->render($form));
698 $this->tpl->printToStdout();
699 }
700}
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Definition: plugin.php:23
$relation
Builds data types.
Definition: Factory.php:36
error(string $a_errmsg)
static getInstanceByGlobalUser(?ilObjUser $user=null)
Class ilBuddySystemRelation.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Error Handling & global info handling.
language handling
getUnsafeGetCommands()
This method must return a list of unsafe GET commands.
readonly ILIAS HTTP GlobalHttpState $http
readonly ilCtrlInterface $ctrl
readonly ILIAS UI Renderer $ui_renderer
readonly ilTabsGUI $tabs
readonly ilRbacSystem $rbacsystem
getSafePostCommands()
This method must return a list of safe POST commands.
readonly ilErrorHandling $error
readonly ilFormatMail $umail
readonly ilGlobalTemplateInterface $tpl
readonly ilMailingLists $mlists
readonly ilObjUser $user
readonly ilToolbarGUI $toolbar
readonly ilLanguage $lng
readonly ILIAS UI Factory $ui_factory
showAssignmentFormCommand(?StandardForm $form=null)
readonly Refinery $refinery
User class.
class ilRbacSystem system function like checkAccess, addActiveRole ... Supporting system functions ar...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
static getNamePresentation( $a_user_id, bool $a_user_image=false, bool $a_profile_link=false, string $a_profile_back_link='', bool $a_force_first_lastname=false, bool $a_omit_login=false, bool $a_sortable=true, bool $a_return_data_array=false, $a_ctrl_path=null)
Default behaviour is:
static redirect(string $a_script)
This describes a standard form.
Definition: Standard.php:29
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
static http()
Fetches the global http state from ILIAS.
form( $class_path, string $cmd, string $submit_caption="")
global $DIC
Definition: shib_login.php:26
$counter