24 include_once(
"./Services/Table/classes/class.ilTable2GUI.php");
50 $this->
setId(
"tst_eval_all");
56 $this->
setStyle(
'table',
'fullwidth');
57 $this->
addColumn($lng->txt(
"name"),
"name",
"");
58 $this->
addColumn($lng->txt(
"login"),
"login",
"");
63 if (!$this->anonymity)
67 if (strcmp($c,
'gender') == 0) $this->
addColumn($this->lng->txt(
"gender"),
'gender',
'');
68 if (strcmp($c,
'email') == 0) $this->
addColumn($this->lng->txt(
"email"),
'email',
'');
69 if (strcmp($c,
'institution') == 0) $this->
addColumn($this->lng->txt(
"institution"),
'institution',
'');
70 if (strcmp($c,
'street') == 0) $this->
addColumn($this->lng->txt(
"street"),
'street',
'');
71 if (strcmp($c,
'city') == 0) $this->
addColumn($this->lng->txt(
"city"),
'city',
'');
72 if (strcmp($c,
'zipcode') == 0) $this->
addColumn($this->lng->txt(
"zipcode"),
'zipcode',
'');
73 if (strcmp($c,
'country') == 0) $this->
addColumn($this->lng->txt(
"country"),
'country',
'');
74 if (strcmp($c,
'department') == 0) $this->
addColumn($this->lng->txt(
"department"),
'department',
'');
75 if (strcmp($c,
'matriculation') == 0) $this->
addColumn($this->lng->txt(
"matriculation"),
'matriculation',
'');
79 $this->
addColumn($lng->txt(
"tst_reached_points"),
"reached",
"");
81 if( $this->offeringQuestionHintsEnabled )
83 $this->
addColumn($lng->txt(
"tst_question_hints_requested_hint_count_header"),
"hint_count",
"");
86 $this->
addColumn($lng->txt(
"tst_mark"),
"mark",
"");
88 if ($this->parent_obj->object->ects_output)
92 if (strcmp($c,
'ects_grade') == 0) $this->
addColumn($this->lng->txt(
"ects_grade"),
'ects_grade',
'');
95 $this->
addColumn($lng->txt(
"tst_answered_questions"),
"answered",
"");
96 $this->
addColumn($lng->txt(
"working_time"),
"working_time",
"");
97 $this->
addColumn($lng->txt(
"detailed_evaluation"),
"details",
"");
99 $this->
setFormAction($this->ctrl->getFormAction($a_parent_obj, $a_parent_cmd));
100 $this->
setRowTemplate(
"tpl.table_evaluation_all.html",
"Modules/Test");
121 if ($this->anonymity)
144 if (!$this->anonymity)
146 $cols[
"gender"] = array(
147 "txt" => $lng->txt(
"gender"),
150 $cols[
"email"] = array(
151 "txt" => $lng->txt(
"email"),
154 $cols[
"institution"] = array(
155 "txt" => $lng->txt(
"institution"),
158 $cols[
"street"] = array(
159 "txt" => $lng->txt(
"street"),
162 $cols[
"city"] = array(
163 "txt" => $lng->txt(
"city"),
166 $cols[
"zipcode"] = array(
167 "txt" => $lng->txt(
"zipcode"),
170 $cols[
"country"] = array(
171 "txt" => $lng->txt(
"country"),
174 $cols[
"department"] = array(
175 "txt" => $lng->txt(
"department"),
178 $cols[
"matriculation"] = array(
179 "txt" => $lng->txt(
"matriculation"),
183 if ($this->parent_obj->object->ects_output)
185 $cols[
"ects_grade"] = array(
186 "txt" => $lng->txt(
"ects_grade"),
201 include_once(
"./Services/Form/classes/class.ilTextInputGUI.php");
204 $ti->setValidationRegexp(
'/^[^%]+$/is');
207 $ti->readFromSession();
208 $this->filter[
"name"] = $ti->getValue();
213 $ti->setValidationRegexp(
'/^[^%]+$/is');
216 $ti->readFromSession();
217 $this->filter[
"group"] = $ti->getValue();
223 $ti->setValidationRegexp(
'/^[^%]+$/is');
225 $ti->readFromSession();
226 $this->filter[
"course"] = $ti->getValue();
229 include_once(
"./Services/Form/classes/class.ilCheckboxInputGUI.php");
233 $si->readFromSession();
234 $this->filter[
"passedonly"] =
$si->getValue();
243 $this->tpl->setVariable(
"NAME",
$data[
'name']);
244 $this->tpl->setVariable(
"LOGIN",
$data[
'login']);
247 if (!$this->anonymity)
249 if (strcmp($c,
'gender') == 0)
251 $this->tpl->setCurrentBlock(
'gender');
252 $this->tpl->setVariable(
"GENDER", $this->lng->txt(
'gender_' .
$data[
'gender']));
253 $this->tpl->parseCurrentBlock();
255 if (strcmp($c,
'email') == 0)
257 $this->tpl->setCurrentBlock(
'email');
258 $this->tpl->setVariable(
"EMAIL", strlen(
$data[
'email']) ?
$data[
'email'] :
' ');
259 $this->tpl->parseCurrentBlock();
261 if (strcmp($c,
'institution') == 0)
263 $this->tpl->setCurrentBlock(
'institution');
264 $this->tpl->setVariable(
"INSTITUTION", strlen(
$data[
'institution']) ?
$data[
'institution'] :
' ');
265 $this->tpl->parseCurrentBlock();
267 if (strcmp($c,
'street') == 0)
269 $this->tpl->setCurrentBlock(
'street');
270 $this->tpl->setVariable(
"STREET", strlen(
$data[
'street']) ?
$data[
'street'] :
' ');
271 $this->tpl->parseCurrentBlock();
273 if (strcmp($c,
'city') == 0)
275 $this->tpl->setCurrentBlock(
'city');
276 $this->tpl->setVariable(
"CITY", strlen(
$data[
'city']) ?
$data[
'city'] :
' ');
277 $this->tpl->parseCurrentBlock();
279 if (strcmp($c,
'zipcode') == 0)
281 $this->tpl->setCurrentBlock(
'zipcode');
282 $this->tpl->setVariable(
"ZIPCODE", strlen(
$data[
'zipcode']) ?
$data[
'zipcode'] :
' ');
283 $this->tpl->parseCurrentBlock();
285 if (strcmp($c,
'country') == 0)
287 $this->tpl->setCurrentBlock(
'country');
288 $this->tpl->setVariable(
"COUNTRY", strlen(
$data[
'country']) ?
$data[
'country'] :
' ');
289 $this->tpl->parseCurrentBlock();
291 if (strcmp($c,
'department') == 0)
293 $this->tpl->setCurrentBlock(
'department');
294 $this->tpl->setVariable(
"DEPARTMENT", strlen(
$data[
'department']) ?
$data[
'department'] :
' ');
295 $this->tpl->parseCurrentBlock();
297 if (strcmp($c,
'matriculation') == 0)
299 $this->tpl->setCurrentBlock(
'matriculation');
300 $this->tpl->setVariable(
"MATRICULATION", strlen(
$data[
'matriculation']) ?
$data[
'matriculation'] :
' ');
301 $this->tpl->parseCurrentBlock();
304 if ($this->parent_obj->object->ects_output)
306 if (strcmp($c,
'ects_grade') == 0)
308 $this->tpl->setCurrentBlock(
'ects_grade');
309 $this->tpl->setVariable(
"ECTS_GRADE",
$data[
'ects_grade']);
310 $this->tpl->parseCurrentBlock();
314 $this->tpl->setVariable(
"REACHED",
$data[
'reached'] .
" " . strtolower($this->lng->txt(
"of")) .
" " .
$data[
'max']);
316 if( $this->offeringQuestionHintsEnabled )
318 $this->tpl->setVariable(
"HINT_COUNT",
$data[
'hint_count']);
321 $data[
'answered'] =
$data[
'questions_worked_through'] .
" " . strtolower($this->lng->txt(
"of")) .
" " .
$data[
'number_of_questions'] .
" (" . sprintf(
"%2.2f",
$data[
'answered']) .
" %" .
")";
323 $this->tpl->setVariable(
"MARK",
$data[
'mark']);
324 $this->tpl->setVariable(
"ANSWERED",
$data[
'answered']);
325 $this->tpl->setVariable(
"WORKING_TIME",
$data[
'working_time']);
326 $this->tpl->setVariable(
"DETAILED",
$data[
'details']);
334 if (!is_array($cols)) {
338 $fields_to_unset = array_diff(array_keys($scol), array_keys($cols));
340 foreach($fields_to_unset as $key) {