ILIAS  release_7 Revision v7.30-3-g800a261c036
class.ilObjSession.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
5include_once('./Modules/Session/classes/class.ilSessionAppointment.php');
6include_once './Services/Membership/classes/class.ilMembershipRegistrationSettings.php';
7
17{
20
21 const LOCAL_ROLE_PARTICIPANT_PREFIX = 'il_sess_participant';
22
23 const CAL_REG_START = 1;
24
25 protected $db;
26
27 protected $location;
28 protected $name;
29 protected $phone;
30 protected $email;
31 protected $details;
32 protected $registration;
33 protected $event_id;
34
36 protected $reg_limited = 0;
37 protected $reg_min_users = 0;
38 protected $reg_limited_users = 0;
39 protected $reg_waiting_list = 0;
40 protected $reg_waiting_list_autofill; // [bool]
41
45 protected $show_members = false;
46
51
56
57 protected $appointments;
58 protected $files = array();
59
63 protected $session_logger = null;
64
68 protected $members_obj;
69
72
79 public function __construct($a_id = 0, $a_call_by_reference = true)
80 {
81 global $DIC;
82
83 $ilDB = $DIC['ilDB'];
84
85 $this->session_logger = $GLOBALS['DIC']->logger()->sess();
86
87 $this->db = $ilDB;
88 $this->type = "sess";
89 parent::__construct($a_id, $a_call_by_reference);
90 }
91
100 public static function _lookupRegistrationEnabled($a_obj_id)
101 {
102 global $DIC;
103
104 $ilDB = $DIC['ilDB'];
105
106 $query = "SELECT reg_type FROM event " .
107 "WHERE obj_id = " . $ilDB->quote($a_obj_id, 'integer') . " ";
108 $res = $ilDB->query($query);
109 while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
110 return (bool) $row->reg_type != ilMembershipRegistrationSettings::TYPE_NONE;
111 }
112 return false;
113 }
114
120 public static function lookupSession($a_obj_id)
121 {
122 global $DIC;
123
124 $ilDB = $DIC['ilDB'];
125
126 $query = "SELECT * FROM event " .
127 "WHERE obj_id = " . $ilDB->quote($a_obj_id);
128 $res = $ilDB->query($query);
129 while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
130 $data['location'] = $row->location ? $row->location : '';
131 $data['details'] = $row->details ? $row->details : '';
132 $data['name'] = $row->tutor_name ? $row->tutor_name : '';
133 $data['email'] = $row->tutor_email ? $row->tutor_email : '';
134 $data['phone'] = $row->tutor_phone ? $row->tutor_phone : '';
135 }
136 return (array) $data;
137 }
138
146 public function getPresentationTitle()
147 {
148 $date = new ilDate($this->getFirstAppointment()->getStart()->getUnixTime(), IL_CAL_UNIX);
149 if ($this->getTitle()) {
150 return ilDatePresentation::formatDate($this->getFirstAppointment()->getStart()) . ': ' . $this->getTitle();
151 } else {
152 return ilDatePresentation::formatDate($date);
153 }
154 }
155
160 {
161 $title = '';
162 if ($this->getTitle()) {
163 $title = ': ' . $this->getTitle();
164 }
166 $this->getFirstAppointment()->getStart(),
167 $this->getFirstAppointment()->getEnd()
168 ) . $title;
169 }
170
174 public function initDefaultRoles()
175 {
176 include_once './Services/AccessControl/classes/class.ilObjRole.php';
178 self::LOCAL_ROLE_PARTICIPANT_PREFIX . '_' . $this->getRefId(),
179 'Participant of session obj_no.' . $this->getId(),
180 self::LOCAL_ROLE_PARTICIPANT_PREFIX,
181 $this->getRefId()
182 );
183
184 if (!$role instanceof ilObjRole) {
185 $this->session_logger->warning('Could not create default session role.');
186 $this->session_logger->logStack(ilLogLevel::WARNING);
187 }
188 return array();
189 }
190
197 public function getEventId()
198 {
199 return $this->event_id;
200 }
201
208 public function setLocation($a_location)
209 {
210 $this->location = $a_location;
211 }
212
219 public function getLocation()
220 {
221 return $this->location;
222 }
223
230 public function setName($a_name)
231 {
232 $this->name = $a_name;
233 }
234
241 public function getName()
242 {
243 return $this->name;
244 }
245
252 public function setPhone($a_phone)
253 {
254 $this->phone = $a_phone;
255 }
256
263 public function getPhone()
264 {
265 return $this->phone;
266 }
267
275 public function setEmail($a_email)
276 {
277 $this->email = $a_email;
278 }
279
286 public function getEmail()
287 {
288 return $this->email;
289 }
290
296 public function hasTutorSettings()
297 {
298 return strlen($this->getName()) or
299 strlen($this->getEmail()) or
300 strlen($this->getPhone());
301 }
302
303
310 public function setDetails($a_details)
311 {
312 $this->details = $a_details;
313 }
314
321 public function getDetails()
322 {
323 return $this->details;
324 }
325
326 public function setRegistrationType($a_type)
327 {
328 $this->reg_type = $a_type;
329 }
330
331 public function getRegistrationType()
332 {
333 return $this->reg_type;
334 }
335
337 {
338 return $this->reg_limited;
339 }
340
341 public function enableRegistrationUserLimit($a_limit)
342 {
343 $this->reg_limited = $a_limit;
344 }
345
346 public function getRegistrationMinUsers()
347 {
349 }
350
351 public function setRegistrationMinUsers($a_users)
352 {
353 $this->reg_min_users = $a_users;
354 }
355
356 public function getRegistrationMaxUsers()
357 {
359 }
360
361 public function setRegistrationMaxUsers($a_users)
362 {
363 $this->reg_limited_users = $a_users;
364 }
365
367 {
369 }
370
371 public function enableRegistrationWaitingList($a_stat)
372 {
373 $this->reg_waiting_list = $a_stat;
374 }
375
376 public function setWaitingListAutoFill($a_value)
377 {
378 $this->reg_waiting_list_autofill = (bool) $a_value;
379 }
380
381 public function hasWaitingListAutoFill()
382 {
384 }
385
390 public function setShowMembers($a_status)
391 {
392 $this->show_members = (bool) $a_status;
393 }
394
399 public function getShowMembers()
400 {
401 return (bool) $this->show_members;
402 }
403
408 {
410 }
411
417 {
418 return $this->registrationNotificationEnabled = $value;
419 }
420
425 {
427 }
428
432 public function setRegistrationNotificationOption($value)
433 {
434 $this->notificationOption = $value;
435 }
436
443 public function enabledRegistration()
444 {
445 return $this->reg_type != ilMembershipRegistrationSettings::TYPE_NONE;
446 }
447
451 public function enabledRegistrationForUsers() : bool
452 {
453 return
456 }
457
458 public function isCannotParticipateOptionEnabled() : bool
459 {
461 }
462
466 public function enableCannotParticipateOption(bool $status) : void
467 {
468 $this->show_cannot_participate_option = $status;
469 }
470
477 public function getAppointments()
478 {
479 return $this->appointments ? $this->appointments : array();
480 }
481
489 public function addAppointment($appointment)
490 {
491 $this->appointments[] = $appointment;
492 }
493
502 {
503 $this->appointments = $appointments;
504 }
505
512 public function getFirstAppointment()
513 {
514 return is_object($this->appointments[0]) ? $this->appointments[0] : ($this->appointments[0] = new ilSessionAppointment());
515 }
516
524 public function getFiles()
525 {
526 return $this->files ? $this->files : array();
527 }
528
529
534 public function setMailToMembersType($a_type)
535 {
536 $this->mail_members = $a_type;
537 }
538
543 public function getMailToMembersType()
544 {
545 return $this->mail_members;
546 }
547
548
556 public function validate()
557 {
558 global $DIC;
559
560 $ilErr = $DIC['ilErr'];
561
562 // #17114
563 if ($this->isRegistrationUserLimitEnabled() &&
564 !$this->getRegistrationMaxUsers()) {
565 $ilErr->appendMessage($this->lng->txt("sess_max_members_needed"));
566 return false;
567 }
568
569 return true;
570 }
571
580 public function cloneObject($a_target_id, $a_copy_id = 0, $a_omit_tree = false)
581 {
585 $new_obj = parent::cloneObject($a_target_id, $a_copy_id, $a_omit_tree);
586
588 $new_obj->applyDidacticTemplate($dtpl);
589
590 $this->read();
591
592 $this->cloneSettings($new_obj);
593 $this->cloneMetaData($new_obj);
594
595
596 // Clone appointment
597 $new_app = $this->getFirstAppointment()->cloneObject($new_obj->getId());
598 $new_obj->setAppointments(array($new_app));
599 $new_obj->update(true);
600
601 // Clone session files
602 foreach ($this->files as $file) {
603 $file->cloneFiles($new_obj->getEventId());
604 }
605
606 // Raise update forn new appointments
607
608
609
610 // Copy learning progress settings
611 include_once('Services/Tracking/classes/class.ilLPObjSettings.php');
612 $obj_settings = new ilLPObjSettings($this->getId());
613 $obj_settings->cloneSettings($new_obj->getId());
614 unset($obj_settings);
615
616 return $new_obj;
617 }
618
626 public function cloneSettings(ilObjSession $new_obj)
627 {
629 $new_obj->getId(),
632 $this->getId(),
634 )
635 );
636
637 // @var ilObjSession $new_obj
638 $new_obj->setLocation($this->getLocation());
639 $new_obj->setName($this->getName());
640 $new_obj->setPhone($this->getPhone());
641 $new_obj->setEmail($this->getEmail());
642 $new_obj->setDetails($this->getDetails());
643
644 $new_obj->setRegistrationType($this->getRegistrationType());
650 $new_obj->setShowMembers($this->getShowMembers());
651 $new_obj->setMailToMembersType($this->getMailToMembersType());
652
656
657 $new_obj->update(true);
658
659 return true;
660 }
661
669 public function cloneDependencies($a_target_id, $a_copy_id)
670 {
671 global $DIC;
672
673 $ilObjDataCache = $DIC['ilObjDataCache'];
674
675 parent::cloneDependencies($a_target_id, $a_copy_id);
676
677 $target_obj_id = $ilObjDataCache->lookupObjId($a_target_id);
678
679 include_once('./Modules/Session/classes/class.ilEventItems.php');
680 $session_materials = new ilEventItems($target_obj_id);
681 $session_materials->cloneItems($this->getId(), $a_copy_id);
682
683 return true;
684 }
685
686
687
693 public function create($a_skip_meta_data = false)
694 {
695 global $DIC;
696
697 $ilDB = $DIC['ilDB'];
698 global $DIC;
699
700 $ilAppEventHandler = $DIC['ilAppEventHandler'];
701
702 parent::create();
703
704 if (!$a_skip_meta_data) {
705 $this->createMetaData();
706 }
707
708 $next_id = $ilDB->nextId('event');
709 $query = "INSERT INTO event (event_id,obj_id,location,tutor_name,tutor_phone,tutor_email,details,registration, " .
710 'reg_type, reg_limit_users, reg_limited, reg_waiting_list, reg_min_users, reg_auto_wait,show_members,mail_members,
711 reg_notification, notification_opt, show_cannot_part) ' .
712 "VALUES( " .
713 $ilDB->quote($next_id, 'integer') . ", " .
714 $this->db->quote($this->getId(), 'integer') . ", " .
715 $this->db->quote($this->getLocation(), 'text') . "," .
716 $this->db->quote($this->getName(), 'text') . ", " .
717 $this->db->quote($this->getPhone(), 'text') . ", " .
718 $this->db->quote($this->getEmail(), 'text') . ", " .
719 $this->db->quote($this->getDetails(), 'text') . "," .
720 $this->db->quote($this->enabledRegistrationForUsers(), 'integer') . ", " .
721 $this->db->quote($this->getRegistrationType(), 'integer') . ', ' .
722 $this->db->quote($this->getRegistrationMaxUsers(), 'integer') . ', ' .
723 $this->db->quote($this->isRegistrationUserLimitEnabled(), 'integer') . ', ' .
724 $this->db->quote($this->isRegistrationWaitingListEnabled(), 'integer') . ', ' .
725 $this->db->quote($this->getRegistrationMinUsers(), 'integer') . ', ' .
726 $this->db->quote($this->hasWaitingListAutoFill(), 'integer') . ', ' .
727 $this->db->quote($this->getShowMembers(), 'integer') . ', ' .
728 $this->db->quote($this->getMailToMembersType(), 'integer') . ',' .
729 $this->db->quote($this->isRegistrationNotificationEnabled(), 'integer') . ', ' .
730 $this->db->quote($this->getRegistrationNotificationOption(), 'text') . ', ' .
731 $this->db->quote($this->isCannotParticipateOptionEnabled(), ilDBConstants::T_INTEGER) . ' ' .
732 ")";
733 $res = $ilDB->manipulate($query);
734 $this->event_id = $next_id;
735
736 $ilAppEventHandler->raise(
737 'Modules/Session',
738 'create',
739 array('object' => $this,
740 'obj_id' => $this->getId(),
741 'appointments' => $this->prepareCalendarAppointments('create'))
742 );
743
744 return $this->getId();
745 }
746
754 public function update($a_skip_meta_update = false)
755 {
756 global $DIC;
757
758 $ilDB = $DIC['ilDB'];
759 global $DIC;
760
761 $ilAppEventHandler = $DIC['ilAppEventHandler'];
762
763 if (!parent::update()) {
764 return false;
765 }
766 if (!$a_skip_meta_update) {
767 $this->updateMetaData();
768 }
769
770 $query = "UPDATE event SET " .
771 "location = " . $this->db->quote($this->getLocation(), 'text') . "," .
772 "tutor_name = " . $this->db->quote($this->getName(), 'text') . ", " .
773 "tutor_phone = " . $this->db->quote($this->getPhone(), 'text') . ", " .
774 "tutor_email = " . $this->db->quote($this->getEmail(), 'text') . ", " .
775 "details = " . $this->db->quote($this->getDetails(), 'text') . ", " .
776 "registration = " . $this->db->quote($this->enabledRegistrationForUsers(), 'integer') . ", " .
777 "reg_type = " . $this->db->quote($this->getRegistrationType(), 'integer') . ", " .
778 "reg_limited = " . $this->db->quote($this->isRegistrationUserLimitEnabled(), 'integer') . ", " .
779 "reg_limit_users = " . $this->db->quote($this->getRegistrationMaxUsers(), 'integer') . ", " .
780 "reg_min_users = " . $this->db->quote($this->getRegistrationMinUsers(), 'integer') . ", " .
781 "reg_waiting_list = " . $this->db->quote($this->isRegistrationWaitingListEnabled(), 'integer') . ", " .
782 "reg_auto_wait = " . $this->db->quote($this->hasWaitingListAutoFill(), 'integer') . ", " .
783 'show_members = ' . $this->db->quote($this->getShowMembers(), 'integer') . ', ' .
784 'mail_members = ' . $this->db->quote($this->getMailToMembersType(), 'integer') . ', ' .
785 "reg_auto_wait = " . $this->db->quote($this->hasWaitingListAutoFill(), 'integer') . ", " .
786 "reg_notification = " . $this->db->quote($this->isRegistrationNotificationEnabled(), 'integer') . ", " .
787 "notification_opt = " . $this->db->quote($this->getRegistrationNotificationOption(), 'text') . ", " .
788 'show_cannot_part = ' . $this->db->quote($this->isCannotParticipateOptionEnabled(), ilDBConstants::T_INTEGER) . ' ' .
789 "WHERE obj_id = " . $this->db->quote($this->getId(), 'integer') . " ";
790 $res = $ilDB->manipulate($query);
791
792 $ilAppEventHandler->raise(
793 'Modules/Session',
794 'update',
795 array('object' => $this,
796 'obj_id' => $this->getId(),
797 'appointments' => $this->prepareCalendarAppointments('update'))
798 );
799 return true;
800 }
801
808 public function delete()
809 {
810 global $DIC;
811
812 $ilDB = $DIC['ilDB'];
813 global $DIC;
814
815 $ilAppEventHandler = $DIC['ilAppEventHandler'];
816
817 if (!parent::delete()) {
818 return false;
819 }
820
821 // delete meta data
822 $this->deleteMetaData();
823
824 $query = "DELETE FROM event " .
825 "WHERE obj_id = " . $this->db->quote($this->getId(), 'integer') . " ";
826 $res = $ilDB->manipulate($query);
827
828 include_once('./Modules/Session/classes/class.ilSessionAppointment.php');
830
831 include_once('./Modules/Session/classes/class.ilEventItems.php');
833
834 include_once('./Modules/Session/classes/class.ilEventParticipants.php');
836
837 foreach ($this->getFiles() as $file) {
838 $file->delete();
839 }
840
841 $ilAppEventHandler->raise(
842 'Modules/Session',
843 'delete',
844 array('object' => $this,
845 'obj_id' => $this->getId(),
846 'appointments' => $this->prepareCalendarAppointments('delete'))
847 );
848
849
850 return true;
851 }
852
860 public function read()
861 {
862 parent::read();
863
864 $query = "SELECT * FROM event WHERE " .
865 "obj_id = " . $this->db->quote($this->getId(), 'integer') . " ";
866 $res = $this->db->query($query);
867
868 while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
869 $this->setLocation($row->location);
870 $this->setName($row->tutor_name);
871 $this->setPhone($row->tutor_phone);
872 $this->setEmail($row->tutor_email);
873 $this->setDetails($row->details);
874 $this->setRegistrationType($row->reg_type);
875 $this->enableRegistrationUserLimit($row->reg_limited);
876 $this->enableRegistrationWaitingList($row->reg_waiting_list);
877 $this->setWaitingListAutoFill($row->reg_auto_wait);
878 $this->setRegistrationMaxUsers($row->reg_limit_users);
879 $this->setRegistrationMinUsers($row->reg_min_users);
880 $this->setShowMembers((bool) $row->show_members);
881 $this->setMailToMembersType((int) $row->mail_members);
882 $this->setRegistrationNotificationEnabled($row->reg_notification);
883 $this->setRegistrationNotificationOption($row->notification_opt);
884 $this->enableCannotParticipateOption((bool) $row->show_cannot_part);
885 $this->event_id = $row->event_id;
886 }
887
888 $this->initAppointments();
889 $this->initFiles();
890 }
891
899 protected function initAppointments()
900 {
901 // get assigned appointments
902 include_once('./Modules/Session/classes/class.ilSessionAppointment.php');
903 $this->appointments = ilSessionAppointment::_readAppointmentsBySession($this->getId());
904 }
905
913 public function initFiles()
914 {
915 include_once('./Modules/Session/classes/class.ilSessionFile.php');
921 //$this->files = ilSessionFile::_readFilesByEvent($this->getEventId());
922 }
923
924
932 public function prepareCalendarAppointments($a_mode = 'create')
933 {
934 include_once('./Services/Calendar/classes/class.ilCalendarAppointmentTemplate.php');
935
936 switch ($a_mode) {
937 case 'create':
938 case 'update':
939
940 $app = new ilCalendarAppointmentTemplate(self::CAL_REG_START);
941 $app->setTranslationType(IL_CAL_TRANSLATION_NONE);
942 $app->setTitle($this->getTitle() ? $this->getTitle() : $this->lng->txt('obj_sess'));
943 $app->setDescription($this->getLongDescription());
944 $app->setLocation($this->getLocation());
945
946 $sess_app = $this->getFirstAppointment();
947 $app->setFullday($sess_app->isFullday());
948 $app->setStart($sess_app->getStart());
949 $app->setEnd($sess_app->getEnd());
950 $apps[] = $app;
951
952 return $apps;
953
954 case 'delete':
955 // Nothing to do: The category and all assigned appointments will be deleted.
956 return array();
957 }
958 }
959
963 public function handleAutoFill()
964 {
965 if (
967 !$this->hasWaitingListAutoFill()
968 ) {
969 $this->session_logger->debug('Waiting list or auto fill is disabled.');
970 return true;
971 }
972
974 $current = $parts->getCountParticipants();
975 $max = $this->getRegistrationMaxUsers();
976
977 if ($max <= $current) {
978 $this->session_logger->debug('Maximum number of participants not reached.');
979 $this->session_logger->debug('Maximum number of members: ' . $max);
980 $this->session_logger->debug('Current number of members: ' . $current);
981 return true;
982 }
983
984 $session_waiting_list = new ilSessionWaitingList($this->getId());
985 foreach ($session_waiting_list->getUserIds() as $user_id) {
986 $user = ilObjectFactory::getInstanceByObjId($user_id);
987 if (!$user instanceof ilObjUser) {
988 $this->session_logger->warning('Found invalid user id on waiting list: ' . $user_id);
989 continue;
990 }
991 if (in_array($user_id, $parts->getParticipants())) {
992 $this->session_logger->notice('User on waiting list already session member: ' . $user_id);
993 continue;
994 }
995
996 if ($this->enabledRegistrationForUsers()) {
997 $this->session_logger->debug('Registration enabled: register user');
998 $parts->register($user_id);
999 $parts->sendNotification(
1001 $user_id
1002 );
1003 } else {
1004 $this->session_logger->debug('Registration disabled: set user status to participated.');
1005 $parts->getEventParticipants()->updateParticipation($user_id, true);
1006 $parts->sendNotification(
1008 $user_id
1009 );
1010 }
1011
1012 $session_waiting_list->removeFromList($user_id);
1013
1014 $current++;
1015 if ($current >= $max) {
1016 break;
1017 }
1018 }
1019 }
1020
1021
1029 protected function initParticipants()
1030 {
1031 $this->members_obj = ilSessionParticipants::_getInstanceByObjId($this->getId());
1032 }
1033
1039 public function getMembersObject()
1040 {
1041 if (!$this->members_obj instanceof ilSessionParticipants) {
1042 $this->initParticipants();
1043 }
1044 return $this->members_obj;
1045 }
1046
1051 public function getEnableMap()
1052 {
1053 return false;
1054 }
1055}
if(!defined('PATH_SEPARATOR')) $GLOBALS['_PEAR_default_error_mode']
Definition: PEAR.php:64
An exception for terminatinating execution or to throw for unit testing.
const IL_CAL_TRANSLATION_NONE
const IL_CAL_UNIX
Apointment templates are used for automatic generated apointments.
static _lookupContainerSetting($a_id, $a_keyword, $a_default_value=null)
Lookup a container setting.
static _writeContainerSetting($a_id, $a_keyword, $a_value)
static formatDate(ilDateTime $date, $a_skip_day=false, $a_include_wd=false, $include_seconds=false)
Format a date @access public.
static formatPeriod(ilDateTime $start, ilDateTime $end, $a_skip_starting_day=false)
Format a period of two date Shows: 14.
Class for single dates.
static lookupTemplateId($a_ref_id)
Lookup template id @global ilDB $ilDB.
class ilEvent
static _delete($a_event_id)
static _deleteByEvent($a_event_id)
Class ilObjRole.
static createDefaultRole($a_title, $a_description, $a_tpl_name, $a_ref_id)
__construct($a_id=0, $a_call_by_reference=true)
Constructor @access public.
getFirstAppointment()
get first appointment
const LOCAL_ROLE_PARTICIPANT_PREFIX
enabledRegistration()
is registration enabled
getShowMembers()
Member gallery enabled.
getEnableMap()
ALways disabled.
static _lookupRegistrationEnabled($a_obj_id)
lookup registration enabled
getMailToMembersType()
Get mail to members type.
setLocation($a_location)
set location
setEmail($a_email)
set email
getDetails()
get details
read()
read session data
enableCannotParticipateOption(bool $status)
setRegistrationNotificationOption($value)
getLocation()
get location
initDefaultRoles()
Create local session participant role.
update($a_skip_meta_update=false)
update object
getEventId()
sget event id
setRegistrationType($a_type)
setName($a_name)
set name
setRegistrationMinUsers($a_users)
initAppointments()
init appointments
setPhone($a_phone)
set phone
setDetails($a_details)
set details
getAppointments()
get appointments
prepareCalendarAppointments($a_mode='create')
Prepare calendar appointments.
setAppointments($appointments)
set appointments
setWaitingListAutoFill($a_value)
setMailToMembersType($a_type)
Set mail to members type.
cloneDependencies($a_target_id, $a_copy_id)
Clone dependencies.
initFiles()
init files
setRegistrationNotificationEnabled($value)
getPresentationTitle()
get title (overwritten from base class)
setShowMembers($a_status)
Show members gallery.
enableRegistrationUserLimit($a_limit)
cloneSettings(ilObjSession $new_obj)
clone settings
static lookupSession($a_obj_id)
Get session data.
getPresentationTitleAppointmentPeriod()
initParticipants()
init participants object
create($a_skip_meta_data=false)
create new session
getMembersObject()
Get members objects.
enableRegistrationWaitingList($a_stat)
addAppointment($appointment)
add appointment
handleAutoFill()
Handle auto fill for session members.
hasTutorSettings()
check if there any tutor settings
setRegistrationMaxUsers($a_users)
static getInstanceByObjId($a_obj_id, $stop_on_error=true)
get an instance of an Ilias object by object id
Class ilObject Basic functions for all objects.
deleteMetaData()
delete meta data entry
updateMetaData()
update meta data entry
createMetaData()
create meta data entry
getRefId()
get reference id @access public
getLongDescription()
get object long description (stored in object_description)
cloneMetaData($target_obj)
Copy meta data.
getId()
get object id @access public
getTitle()
get object title @access public
class ilSessionAppointment
static _readAppointmentsBySession($a_event_id)
static _deleteBySession($a_event_id)
Session participation handling.
static _getInstanceByObjId($a_obj_id)
Get instance.
$app
Definition: cli.php:38
global $DIC
Definition: goto.php:24
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc
$query
$ilErr
Definition: raiseError.php:18
foreach($_POST as $key=> $value) $res
global $ilDB
$data
Definition: storeScorm.php:23