5 include_once
'Services/Tracking/classes/class.ilLPStatus.php';
29 global $ilObjDataCache;
32 $ilBench->start(
'LearningProgress',
'9171_LPStatusObjectives_notAttempted');
34 include_once
'Modules/Course/classes/class.ilCourseParticipants.php';
36 $members = $members_obj->getParticipants();
42 $ilBench->stop(
'LearningProgress',
'9171_LPStatusObjectives_notAttempted');
43 return $users ? $users : array();
52 include_once
'Modules/Course/classes/class.ilCourseParticipants.php';
54 $members = $members_obj->getParticipants();
56 include_once
'./Services/Tracking/classes/class.ilChangeEvent.php';
58 foreach($all as $user_id)
60 if(!in_array($user_id,$completed) and in_array($user_id,$members))
62 $user_ids[] = $user_id;
65 return $user_ids ? $user_ids : array();
75 foreach($status_info[
'objective_result'] as $user_id => $completed)
77 if(count($completed) == $status_info[
'num_objectives'])
79 $usr_ids[] = $user_id;
82 return $usr_ids ? $usr_ids : array();
88 include_once
'Modules/Course/classes/class.ilCourseObjective.php';
92 $status_info[
'objective_result'] = array();
94 $status_info[
'num_objectives'] = count($status_info[
'objectives']);
96 if(!$status_info[
'num_objectives'])
102 $in = $ilDB->in(
'objective_id',$status_info[
'objectives'],
false,
'integer');
105 $query =
"SELECT * FROM crs_objective_status ".
111 $status_info[
'completed'][
$row->objective_id][] =
$row->user_id;
112 $status_info[
'objective_result'][
$row->user_id][
$row->objective_id] =
$row->objective_id;
116 $query =
"SELECT * FROM crs_objectives ".
121 $status_info[
'objective_title'][
$row->objective_id] =
$row->title;
122 $status_info[
'objective_description'][
$row->objective_id] =
$row->description;
137 global $ilObjDataCache,
$ilDB;
150 switch ($ilObjDataCache->lookupType($a_obj_id))
153 include_once(
"./Services/Tracking/classes/class.ilChangeEvent.php");
158 include_once
'Modules/Course/classes/class.ilCourseObjective.php';
162 $set = $ilDB->query(
"SELECT count(objective_id) cnt FROM crs_objective_status ".
163 "WHERE ".$ilDB->in(
'objective_id',$objectives,
false,
'integer').
164 " AND user_id = ".$ilDB->quote($a_user_id,
"integer"));
165 if ($rec = $ilDB->fetchAssoc($set))
167 if ($rec[
"cnt"] == count($objectives))