ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
class.ilMembershipGUI.php
Go to the documentation of this file.
1 <?php
2 
3 /* Copyright (c) 1998-2010 ILIAS open source, Extended GPL, see docs/LICENSE */
4 
12 {
16  private $repository_object = null;
17 
21  private $repository_gui = null;
22 
26  protected $lng = null;
27 
31  protected $ctrl = null;
32 
36  protected $logger = null;
37 
41  protected $tpl;
42 
46  protected $access;
47 
48 
53  public function __construct(ilObjectGUI $repository_gui, ilObject $repository_obj)
54  {
55  $this->repository_gui = $repository_gui;
56  $this->repository_object = $repository_obj;
57 
58  $this->lng = $GLOBALS['DIC']['lng'];
59  $this->lng->loadLanguageModule('crs');
60  $this->lng->loadLanguageModule($this->getParentObject()->getType());
61 
62  $this->tpl = $GLOBALS['DIC']['tpl'];
63 
64  $this->ctrl = $GLOBALS['DIC']['ilCtrl'];
65 
66  $this->logger = ilLoggerFactory::getLogger($this->getParentObject()->getType());
67 
68  $this->access = $GLOBALS['DIC']->access();
69  }
70 
75  public function getParentGUI()
76  {
77  return $this->repository_gui;
78  }
79 
84  public function getParentObject()
85  {
87  }
88 
93  public function getMembersObject()
94  {
95  if($this->participants instanceof ilParticipants)
96  {
97  return $this->participants;
98  }
99  include_once './Services/Membership/classes/class.ilParticipants.php';
100  return $this->participants = ilParticipants::getInstanceByObjId($this->getParentObject()->getId());
101  }
102 
110  protected function checkPermissionBool($a_permission, $a_cmd = '', $a_type = '', $a_ref_id = 0)
111  {
112  if(!$a_ref_id)
113  {
114  $a_ref_id = $this->getParentObject()->getRefId();
115  }
116  return $this->access->checkAccess($a_permission, $a_cmd, $a_ref_id);
117  }
118 
122  public function executeCommand()
123  {
127  global $ilUser, $ilErr, $ilAccess, $rbacsystem, $ilTabs;
128 
129  $cmd = $this->ctrl->getCmd('participants');
130  $next_class = $this->ctrl->getNextClass();
131 
132  switch($next_class)
133  {
134  case 'ilrepositorysearchgui':
135 
136  include_once('./Services/Search/classes/class.ilRepositorySearchGUI.php');
137  include_once './Services/Membership/classes/class.ilParticipants.php';
138  $rep_search = new ilRepositorySearchGUI();
139 
140  $participants = $this->getMembersObject();
141  if(
142  $participants->isAdmin($GLOBALS['ilUser']->getId()) ||
143  $ilAccess->checkAccess('manage_members','', $this->getParentObject()->getRefId())
144  )
145  {
146  $rep_search->setCallback(
147  $this,
148  'assignMembers',
149  $this->getParentGUI()->getLocalRoles()
150  );
151  }
152  else
153  {
154  //#18445 excludes admin role
155  $rep_search->setCallback(
156  $this,
157  'assignMembers',
158  $this->getLocalRoles(array($this->getParentObject()->getDefaultAdminRole()))
159  );
160  }
161 
162  // Set tabs
163  $this->ctrl->setReturn($this,'participants');
164  $ret = $this->ctrl->forwardCommand($rep_search);
165  break;
166 
167 
168  case 'ilmailmembersearchgui':
169 
170  $ilTabs->clearTargets();
171  $ilTabs->setBackTarget(
172  $this->lng->txt('btn_back'),
173  $this->ctrl->getLinkTarget($this,'')
174  );
175 
176  include_once 'Services/Mail/classes/class.ilMail.php';
177  $mail = new ilMail($ilUser->getId());
178  include_once 'Modules/Course/classes/class.ilCourseConstants.php';
179  if(
180  !(
181  $this->getParentObject()->getMailToMembersType() == ilCourseConstants::MAIL_ALLOWED_ALL ||
182  $ilAccess->checkAccess('manage_members',"",$this->getParentObject()->getRefId())
183  ) || !$rbacsystem->checkAccess('internal_mail',$mail->getMailObjectReferenceId())
184  )
185  {
186  $ilErr->raiseError($this->lng->txt("msg_no_perm_read"),$ilErr->MESSAGE);
187  }
188 
189  include_once './Services/Contact/classes/class.ilMailMemberSearchGUI.php';
190  include_once './Services/Contact/classes/class.ilMailMemberCourseRoles.php';
191 
192  // @todo: fix mail course roles object
193  $mail_search = new ilMailMemberSearchGUI($this, $this->getParentObject()->getRefId(), new ilMailMemberCourseRoles());
194  $mail_search->setObjParticipants(
196  );
197  $this->ctrl->forwardCommand($mail_search);
198  break;
199 
200  case 'ilusersgallerygui':
201 
202  $this->setSubTabs($GLOBALS['ilTabs']);
203  $tabs = $GLOBALS['DIC']->tabs()->setSubTabActive(
204  $this->getParentObject()->getType().'_members_gallery'
205  );
206 
207  $is_admin = (bool)$ilAccess->checkAccess('manage_members', '', $this->getParentObject()->getRefId());
208  $is_participant = (bool)ilParticipants::_isParticipant($this->getParentObject()->getRefId(), $ilUser->getId());
209  if(
210  !$is_admin &&
211  (
212  $this->getParentObject()->getShowMembers() == 0 ||
213  !$is_participant
214  )
215  )
216  {
217  $ilErr->raiseError($this->lng->txt('msg_no_perm_read'), $ilErr->MESSAGE);
218  }
219 
220  $this->showMailToMemberToolbarButton($GLOBALS['ilToolbar'], 'jump2UsersGallery');
221 
222  require_once 'Services/User/classes/class.ilUsersGalleryGUI.php';
223  require_once 'Services/User/classes/class.ilUsersGalleryParticipants.php';
224 
225 
227  $gallery_gui = new ilUsersGalleryGUI($provider);
228  $this->ctrl->forwardCommand($gallery_gui);
229  break;
230 
231  case 'ilcourseparticipantsgroupsgui':
232 
233  $this->setSubTabs($GLOBALS['ilTabs']);
234 
235 
236  include_once './Modules/Course/classes/class.ilCourseParticipantsGroupsGUI.php';
237  $cmg_gui = new ilCourseParticipantsGroupsGUI($this->getParentObject()->getRefId());
238  if($cmd == "show" || $cmd = "")
239  {
240  $this->showMailToMemberToolbarButton($GLOBALS['ilToolbar']);
241  }
242  $this->ctrl->forwardCommand($cmg_gui);
243  break;
244 
245  case 'ilsessionoverviewgui':
246 
247  $this->setSubTabs($GLOBALS['ilTabs']);
248 
249  include_once './Services/Membership/classes/class.ilParticipants.php';
250  $prt = ilParticipants::getInstanceByObjId($this->getParentObject()->getId());
251 
252  include_once('./Modules/Session/classes/class.ilSessionOverviewGUI.php');
253  $overview = new ilSessionOverviewGUI($this->getParentObject()->getRefId(), $prt);
254  $this->ctrl->forwardCommand($overview);
255  break;
256 
257  case 'ilmemberexportgui':
258 
259  $this->setSubTabs($GLOBALS['ilTabs']);
260 
261  include_once('./Services/Membership/classes/Export/class.ilMemberExportGUI.php');
262  $export = new ilMemberExportGUI($this->getParentObject()->getRefId());
263  $this->ctrl->forwardCommand($export);
264  break;
265 
266  case 'ilobjectcustomuserfieldsgui':
267  $this->setSubTabs($GLOBALS['ilTabs']);
268  $this->activateSubTab($this->getParentObject()->getType()."_member_administration");
269  $this->ctrl->setReturn($this,'participants');
270 
271  include_once './Services/Membership/classes/class.ilObjectCustomUserFieldsGUI.php';
272  $cdf_gui = new ilObjectCustomUserFieldsGUI($this->getParentGUI()->object->getId());
273  $this->ctrl->forwardCommand($cdf_gui);
274  break;
275 
276  default:
277  $this->setSubTabs($GLOBALS['DIC']['ilTabs']);
278 
279  //exclude mailMembersBtn cmd from this check
280  if(
281  $cmd != "mailMembersBtn" &&
282  $cmd != 'membersMap'
283  )
284  {
285  $this->checkPermission('manage_members');
286  }
287  else
288  {
289  $this->checkPermission('read');
290  }
291 
292  $this->$cmd();
293  break;
294  }
295  }
296 
300  protected function participants()
301  {
302  $this->initParticipantTemplate();
303  $this->showParticipantsToolbar();
304  $this->activateSubTab($this->getParentObject()->getType()."_member_administration");
305 
306  // show waiting list table
307  $waiting = $this->parseWaitingListTable();
308  if($waiting instanceof ilWaitingListTableGUI)
309  {
310  $this->tpl->setVariable('TABLE_WAIT', $waiting->getHTML());
311  }
312 
313  // show subscriber table
314  $subscriber = $this->parseSubscriberTable();
315  if($subscriber instanceof ilSubscriberTableGUI)
316  {
317  $this->tpl->setVariable('TABLE_SUB', $subscriber->getHTML());
318  }
319 
320  // show member table
321  $table = $this->initParticipantTableGUI();
322  $table->setTitle($this->lng->txt($this->getParentObject()->getType().'_mem_tbl_header'));
323  $table->setFormAction($this->ctrl->getFormAction($this));
324  $table->parse();
325 
326  // filter commands
327  $table->setFilterCommand('participantsApplyFilter');
328  $table->setResetCommand('participantsResetFilter');
329 
330  $this->tpl->setVariable('MEMBERS', $table->getHTML());
331  }
332 
336  protected function participantsApplyFilter()
337  {
338  $table = $this->initParticipantTableGUI();
339  $table->resetOffset();
340  $table->writeFilterToSession();
341 
342  $this->participants();
343  }
344 
348  protected function participantsResetFilter()
349  {
350  $table = $this->initParticipantTableGUI();
351  $table->resetOffset();
352  $table->resetFilter();
353 
354  $this->participants();
355  }
356 
357 
361  protected function editMember()
362  {
363  $this->activateSubTab($this->getParentObject()->getType()."_member_administration");
364  return $this->editParticipants(array($_REQUEST['member_id']));
365  }
366 
371  protected function editParticipants($post_participants = array())
372  {
373  if(!$post_participants)
374  {
375  $post_participants = (array) $_POST['participants'];
376  }
377 
378  $real_participants = $this->getMembersObject()->getParticipants();
379  $participants = array_intersect((array) $post_participants, (array) $real_participants);
380 
381  if(!count($participants))
382  {
383  ilUtil::sendFailure($this->lng->txt('no_checkbox'),true);
384  $this->ctrl->redirect($this,'participants');
385  }
386  $table = $this->initEditParticipantTableGUI($participants);
387  $this->tpl->setContent($table->getHTML());
388  return true;
389  }
390 
398  public function updateParticipants()
399  {
400  global $rbacsystem, $rbacreview, $ilUser, $ilAccess;
401 
402  if(!count($_POST['participants']))
403  {
404  ilUtil::sendFailure($this->lng->txt('no_checkbox'),true);
405  $this->ctrl->redirect($this,'participants');
406  }
407 
408  $notifications = $_POST['notification'] ? $_POST['notification'] : array();
409  $passed = $_POST['passed'] ? $_POST['passed'] : array();
410  $blocked = $_POST['blocked'] ? $_POST['blocked'] : array();
411  $contact = $_POST['contact'] ? $_POST['contact'] : array();
412 
413  // Determine whether the user has the 'edit_permission' permission
414  $hasEditPermissionAccess =
415  (
416  $ilAccess->checkAccess('edit_permission','',$this->getParentObject()->getRefId()) or
417  $this->getMembersObject()->isAdmin($ilUser->getId())
418  );
419 
420  // Get all assignable local roles of the object, and
421  // determine the role id of the course administrator role.
422  $assignableLocalRoles = array();
423  $adminRoleId = $this->getParentObject()->getDefaultAdminRole();
424  foreach ($this->getLocalTypeRole(false) as $title => $role_id)
425  {
426  $assignableLocalRoles[$role_id] = $title;
427  }
428 
429  // Validate the user ids and role ids in the post data
430  foreach($_POST['participants'] as $usr_id)
431  {
432  $memberIsAdmin = $rbacreview->isAssigned($usr_id, $adminRoleId);
433 
434  // If the current user doesn't have the 'edit_permission'
435  // permission, make sure he doesn't remove the course
436  // administrator role of members who are course administrator.
437  if (! $hasEditPermissionAccess && $memberIsAdmin &&
438  ! in_array($adminRoleId, $_POST['roles'][$usr_id])
439  )
440  {
441  $_POST['roles'][$usr_id][] = $adminRoleId;
442  }
443 
444  // Validate the role ids in the post data
445  foreach ((array) $_POST['roles'][$usr_id] as $role_id)
446  {
447  if(!array_key_exists($role_id, $assignableLocalRoles))
448  {
449  ilUtil::sendFailure($this->lng->txt('msg_no_perm_perm'),true);
450  $this->ctrl->redirect($this, 'participants');
451  }
452  if(!$hasEditPermissionAccess &&
453  $role_id == $adminRoleId &&
454  !$memberIsAdmin)
455  {
456  ilUtil::sendFailure($this->lng->txt('msg_no_perm_perm'));
457  $this->ctrl->redirect($this, 'participants');
458  }
459  }
460  }
461 
462  $has_admin = false;
463  foreach($this->getMembersObject()->getAdmins() as $admin_id)
464  {
465  if(!isset($_POST['roles'][$admin_id]))
466  {
467  $has_admin = true;
468  break;
469  }
470  if(in_array($adminRoleId,$_POST['roles'][$admin_id]))
471  {
472  $has_admin = true;
473  break;
474  }
475  }
476 
477  if(!$has_admin)
478  {
479  ilUtil::sendFailure($this->lng->txt($this->getParentObject()->getType().'_min_one_admin'),true);
480  $this->ctrl->redirect($this, 'participants');
481  }
482 
483  foreach($_POST['participants'] as $usr_id)
484  {
485  $this->getMembersObject()->updateRoleAssignments($usr_id,(array) $_POST['roles'][$usr_id]);
486 
487  // Disable notification for all of them
488  $this->getMembersObject()->updateNotification($usr_id,0);
489  if(($this->getMembersObject()->isTutor($usr_id) or $this->getMembersObject()->isAdmin($usr_id)) and in_array($usr_id,$notifications))
490  {
491  $this->getMembersObject()->updateNotification($usr_id,1);
492  }
493 
494  $this->getMembersObject()->updateBlocked($usr_id,0);
495  if((!$this->getMembersObject()->isAdmin($usr_id) and !$this->getMembersObject()->isTutor($usr_id)) and in_array($usr_id,$blocked))
496  {
497  $this->getMembersObject()->updateBlocked($usr_id,1);
498  }
499 
500  if($this instanceof ilCourseMembershipGUI)
501  {
502  $this->getMembersObject()->updatePassed($usr_id,in_array($usr_id,$passed),true);
503  $this->getMembersObject()->sendNotification(
504  $this->getMembersObject()->NOTIFY_STATUS_CHANGED,
505  $usr_id);
506  }
507 
508  if(
509  ($this->getMembersObject()->isAdmin($usr_id) ||
510  $this->getMembersObject()->isTutor($usr_id)) &&
511  in_array($usr_id, $contact)
512  )
513  {
514  $this->getMembersObject()->updateContact($usr_id,TRUE);
515  }
516  else
517  {
518  $this->getMembersObject()->updateContact($usr_id,FALSE);
519  }
520 
521  $this->updateLPFromStatus($usr_id,in_array($usr_id,$passed));
522  }
523  ilUtil::sendSuccess($this->lng->txt("msg_obj_modified"),true);
524  $this->ctrl->redirect($this, "participants");
525  }
526 
530  protected function confirmDeleteParticipants()
531  {
532  global $ilAccess, $ilUser;
533 
534  $participants = (array) $_POST['participants'];
535 
536  if(!count($participants))
537  {
538  ilUtil::sendFailure($this->lng->txt('no_checkbox'),true);
539  $this->ctrl->redirect($this, 'participants');
540  }
541 
542  // Check last admin
543  if(!$this->getMembersObject()->checkLastAdmin($participants))
544  {
545  ilUtil::sendFailure($this->lng->txt($this->getParentObject()->getType().'_at_least_one_admin'),true);
546  $this->ctrl->redirect($this, 'participants');
547  }
548 
549  // Access check for admin deletion
550  if(
551  !$ilAccess->checkAccess(
552  'edit_permission',
553  '',
554  $this->getParentObject()->getRefId()) &&
555  !$this->getMembersObject()->isAdmin($GLOBALS['ilUser']->getId())
556  )
557  {
558  foreach ($participants as $usr_id)
559  {
560  if($this->getMembersObject()->isAdmin($usr_id))
561  {
562  ilUtil::sendFailure($this->lng->txt("msg_no_perm_perm"),true);
563  $this->ctrl->redirect($this, 'participants');
564  }
565  }
566  }
567 
568 
569  include_once('./Services/Utilities/classes/class.ilConfirmationGUI.php');
570  $confirm = new ilConfirmationGUI();
571  $confirm->setFormAction($this->ctrl->getFormAction($this,'confirmDeleteParticipants'));
572  $confirm->setHeaderText($this->lng->txt($this->getParentObject()->getType().'_header_delete_members'));
573  $confirm->setConfirm($this->lng->txt('confirm'),'deleteParticipants');
574  $confirm->setCancel($this->lng->txt('cancel'),'participants');
575 
576  foreach($participants as $usr_id)
577  {
578  $name = ilObjUser::_lookupName($usr_id);
579 
580  $confirm->addItem('participants[]',
581  $name['user_id'],
582  $name['lastname'].', '.$name['firstname'].' ['.$name['login'].']',
583  ilUtil::getImagePath('icon_usr.svg'));
584  }
585 
586  $this->tpl->setContent($confirm->getHTML());
587  }
588 
589  protected function deleteParticipants()
590  {
591  global $rbacreview, $rbacsystem, $ilAccess, $ilUser;
592 
593  $participants = (array) $_POST['participants'];
594 
595  if(!is_array($participants) or !count($participants))
596  {
597  ilUtil::sendFailure($this->lng->txt("no_checkbox"),true);
598  $this->ctrl->redirect($this, 'participants');
599  }
600 
601  // If the user doesn't have the edit_permission and is not administrator, he may not remove
602  // members who have the course administrator role
603  if (
604  !$ilAccess->checkAccess('edit_permission', '', $this->getParentObject()->getRefId()) &&
605  !$this->getMembersObject()->isAdmin($GLOBALS['ilUser']->getId())
606  )
607  {
608  foreach($participants as $part)
609  {
610  if($this->getMembersObject()->isAdmin($part))
611  {
612  ilUtil::sendFailure($this->lng->txt('msg_no_perm_perm'),true);
613  $this->ctrl->redirect($this, 'participants');
614  }
615  }
616  }
617 
618  if(!$this->getMembersObject()->deleteParticipants($participants))
619  {
620  ilUtil::sendFailure('Error deleting participants.', true);
621  $this->ctrl->redirect($this, 'participants');
622  }
623  else
624  {
625  foreach((array) $_POST["participants"] as $usr_id)
626  {
627  $mail_type = 0;
628  // @todo more generic
629  switch($this->getParentObject()->getType())
630  {
631  case 'crs':
632  $mail_type = $this->getMembersObject()->NOTIFY_DISMISS_MEMBER;
633  break;
634  case 'grp':
635  include_once './Modules/Group/classes/class.ilGroupMembershipMailNotification.php';
637  break;
638  }
639  $this->getMembersObject()->sendNotification($mail_type, $usr_id);
640  }
641  }
642  ilUtil::sendSuccess($this->lng->txt($this->getParentObject()->getType()."_members_deleted"), true);
643  $this->ctrl->redirect($this, "participants");
644 
645  return true;
646 
647  }
648 
652  protected function sendMailToSelectedUsers()
653  {
654  if($_POST['participants'])
655  {
656  $participants = (array) $_POST['participants'];
657  }
658  elseif($_GET['member_id'])
659  {
660  $participants = array($_GET['member_id']);
661  }
662  elseif($_POST['subscribers'])
663  {
664  $participants = (array) $_POST['subscribers'];
665  }
666  elseif($_POST['waiting'])
667  {
668  $participants = (array) $_POST['waiting'];
669  }
670 
671  if (!count($participants))
672  {
673  ilUtil::sendFailure($this->lng->txt("no_checkbox"), true);
674  $this->ctrl->redirect($this, 'participants');
675  }
676 
677  foreach($participants as $usr_id)
678  {
679  $rcps[] = ilObjUser::_lookupLogin($usr_id);
680  }
681 
682  require_once 'Services/Mail/classes/class.ilMailFormCall.php';
683  require_once 'Modules/Course/classes/class.ilCourseMailTemplateTutorContext.php';
684 
688  $this,
689  'participants',
690  array(),
691  array(
692  'type' => 'new',
693  'sig' => $this->createMailSignature()
694  ),
695  array(
697  'ref_id' => $this->getParentObject()->getRefId(),
698  'ts' => time()
699  )
700  )
701  );
702  }
703 
707  protected function membersMap()
708  {
709  global $tpl;
710  $this->activateSubTab($this->getParentObject()->getType()."_members_map");
711  include_once("./Services/Maps/classes/class.ilMapUtil.php");
712  if (!ilMapUtil::isActivated() || !$this->getParentObject()->getEnableMap())
713  {
714  return;
715  }
716 
717  $map = ilMapUtil::getMapGUI();
718  $map->setMapId("course_map")
719  ->setWidth("700px")
720  ->setHeight("500px")
721  ->setLatitude($this->getParentObject()->getLatitude())
722  ->setLongitude($this->getParentObject()->getLongitude())
723  ->setZoom($this->getParentObject()->getLocationZoom())
724  ->setEnableTypeControl(true)
725  ->setEnableNavigationControl(true)
726  ->setEnableCentralMarker(true);
727 
728  include_once './Services/Membership/classes/class.ilParticipants.php';
729  $members = ilParticipants::getInstanceByObjId($this->getParentObject()->getId())->getParticipants();
730  foreach((array) $members as $user_id)
731  {
732  $map->addUserMarker($user_id);
733  }
734 
735  $tpl->setContent($map->getHTML());
736  $tpl->setLeftContent($map->getUserListHTML());
737  }
738 
743  protected function mailMembersBtn()
744  {
745  global $ilToolbar;
746 
747  $this->showMailToMemberToolbarButton($GLOBALS['ilToolbar'], 'mailMembersBtn');
748  }
749 
750 
751 
752 
756  protected function showParticipantsToolbar()
757  {
758  global $ilToolbar;
759 
760  include_once './Services/Search/classes/class.ilRepositorySearchGUI.php';
762  $this,
763  $ilToolbar,
764  array(
765  'auto_complete_name' => $this->lng->txt('user'),
766  'user_type' => $this->getParentGUI()->getLocalRoles(),
767  'user_type_default' => $this->getDefaultRole(),
768  'submit_name' => $this->lng->txt('add')
769  )
770  );
771 
772  // spacer
773  $ilToolbar->addSeparator();
774 
775  // search button
776  $ilToolbar->addButton(
777  $this->lng->txt($this->getParentObject()->getType()."_search_users"),
778  $this->ctrl->getLinkTargetByClass(
779  'ilRepositorySearchGUI',
780  'start')
781  );
782 
783  // separator
784  $ilToolbar->addSeparator();
785 
786  // print button
787  $ilToolbar->addButton(
788  $this->lng->txt($this->getParentObject()->getType(). "_print_list"),
789  $this->ctrl->getLinkTarget($this, 'printMembers'));
790 
791  $this->showMailToMemberToolbarButton($ilToolbar, 'participants', false);
792  }
793 
794 
795 
799  protected function showMailToMemberToolbarButton(ilToolbarGUI $toolbar, $a_back_cmd = null, $a_separator = false)
800  {
801  global $ilUser, $rbacsystem, $ilAccess;
802  include_once 'Services/Mail/classes/class.ilMail.php';
803  $mail = new ilMail($ilUser->getId());
804 
805  if(
806  ($this->getParentObject()->getMailToMembersType() == 1) ||
807  (
808  $ilAccess->checkAccess('manage_members',"",$this->getParentObject()->getRefId()) &&
809  $rbacsystem->checkAccess('internal_mail',$mail->getMailObjectReferenceId())
810  )
811  )
812  {
813 
814  if($a_separator)
815  {
816  $toolbar->addSeparator();
817  }
818 
819  if($a_back_cmd)
820  {
821  $this->ctrl->setParameter($this, "back_cmd", $a_back_cmd);
822  }
823 
824  $toolbar->addButton(
825  $this->lng->txt("mail_members"),
826  $this->ctrl->getLinkTargetByClass('ilMailMemberSearchGUI','')
827  );
828  }
829  }
830 
835  public function createMailSignature()
836  {
837  return $this->getParentGUI()->createMailSignature();
838  }
839 
844  public function addMemberTab(ilTabsGUI $tabs, $a_is_participant = false)
845  {
846  global $ilAccess;
847 
848  include_once './Services/Mail/classes/class.ilMail.php';
849  $mail = new ilMail($GLOBALS['ilUser']->getId());
850 
851  if($ilAccess->checkAccess('manage_members', '' , $this->getParentObject()->getRefId()))
852  {
853  $tabs->addTab(
854  'members',
855  $this->lng->txt('members'),
856  $this->ctrl->getLinkTarget($this,'')
857  );
858  }
859  elseif(
860  (bool) $this->getParentObject()->getShowMembers() && $a_is_participant
861  )
862  {
863  $tabs->addTab(
864  'members',
865  $this->lng->txt('members'),
866  $this->ctrl->getLinkTargetByClass(array(get_class($this),'ilusersgallerygui'), 'view')
867  );
868  }
869  elseif(
870  $this->getParentObject()->getMailToMembersType() == 1 &&
871  $GLOBALS['rbacsystem']->checkAccess('internal_mail',$mail->getMailObjectReferenceId ()) &&
872  $a_is_participant
873  )
874  {
875  $tabs->addTab(
876  'members',
877  $this->lng->txt('members'),
878  $this->ctrl->getLinkTarget($this, "mailMembersBtn")
879  );
880  }
881  }
882 
886  protected function setSubTabs(ilTabsGUI $tabs)
887  {
888  global $ilAccess;
889 
890  if($ilAccess->checkAccess('manage_members','',$this->getParentObject()->getRefId()))
891  {
892  $tabs->addSubTabTarget(
893  $this->getParentObject()->getType()."_member_administration",
894  $this->ctrl->getLinkTarget($this,'participants'),
895  "members",
896  get_class($this)
897  );
898 
899  // show group overview
900  if($this instanceof ilCourseMembershipGUI)
901  {
902  $tabs->addSubTabTarget(
903  "crs_members_groups",
904  $this->ctrl->getLinkTargetByClass("ilCourseParticipantsGroupsGUI", "show"),
905  "",
906  "ilCourseParticipantsGroupsGUI"
907  );
908  }
909 
910  $childs = (array) $GLOBALS['tree']->getChildsByType($this->getParentObject()->getRefId(),'sess');
911  if(count($childs))
912  {
913  $tabs->addSubTabTarget(
914  'events',
915  $this->ctrl->getLinkTargetByClass(array(get_class($this),'ilsessionoverviewgui'),'listSessions'),
916  '',
917  'ilsessionoverviewgui'
918  );
919  }
920 
921  $tabs->addSubTabTarget(
922  $this->getParentObject()->getType().'_members_gallery',
923  $this->ctrl->getLinkTargetByClass(array(get_class($this),'ilUsersGalleryGUI')),
924  'view',
925  'ilUsersGalleryGUI'
926  );
927  }
928  else if($this->getParentObject()->getShowMembers())
929  {
930  // gallery
931  $tabs->addSubTabTarget(
932  $this->getParentObject()->getType().'_members_gallery',
933  $this->ctrl->getLinkTargetByClass(array(get_class($this),'ilUsersGalleryGUI')),
934  'view',
935  'ilUsersGalleryGUI'
936  );
937  }
938 
939  include_once './Services/Maps/classes/class.ilMapUtil.php';
940  if(ilMapUtil::isActivated() && $this->getParentObject()->getEnableMap())
941  {
942  $tabs->addSubTabTarget(
943  $this->getParentObject()->getType().'_members_map',
944  $this->ctrl->getLinkTarget($this,'membersMap'),
945  "membersMap",
946  get_class($this)
947  );
948  }
949 
950  include_once 'Services/PrivacySecurity/classes/class.ilPrivacySettings.php';
951  if(ilPrivacySettings::_getInstance()->checkExportAccess($this->getParentObject()->getRefId()))
952  {
953  $tabs->addSubTabTarget(
954  'export_members',
955  $this->ctrl->getLinkTargetByClass(array(get_class($this),'ilmemberexportgui'),'show'),
956  '',
957  'ilmemberexportgui'
958  );
959  }
960  }
961 
967  public function readMemberData(array $usr_ids, array $columns)
968  {
969  return $this->getParentGUI()->readMemberData($usr_ids, $columns);
970  }
971 
976  public function getLocalRoles()
977  {
978  return $this->getParentGUI()->getLocalRoles();
979  }
980 
984  protected function parseSubscriberTable()
985  {
986  if(!$this->getMembersObject()->getSubscribers())
987  {
988  ilLoggerFactory::getLogger('mmbr')->debug('No subscriber found');
989  return null;
990  }
991  include_once './Services/Membership/classes/class.ilSubscriberTableGUI.php';
992  $subscriber = new ilSubscriberTableGUI($this, $this->getParentObject(),true);
993  $subscriber->setTitle($this->lng->txt('group_new_registrations'));
994  $subscriber->readSubscriberData();
995  return $subscriber;
996  }
997 
1002  public function confirmAssignSubscribers()
1003  {
1004  if(!is_array($_POST["subscribers"]))
1005  {
1006  ilUtil::sendFailure($this->lng->txt("crs_no_subscribers_selected"),true);
1007  $this->ctrl->redirect($this, 'participants');
1008  }
1009 
1010  include_once("Services/Utilities/classes/class.ilConfirmationGUI.php");
1011  $c_gui = new ilConfirmationGUI();
1012 
1013  // set confirm/cancel commands
1014  $c_gui->setFormAction($this->ctrl->getFormAction($this, "assignSubscribers"));
1015  $c_gui->setHeaderText($this->lng->txt("info_assign_sure"));
1016  $c_gui->setCancel($this->lng->txt("cancel"), "participants");
1017  $c_gui->setConfirm($this->lng->txt("confirm"), "assignSubscribers");
1018 
1019  foreach($_POST["subscribers"] as $subscribers)
1020  {
1021  $name = ilObjUser::_lookupName($subscribers);
1022 
1023  $c_gui->addItem('subscribers[]',
1024  $name['user_id'],
1025  $name['lastname'].', '.$name['firstname'].' ['.$name['login'].']',
1026  ilUtil::getImagePath('icon_usr.svg'));
1027  }
1028 
1029  $this->tpl->setContent($c_gui->getHTML());
1030  return true;
1031  }
1032 
1037  public function confirmRefuseSubscribers()
1038  {
1039  if(!is_array($_POST["subscribers"]))
1040  {
1041  ilUtil::sendFailure($this->lng->txt("crs_no_subscribers_selected"),true);
1042  $this->ctrl->redirect($this, 'participants');
1043  }
1044 
1045  $this->lng->loadLanguageModule('mmbr');
1046 
1047  include_once("Services/Utilities/classes/class.ilConfirmationGUI.php");
1048  $c_gui = new ilConfirmationGUI();
1049 
1050  // set confirm/cancel commands
1051  $c_gui->setFormAction($this->ctrl->getFormAction($this, "refuseSubscribers"));
1052  $c_gui->setHeaderText($this->lng->txt("info_refuse_sure"));
1053  $c_gui->setCancel($this->lng->txt("cancel"), "participants");
1054  $c_gui->setConfirm($this->lng->txt("confirm"), "refuseSubscribers");
1055 
1056  foreach($_POST["subscribers"] as $subscribers)
1057  {
1058  $name = ilObjUser::_lookupName($subscribers);
1059 
1060  $c_gui->addItem('subscribers[]',
1061  $name['user_id'],
1062  $name['lastname'].', '.$name['firstname'].' ['.$name['login'].']',
1063  ilUtil::getImagePath('icon_usr.svg'));
1064  }
1065 
1066  $this->tpl->setContent($c_gui->getHTML());
1067  return true;
1068  }
1069 
1075  protected function refuseSubscribers()
1076  {
1077  global $rbacsystem;
1078 
1079  if(!$_POST['subscribers'])
1080  {
1081  ilUtil::sendFailure($this->lng->txt("crs_no_subscribers_selected"),true);
1082  $this->ctrl->redirect($this, 'participants');
1083  }
1084 
1085  if(!$this->getMembersObject()->deleteSubscribers($_POST["subscribers"]))
1086  {
1087  ilUtil::sendFailure($GLOBALS['ilErr']->getMessage(),true);
1088  $this->ctrl->redirect($this, 'participants');
1089  }
1090  else
1091  {
1092  foreach($_POST['subscribers'] as $usr_id)
1093  {
1094  if($this instanceof ilCourseMembershipGUI)
1095  {
1096  $this->getMembersObject()->sendNotification($this->getMembersObject()->NOTIFY_DISMISS_SUBSCRIBER, $usr_id);
1097  }
1098  else
1099  {
1100  include_once './Modules/Group/classes/class.ilGroupMembershipMailNotification.php';
1101  $this->getMembersObject()->sendNotification(
1103  $usr_id
1104  );
1105  }
1106  }
1107  }
1108 
1109  ilUtil::sendSuccess($this->lng->txt("crs_subscribers_deleted"),true);
1110  $this->ctrl->redirect($this, 'participants');
1111  }
1112 
1119  public function assignSubscribers()
1120  {
1121  global $ilErr;
1122 
1123  if(!is_array($_POST["subscribers"]))
1124  {
1125  ilUtil::sendFailure($this->lng->txt("crs_no_subscribers_selected"),true);
1126  $this->ctrl->redirect($this, 'participants');
1127  }
1128 
1129  if(!$this->getMembersObject()->assignSubscribers($_POST["subscribers"]))
1130  {
1131  $this->object->members_obj->add($usr_id,IL_GRP_MEMBER);
1132  $this->object->members_obj->deleteSubscriber($usr_id);
1133 
1134 
1135 
1136  ilUtil::sendFailure($ilErr->getMessage(),true);
1137  $this->ctrl->redirect($this, 'participants');
1138  }
1139  else
1140  {
1141  foreach($_POST["subscribers"] as $usr_id)
1142  {
1143  if($this instanceof ilCourseMembershipGUI)
1144  {
1145  $this->getMembersObject()->sendNotification($this->getMembersObject()->NOTIFY_ACCEPT_SUBSCRIBER, $usr_id);
1146  $this->getParentObject()->checkLPStatusSync($usr_id);
1147  }
1148  else
1149  {
1150  include_once './Modules/Group/classes/class.ilGroupMembershipMailNotification.php';
1151  $this->getMembersObject()->sendNotification(
1153  $usr_id
1154  );
1155  }
1156  }
1157  }
1158  ilUtil::sendSuccess($this->lng->txt("crs_subscribers_assigned"),true);
1159  $this->ctrl->redirect($this, 'participants');
1160  }
1161 
1166  protected function parseWaitingListTable()
1167  {
1168  $wait = $this->initWaitingList();
1169 
1170  if(!$wait->getCountUsers())
1171  {
1172  return null;
1173  }
1174 
1175  include_once './Services/Membership/classes/class.ilWaitingListTableGUI.php';
1176  $waiting_table = new ilWaitingListTableGUI($this, $this->getParentObject(), $wait);
1177  $waiting_table->setUsers($wait->getAllUsers());
1178  $waiting_table->setTitle($this->lng->txt('crs_waiting_list'));
1179 
1180  return $waiting_table;
1181  }
1182 
1188  {
1189  if(!is_array($_POST["waiting"]))
1190  {
1191  ilUtil::sendFailure($this->lng->txt("crs_no_users_selected"),true);
1192  $this->ctrl->redirect($this,'participants');
1193  }
1194 
1195 
1196  include_once("Services/Utilities/classes/class.ilConfirmationGUI.php");
1197  $c_gui = new ilConfirmationGUI();
1198 
1199  // set confirm/cancel commands
1200  $c_gui->setFormAction($this->ctrl->getFormAction($this, "assignFromWaitingList"));
1201  $c_gui->setHeaderText($this->lng->txt("info_assign_sure"));
1202  $c_gui->setCancel($this->lng->txt("cancel"), "participants");
1203  $c_gui->setConfirm($this->lng->txt("confirm"), "assignFromWaitingList");
1204 
1205  foreach($_POST["waiting"] as $waiting)
1206  {
1207  $name = ilObjUser::_lookupName($waiting);
1208 
1209  $c_gui->addItem('waiting[]',
1210  $name['user_id'],
1211  $name['lastname'].', '.$name['firstname'].' ['.$name['login'].']',
1212  ilUtil::getImagePath('icon_usr.svg'));
1213  }
1214 
1215  $this->tpl->setContent($c_gui->getHTML());
1216  return true;
1217  }
1218 
1224  public function assignFromWaitingList()
1225  {
1226  if(!count($_POST["waiting"]))
1227  {
1228  ilUtil::sendFailure($this->lng->txt("crs_no_users_selected"),true);
1229  $this->ctrl->redirect($this,'participants');
1230  }
1231 
1232  $waiting_list = $this->initWaitingList();
1233 
1234  $added_users = 0;
1235  foreach($_POST["waiting"] as $user_id)
1236  {
1237  if(!$tmp_obj = ilObjectFactory::getInstanceByObjId($user_id,false))
1238  {
1239  continue;
1240  }
1241  if($this->getMembersObject()->isAssigned($user_id))
1242  {
1243  continue;
1244  }
1245 
1246  if($this instanceof ilCourseMembershipGUI)
1247  {
1248  $this->getMembersObject()->add($user_id,IL_CRS_MEMBER);
1249  $this->getMembersObject()->sendNotification($this->getMembersObject()->NOTIFY_ACCEPT_USER,$user_id,true);
1250  $this->getParentObject()->checkLPStatusSync($user_id);
1251  }
1252  else
1253  {
1254  include_once './Modules/Group/classes/class.ilGroupMembershipMailNotification.php';
1255  $this->getMembersObject()->add($user_id,IL_GRP_MEMBER);
1256  $this->getMembersObject()->sendNotification(
1258  $user_id,
1259  true
1260  );
1261  }
1262  $waiting_list->removeFromList($user_id);
1263  ++$added_users;
1264  }
1265 
1266  if($added_users)
1267  {
1268  ilUtil::sendSuccess($this->lng->txt("crs_users_added"),true);
1269  $this->ctrl->redirect($this, 'participants');
1270  }
1271  else
1272  {
1273  ilUtil::sendFailure($this->lng->txt("crs_users_already_assigned"),true);
1274  $this->ctrl->redirect($this, 'participants');
1275  }
1276  }
1277 
1282  public function confirmRefuseFromList()
1283  {
1284  if(!is_array($_POST["waiting"]))
1285  {
1286  ilUtil::sendFailure($this->lng->txt("no_checkbox"),true);
1287  $this->ctrl->redirect($this, 'participants');
1288  }
1289 
1290  $this->lng->loadLanguageModule('mmbr');
1291 
1292  include_once("Services/Utilities/classes/class.ilConfirmationGUI.php");
1293  $c_gui = new ilConfirmationGUI();
1294 
1295  // set confirm/cancel commands
1296  $c_gui->setFormAction($this->ctrl->getFormAction($this, "refuseFromList"));
1297  $c_gui->setHeaderText($this->lng->txt("info_refuse_sure"));
1298  $c_gui->setCancel($this->lng->txt("cancel"), "participants");
1299  $c_gui->setConfirm($this->lng->txt("confirm"), "refuseFromList");
1300 
1301  foreach($_POST["waiting"] as $waiting)
1302  {
1303  $name = ilObjUser::_lookupName($waiting);
1304 
1305  $c_gui->addItem('waiting[]',
1306  $name['user_id'],
1307  $name['lastname'].', '.$name['firstname'].' ['.$name['login'].']',
1308  ilUtil::getImagePath('icon_usr.svg'));
1309  }
1310 
1311  $this->tpl->setContent($c_gui->getHTML());
1312  return true;
1313  }
1314 
1321  protected function refuseFromList()
1322  {
1323  global $ilUser;
1324 
1325  if(!count($_POST['waiting']))
1326  {
1327  ilUtil::sendFailure($this->lng->txt('no_checkbox'),true);
1328  $this->ctrl->redirect($this, 'participants');
1329  }
1330 
1331  $waiting_list = $this->initWaitingList();
1332 
1333  foreach($_POST["waiting"] as $user_id)
1334  {
1335  $waiting_list->removeFromList($user_id);
1336 
1337  if($this instanceof ilCourseWaitingList)
1338  {
1339  $this->getMembersObject()->sendNotification($this->getMembersObject()->NOTIFY_DISMISS_SUBSCRIBER,$user_id,true);
1340  }
1341  else
1342  {
1343  include_once './Modules/Group/classes/class.ilGroupMembershipMailNotification.php';
1344  $this->getMembersObject()->sendNotification(
1346  $user_id,
1347  true
1348  );
1349  }
1350 
1351  }
1352  ilUtil::sendSuccess($this->lng->txt('crs_users_removed_from_list'),true);
1353  $this->ctrl->redirect($this, 'participants');
1354  }
1355 
1359  protected function addToClipboard()
1360  {
1361  $users = (array) $_POST['participants'];
1362  if(!count($users))
1363  {
1364  ilUtil::sendFailure($this->lng->txt('select_one'),true);
1365  $this->ctrl->redirect($this, 'participants');
1366  }
1367  include_once './Services/User/classes/class.ilUserClipboard.php';
1368  $clip = ilUserClipboard::getInstance($GLOBALS['ilUser']->getId());
1369  $clip->add($users);
1370  $clip->save();
1371 
1372  $this->lng->loadLanguageModule('user');
1373  ilUtil::sendSuccess($this->lng->txt('clipboard_user_added'),true);
1374  $this->ctrl->redirect($this, 'participants');
1375 
1376  }
1377 
1381  protected function getDefaultRole()
1382  {
1383  return null;
1384  }
1385 
1389  protected function activateSubTab($a_sub_tab)
1390  {
1394  $tabs = $GLOBALS['DIC']['ilTabs'];
1395  $tabs->activateSubTab($a_sub_tab);
1396  }
1397 
1405  protected function checkPermission($a_permission, $a_cmd = "")
1406  {
1410  $ilAccess = $GLOBALS['DIC']['ilAccess'];
1411 
1412  if(!$ilAccess->checkAccess($a_permission, $a_cmd, $this->getParentGUI()->ref_id))
1413  {
1414  ilUtil::sendFailure($this->lng->txt('no_permission'), true);
1415  $this->ctrl->redirect($this->getParentGUI());
1416  }
1417  }
1418 
1423  protected function printMembers()
1424  {
1425  global $ilTabs;
1426 
1427  $this->checkPermission('manage_members');
1428 
1429  $ilTabs->clearTargets();
1430  $ilTabs->setBackTarget(
1431  $this->lng->txt('back'),
1432  $this->ctrl->getLinkTarget($this, 'participants'));
1433 
1434  $list = $this->initAttendanceList();
1435  $form = $list->initForm('printMembersOutput');
1436  $this->tpl->setContent($form->getHTML());
1437 
1438  }
1439 
1443  protected function printMembersOutput()
1444  {
1445  $list = $this->initAttendanceList();
1446  $list->initFromForm();
1447  $list->setCallback(array($this, 'getAttendanceListUserData'));
1448  $this->member_data = $this->getPrintMemberData($this->getMembersObject()->getParticipants());
1449  $list->getNonMemberUserData($this->member_data);
1450 
1451  $list->getFullscreenHTML();
1452  exit();
1453  }
1454 
1455 
1456 
1460  protected function initAttendanceList()
1461  {
1465  $waiting_list = $this->initWaitingList();
1466 
1467 
1468  include_once 'Services/Membership/classes/class.ilAttendanceList.php';
1469  $list = new ilAttendanceList(
1470  $this,
1471  $this->getParentObject(),
1472  $this->getMembersObject(),
1473  $waiting_list
1474  );
1475  $list->setId($this->getParentObject()->getType().'_memlist_'.$this->getParentObject()->getId());
1476 
1477  $list->setTitle(
1478  $this->lng->txt($this->getParentObject()->getType().'_members_print_title'),
1479  $this->lng->txt('obj_'. $this->getParentObject()->getType()).': '.$this->getParentObject()->getTitle());
1480 
1481  include_once './Services/Tracking/classes/class.ilObjUserTracking.php';
1482  $show_tracking =
1484  if($show_tracking)
1485  {
1486  include_once('./Services/Object/classes/class.ilObjectLP.php');
1487  $olp = ilObjectLP::getInstance($this->getParentObject()->getId());
1488  $show_tracking = $olp->isActive();
1489  }
1490  if($show_tracking)
1491  {
1492  $list->addPreset('progress', $this->lng->txt('learning_progress'), true);
1493  }
1494 
1495  include_once('./Services/PrivacySecurity/classes/class.ilPrivacySettings.php');
1499  $privacy = ilPrivacySettings::_getInstance();
1500  if($privacy->enabledAccessTimesByType($this->getParentObject()->getType()))
1501  {
1502  $list->addPreset('access', $this->lng->txt('last_access'), true);
1503  }
1504 
1505  switch($this->getParentObject()->getType())
1506  {
1507  case 'crs':
1508  $list->addPreset('status', $this->lng->txt('crs_status'), true);
1509  $list->addPreset('passed', $this->lng->txt('crs_passed'), true);
1510  break;
1511 
1512  case 'grp':
1513  default:
1514  break;
1515  }
1516 
1517  return $list;
1518 
1519  }
1520 
1521 
1522 
1523 }
1524 ?>
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
static _lookupLogin($a_user_id)
lookup login
static _lookupName($a_user_id)
lookup user name
static _isParticipant($a_ref_id, $a_usr_id)
Static function to check if a user is a participant of the container object.
readMemberData(array $usr_ids, array $columns)
Required for member table guis.
global $ilErr
Definition: raiseError.php:16
Class ilCourseParticipantsGroupsGUI.
setSubTabs(ilTabsGUI $tabs)
Set sub tabs.
Base class for member tab content.
confirmDeleteParticipants()
Show confirmation screen for participants deletion.
static getInstance($a_usr_id)
Get singelton instance.
printMembersOutput()
print members output
addToClipboard()
Add selected users to user clipboard.
Tabs GUI.
printMembers()
Print members.
getMembersObject()
Get member object.
$_GET["client_id"]
addButton($a_txt, $a_cmd, $a_target="", $a_acc_key="", $a_additional_attrs='', $a_id="", $a_class='submit')
Add button to toolbar.
updateParticipants()
update members
Class ilObject Basic functions for all objects.
assignFromWaitingList()
Assign from waiting list type $rbacsystem.
checkPermissionBool($a_permission, $a_cmd='', $a_type='', $a_ref_id=0)
Check permission.
$GLOBALS['loaded']
Global hash that tracks already loaded includes.
$cmd
Definition: sahs_server.php:35
participantsResetFilter()
reset participants filter
ilUsersGalleryGUI: ilPublicUserProfileGUI ilUsersGalleryGUI: ilCourseMembershipGUI, ilGroupMembershipGUI
confirmAssignSubscribers()
Show subscription confirmation.
editMember()
Edit one participant.
__construct(ilObjectGUI $repository_gui, ilObject $repository_obj)
Constructor.
Class ilMailMemberSearchGUI.
const IL_GRP_MEMBER
parseWaitingListTable()
Parse table of subscription request.
Base class for attendance lists.
getLocalRoles()
Get parent roles.
const IL_CRS_MEMBER
refuseSubscribers()
Refuse subscribers type $rbacsystem.
showMailToMemberToolbarButton(ilToolbarGUI $toolbar, $a_back_cmd=null, $a_separator=false)
Show mail to member toolbar button.
$a_type
Definition: workflow.php:93
static _enabledUserRelatedData()
check wether user related tracking is enabled or not
static _enabledLearningProgress()
check wether learing progress is enabled or not
static getMapGUI()
Get an instance of the GUI class.
Class ilMailMemberCourseRoles.
assignSubscribers()
Do assignment of subscription request type $rbacsystem type $ilErr.
addSubTabTarget($a_text, $a_link, $a_cmd="", $a_cmdClass="", $a_frame="", $a_activate=false, $a_dir_text=false)
DEPRECATED.
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)
This class handles base functions for mail handling.
Class ilObjectGUI Basic methods of all Output classes.
GUI class for course/group subscriptions.
$ilUser
Definition: imgupload.php:18
sendMailToSelectedUsers()
Send mail to selected users.
getParentGUI()
Get parent gui.
addSeparator()
Add separator.
confirmAssignFromWaitingList()
Assign from waiting list (confirmatoin)
static getInstanceByObjId($a_obj_id, $stop_on_error=true)
get an instance of an Ilias object by object id
Class ilUsersGalleryParticipants.
Create styles array
The data for the language used.
showParticipantsToolbar()
Show participants toolbar.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
const CONTEXT_KEY
Session parameter for the context.
confirmRefuseSubscribers()
Refuse subscriber confirmation.
static isActivated()
Checks whether Map feature is activated.
parseSubscriberTable()
Parse table of subscription request.
Create new PHPExcel object
obj_idprivate
mailMembersBtn()
Mail to members view type $ilToolbar.
static getRedirectTarget($gui, $cmd, array $gui_params=array(), array $mail_params=array(), array $context_params=array())
$ret
Definition: parser.php:6
GUI class for course/group waiting list.
addMemberTab(ilTabsGUI $tabs, $a_is_participant=false)
add member tab
participants()
Show participant table, subscriber table, wating list table;.
addTab($a_id, $a_text, $a_link, $a_frame="")
Add a Tab.
refuseFromList()
refuse from waiting list
static setRecipients(array $recipients)
static getLogger($a_component_id)
Get component logger.
membersMap()
Members map.
static _getInstance()
Get instance of ilPrivacySettings.
Add data(end) time
Method that wraps PHPs time in order to allow simulations with the workflow.
static fillAutoCompleteToolbar($parent_object, ilToolbarGUI $toolbar=null, $a_options=array(), $a_sticky=false)
fill toolbar with
getParentObject()
Get parent object.
editParticipants($post_participants=array())
Edit participants.
confirmRefuseFromList()
Refuse from waiting list (confirmation)
static redirect($a_script)
http redirect to other script
static getInstance($a_obj_id)
if(! $in) $columns
Definition: Utf8Test.php:45
$_POST["username"]
static getInstanceByObjId($a_obj_id)
Get instance by obj type.
participantsApplyFilter()
Apply filter for participant table.
Confirmation screen class.