4 include_once(
"./Services/Table/classes/class.ilTable2GUI.php");
5 include_once
'./Services/Search/classes/class.ilSearchSettings.php';
19 public function __construct($a_parent_obj, $a_parent_cmd =
"", $a_template_context =
"")
24 $this->lng->loadLanguageModule(
"meta");
33 if(!$ilCtrl->getNextClass($this))
37 switch($ilCtrl->getCmd())
50 $to_hide =
$_POST[
"item_id"];
54 $to_hide = array((
int)
$_GET[
"hide"]);
61 $value = array_unique(array_merge((array)$obj->getValue(), $to_hide));
62 $obj->setValue($value);
63 $obj->writeToSession();
66 if(isset(
$_POST[
"tbltplcrt"]))
68 $ilCtrl->setParameter($this->parent_obj,
"tbltplcrt",
$_POST[
"tbltplcrt"]);
70 if(isset(
$_POST[
"tbltpldel"]))
72 $ilCtrl->setParameter($this->parent_obj,
"tbltpldel",
$_POST[
"tbltpldel"]);
75 $ilCtrl->redirect($this->parent_obj, $this->parent_cmd);
93 global $ilObjDataCache;
95 include_once
'./Services/Search/classes/class.ilQueryParser.php';
98 $query_parser->setMinWordLength(0);
100 $query_parser->parse();
101 if(!$query_parser->validate())
107 include_once
'Services/Search/classes/Like/class.ilLikeObjectSearch.php';
109 $object_search->setFilter($filter[
"type"]);
110 $res =& $object_search->performSearch();
111 $res->setRequiredPermission($permission);
112 $res->setMaxHits(1000);
113 $res->addObserver($this,
"searchFilterListener");
115 if(!$this->filter[
"area"])
117 $res->filter(ROOT_FOLDER_ID,
false);
121 $res->filter($this->filter[
"area"],
false);
125 foreach(
$res->getResults() as $obj_data)
127 $objects[$obj_data[
'obj_id']][] = $obj_data[
'ref_id'];
131 $this->limit_reached =
$res->isLimitReached();
133 return $objects ? $objects : array();
143 if(is_array($this->filter[
"hide"]) && in_array($a_data[
"obj_id"], $this->filter[
"hide"]))
160 global
$lng, $ilObjDataCache;
165 include_once(
"./Services/Form/classes/class.ilSelectInputGUI.php");
169 $si->readFromSession();
172 $si->setValue(
"crs");
174 $this->filter[
"type"] = $si->getValue();
177 include_once(
"./Services/Form/classes/class.ilMultiSelectInputGUI.php");
180 $msi->readFromSession();
181 $this->filter[
"hide"] = $msi->getValue();
182 if($this->filter[
"hide"])
186 $types = $types[
"type"];
188 foreach($this->filter[
"hide"] as $obj_id)
190 if(in_array($ilObjDataCache->lookupType($obj_id), $types))
192 $options[$obj_id] = $ilObjDataCache->lookupTitle($obj_id);
195 $msi->setOptions($options);
199 include_once(
"./Services/Form/classes/class.ilTextInputGUI.php");
200 $ti =
new ilTextInputGUI($lng->txt(
"trac_title_description"),
"query");
204 $ti->readFromSession();
205 $this->filter[
"query"] = $ti->getValue();
208 include_once(
"./Services/Form/classes/class.ilRepositorySelectorInputGUI.php");
212 $rs->readFromSession();
213 $this->filter[
"area"] = $rs->getValue();
226 include_once
'classes/class.ilLink.php';
236 $path_full = $tree->getPathFull($ref_id);
237 foreach($path_full as
$data)
239 if(++$counter < (count($path_full)-1))
243 $path .=
" » ";
244 if($ref_id != $data[
'ref_id'])
246 $path .= $data[
'title'];
250 $path .= (
'<a target="_top" href="'.
252 $data[
'title'].
'</a>');
268 return array(
'crs' => $lng->txt(
'objs_crs'),
269 'grp' => $lng->txt(
'objs_grp'),
270 'lm' => $lng->txt(
'learning_resources'),
271 'exc' => $lng->txt(
'objs_exc'),
272 'tst' => $lng->txt(
'objs_tst'));
280 $pos = strrpos($id,
"_");
283 $function = strtoupper(substr($id,
$pos+1));
284 if(in_array($function, array(
"MIN",
"MAX",
"SUM",
"AVG",
"COUNT")))
286 $id = substr($id, 0,
$pos);
290 if(trim($value) ==
"" && $id !=
"status")
292 if($id ==
"title" && get_class($this) !=
"ilTrObjectUsersPropsTableGUI")
294 return "--".$lng->txt(
"none").
"--";
314 case "spent_seconds":
315 if(in_array(
$type, array(
"exc")))
321 include_once(
"./classes/class.ilFormat.php");
343 if(in_array(
$type, array(
"lm",
"dbk")))
350 $value = $lng->txt(
"gender_".$value);
354 include_once(
"./Services/Tracking/classes/class.ilLearningProgressBaseGUI.php");
361 $value = $lng->txt(
"lang_".$value);
365 $value = $lng->txt(
"meta_c_".$value);
375 foreach($this->filter as $id => $value)
384 $result[
"type"] = array(
'lm',
'sahs',
'htlm',
'dbk');
388 $result[
"type"] = array($value);
409 case "matriculation":
414 $result[$id] = $value;
421 $result[$id] = $value;
429 case "spent_seconds":
430 if(is_array($value) && implode(
"", $value))
432 $result[$id] = $value;
446 $result[$id][
"from"] = substr($result[$id][
"from"], 0, -8).
"00:00:00";
451 $result[$id][
"to"] = substr($result[$id][
"to"], 0, -8).
"23:59:59";
463 include_once(
"./Services/Tracking/classes/class.ilLPObjSettings.php");
473 protected function parseTitle($a_obj_id, $action, $a_user_id =
false)
475 global
$lng, $ilObjDataCache, $ilUser;
480 if($a_user_id != $ilUser->getId())
488 $user .=
", ".$a_user->getFullName();
491 $this->
setTitle($lng->txt($action).
": ".$ilObjDataCache->lookupTitle($a_obj_id).$user);
502 global
$lng, $ilObjDataCache, $ilUser, $ilClientIniFile;
515 include_once
'./classes/class.ilLink.php';
518 $lng->txt(
"trac_name_of_installation") => $ilClientIniFile->readVariable(
'client',
'name'),
519 $lng->txt(
"trac_object_name") => $ilObjDataCache->lookupTitle($this->obj_id),
522 $lng->txt(
"trac_report_date") =>
524 $lng->txt(
"trac_report_owner") => $ilUser->getFullName()
533 $worksheet->write($a_row, 0, $caption);
534 $worksheet->write($a_row, 1, $value);
544 $a_csv->addColumn(strip_tags($caption));
545 $a_csv->addColumn(strip_tags($value));
553 include_once
'Modules/Course/classes/Timings/class.ilTimingCache.php';
557 if($timings[
'item'][
'changeable'] and $timings[
'user'][$a_usr_id][
'end'])
559 $end = $timings[
'user'][$a_usr_id][
'end'];
561 else if ($timings[
'item'][
'suggestion_end'])
563 $end = $timings[
'item'][
'suggestion_end'];