4 include_once
'./Services/Table/classes/class.ilTable2GUI.php';
22 public function __construct($a_parent_obj, $a_parent_cmd =
"", $a_node_id, $a_mode)
29 $this->node_id = $a_node_id;
30 $this->mode = $a_mode;
52 $this->
setData($a_collection->getTableGUIData($this->getNode()));
59 $this->
addMultiCommand(
'releaseMaterials', $this->lng->txt(
'trac_release_materials'));
61 foreach($this->row_data as $item)
65 $this->
addCommandButton(
'saveObligatoryMaterials', $this->lng->txt(
'trac_group_materials_save'));
78 global $objDefinition;
80 include_once
'./Services/Link/classes/class.ilLink.php';
82 $this->tpl->setCurrentBlock(
'item_row');
83 $this->tpl->setVariable(
'ITEM_ID', $a_set[
'id']);
84 $this->tpl->setVariable(
'COLL_TITLE', $a_set[
'title']);
85 $this->tpl->setVariable(
'COLL_DESC',$a_set[
'description']);
90 $this->tpl->setVariable(
'ALT_IMG', $this->lng->txt(
'obj_sco'));
94 if($objDefinition->isPluginTypeName($a_set[
"type"]))
100 $alt = $this->lng->txt(
'obj_' . $a_set[
'type']);
102 $this->tpl->setVariable(
'ALT_IMG', $alt);
108 $this->tpl->setVariable(
'COLL_LINK',
ilLink::_getLink($a_set[
'ref_id'], $a_set[
'type']));
111 include_once
'./Services/Tree/classes/class.ilPathGUI.php';
113 $this->tpl->setVariable(
'COLL_PATH', $this->lng->txt(
'path').
': '.
$path->getPath($this->
getNode(),$a_set[
'ref_id']));
116 if($a_set[
'grouped'] ||
117 $a_set[
'group_item'])
120 $mode_suffix =
'_INLINE';
122 if(!$a_set[
'group_item'])
124 $this->tpl->setVariable(
"COLL_MODE",
"");
128 $mode = $a_set[
'mode_id'];
131 $this->tpl->setVariable(
"COLL_MODE".$mode_suffix, $a_set[
'mode']);
135 $this->tpl->setVariable(
"COLL_MODE".$mode_suffix,
"");
136 $this->tpl->setVariable(
"COLL_MODE_DEACTIVATED".$mode_suffix, $a_set[
'mode']);
138 if($a_set[
"anonymized"])
140 $this->tpl->setVariable(
"ANONYMIZED".$mode_suffix, $this->lng->txt(
'trac_anonymized_info_short'));
145 $this->tpl->setVariable(
"COLL_MODE_LABEL", $this->lng->txt(
"trac_mode"));
150 $this->tpl->setVariable(
'COLL_LINK', $a_set[
'url']);
155 $this->tpl->setCurrentBlock(
"tlt");
156 $this->tpl->setVariable(
"TXT_MONTH",$this->lng->txt(
'md_months'));
157 $this->tpl->setVariable(
"TXT_DAYS",$this->lng->txt(
'md_days'));
158 $this->tpl->setVariable(
"TXT_TIME",$this->lng->txt(
'md_time'));
159 $this->tpl->setVariable(
"TLT_HINT",
'(hh:mm)');
162 $mon = floor($a_set[
"tlt"]/(60*60*24*30));
163 $tlt = $a_set[
"tlt"]%(60*60*24*30);
164 $day = floor($tlt/(60*60*24));
165 $tlt = $tlt%(60*60*24);
166 $hr = floor($tlt/(60*60));
168 $min = floor($tlt/60);
171 for($i = 0;$i <= 24;$i++)
175 $this->tpl->setVariable(
"SEL_MONTHS",
178 for($i = 0;$i <= 31;$i++)
182 $this->tpl->setVariable(
"SEL_DAYS",
186 true,$hr,$min,null,
false));
188 $this->tpl->parseCurrentBlock();
194 $this->tpl->setVariable(
"ASSIGNED_IMG_OK", $a_set[
'status']
198 $this->tpl->setVariable(
"ASSIGNED_STATUS", $a_set[
'status']
199 ? $this->lng->txt(
'trac_assigned')
200 : $this->lng->txt(
'trac_not_assigned')
202 $this->tpl->parseCurrentBlock();
206 foreach((array) $a_set[
'grouped'] as $item)
208 $item[
'group_item'] =
true;
213 if(count($a_set[
'grouped']))
215 $this->tpl->setCurrentBlock(
'num_passed_items');
216 $this->tpl->setVariable(
'MIN_PASSED_TXT', $this->lng->txt(
'trac_min_passed'));
217 $this->tpl->setVariable(
'NUM_OBLIGATORY', $a_set[
'num_obligatory']);
218 $this->tpl->setVariable(
'GRP_ID', $a_set[
'grouping_id']);
219 $this->tpl->parseCurrentBlock();
227 $this->
setFormAction($ilCtrl->getFormAction($this->getParentObject()));
232 $this->
setRowTemplate(
'tpl.lp_collection_row.html',
'Services/Tracking');
233 $this->
setTitle($this->lng->txt(
'trac_lp_determination'));
234 $this->
setDescription($this->lng->txt(
'trac_lp_determination_info_crs'));
238 $this->
setRowTemplate(
'tpl.lp_collection_row.html',
'Services/Tracking');
239 $this->
setTitle($this->lng->txt(
'trac_lp_determination_tutor'));
240 $this->
setDescription($this->lng->txt(
'trac_lp_determination_info_crs_tutor'));
244 $this->
setRowTemplate(
'tpl.lp_collection_scorm_row.html',
'Services/Tracking');
245 $this->
setTitle($this->lng->txt(
'trac_lp_determination'));
246 $this->
setDescription($this->lng->txt(
'trac_lp_determination_info_sco'));
250 $this->
setRowTemplate(
'tpl.lp_collection_subitem_row.html',
'Services/Tracking');
251 $this->
setTitle($this->lng->txt(
'trac_lp_determination'));
252 $this->
setDescription($this->lng->txt(
'trac_lp_determination_info_crs'));
253 $this->lng->loadLanguageModule(
"meta");
260 $this->
addColumn($this->lng->txt(
'item'),
'title',
'50%');
266 $this->
addColumn($this->lng->txt(
'trac_mode'),
'mode');
270 $this->
addColumn($this->lng->txt(
'meta_typical_learning_time'),
'tlt');
275 $this->
addMultiCommand(
'assign', $this->lng->txt(
'trac_collection_assign'));
276 $this->
addMultiCommand(
'deassign', $this->lng->txt(
'trac_collection_deassign'));
277 $this->
addColumn($this->lng->txt(
'trac_determines_learning_progress'),
'status');
281 $this->
addMultiCommand(
'assign', $this->lng->txt(
'trac_manual_display'));
282 $this->
addMultiCommand(
'deassign', $this->lng->txt(
'trac_manual_no_display'));
283 $this->
addColumn($this->lng->txt(
'trac_manual_is_displayed'),
'status');
286 $this->
enable(
'select_all');
291 $this->
addMultiCommand(
'groupMaterials', $this->lng->txt(
'trac_group_materials'));