33include_once
'./Services/Tracking/classes/class.ilLPStatus.php';
34include_once
'./Services/Tracking/classes/class.ilLPStatusWrapper.php';
69 if (!$status_info[
'registration']) {
73 if ($status_info[
'starting_time'] < time()) {
78 return $status_info[
'registered_users'] ? $status_info[
'registered_users'] : array();
84 return $status_info[
'participated_users'] ? $status_info[
'participated_users'] : array();
89 $tree =
$GLOBALS[
'DIC']->repositoryTree();
92 $ref_id = end($references);
94 $member_ref_id =
null;
95 if ($id = $tree->checkForParentType($ref_id,
'grp')) {
97 } elseif ($id = $tree->checkForParentType($ref_id,
'crs')) {
101 $status_info = array();
108 $status_info[
'starting_time'] = $time_info[
'start'];
109 $status_info[
'ending_time'] = $time_info[
'end'];
110 $status_info[
'fullday'] = $time_info[
'fullday'];
130 $ilObjDataCache =
$DIC[
'ilObjDataCache'];
133 switch ($ilObjDataCache->lookupType($a_obj_id)) {
135 include_once
'./Modules/Session/classes/class.ilEventParticipants.php';
136 include_once(
'./Modules/Session/classes/class.ilSessionAppointment.php');
137 include_once(
'./Modules/Session/classes/class.ilObjSession.php');
144 if ($registration && $time_info[
'start'] >= time()) {
164 protected static function getMembers($a_obj_id, $a_is_crs_id =
false)
167 $tree =
$GLOBALS[
'DIC']->repositoryTree();
169 $ref_id = end($references);
171 $member_ref_id =
null;
172 if ($id = $tree->checkForParentType($ref_id,
'grp')) {
173 $member_ref_id = $id;
174 } elseif ($id = $tree->checkForParentType($ref_id,
'crs')) {
175 $member_ref_id = $id;
181 $member_obj_id = $a_obj_id;
185 return $member_obj->getMembers();
if(!defined('PATH_SEPARATOR')) $GLOBALS['_PEAR_default_error_mode']
An exception for terminatinating execution or to throw for unit testing.
static _isRegistered($a_usr_id, $a_event_id)
static _hasParticipated($a_usr_id, $a_event_id)
static _getParticipated($a_event_id)
static _getRegistered($a_event_id)
static _getCompleted($a_obj_id)
static _getInProgress($a_obj_id)
static getMembers($a_obj_id, $a_is_crs_id=false)
Get members for object.
static _getStatusInfo($a_obj_id)
determineStatus($a_obj_id, $a_user_id, $a_obj=null)
Determine status.
static _getNotAttempted($a_obj_id)
static _lookupCompletedForObject($a_obj_id, $a_user_ids=null)
Get completed users for object.
static _lookupFailedForObject($a_obj_id, $a_user_ids=null)
Get failed users for object.
static _lookupInProgressForObject($a_obj_id, $a_user_ids=null)
Get in progress users for object.
static _getStatusInfo($a_obj_id)
Reads informations about the object e.g test results, tlt, number of visits.
static _getCompleted($a_obj_id)
Static function to read the users who have the status 'completed'.
static _getInProgress($a_obj_id)
Static function to read users who have the status 'in_progress'.
Abstract class ilLPStatus for all learning progress modes E.g ilLPStatusManual, ilLPStatusObjectives ...
const LP_STATUS_COMPLETED_NUM
static _lookupStatusForObject($a_obj_id, $a_status, $a_user_ids=null)
Get users with given status for object.
const LP_STATUS_IN_PROGRESS_NUM
const LP_STATUS_NOT_ATTEMPTED_NUM
static _lookupRegistrationEnabled($a_obj_id)
lookup registration enabled
static _lookupObjId($a_id)
static _lookupTitle($a_id)
lookup object title
static _lookupDescription($a_id)
lookup object description
static _getAllReferences($a_id)
get all reference ids of object
static getInstanceByObjId($a_obj_id)
Get instance by obj type.
static _lookupAppointment($a_obj_id)
lookup appointment
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc