24 include_once(
'./Services/Table/classes/class.ilTable2GUI.php');
47 $this->
setId(
"qpl_print");
57 $this->
setStyle(
'table',
'fullwidth');
58 $this->
addColumn($this->lng->txt(
"title"),
'title',
'');
61 if (strcmp($c,
'description') == 0) $this->
addColumn($this->lng->txt(
"description"),
'description',
'');
62 if (strcmp($c,
'author') == 0) $this->
addColumn($this->lng->txt(
"author"),
'author',
'');
63 if (strcmp($c,
'ttype') == 0) $this->
addColumn($this->lng->txt(
"question_type"),
'ttype',
'');
64 if (strcmp($c,
'created') == 0) $this->
addColumn($this->lng->txt(
"create_date"),
'created',
'');
65 if (strcmp($c,
'updated') == 0) $this->
addColumn($this->lng->txt(
"last_update"),
'updated',
'');
68 $this->
addCommandButton(
'print', $this->lng->txt(
'print'),
"javascript:window.print();return false;");
70 $this->
setRowTemplate(
"tpl.il_as_qpl_printview_row.html",
"Modules/TestQuestionPool");
72 $this->
setFormAction($this->ctrl->getFormAction($a_parent_obj, $a_parent_cmd));
86 $cols[
"description"] = array(
87 "txt" => $lng->txt(
"description"),
90 $cols[
"author"] = array(
91 "txt" => $lng->txt(
"author"),
94 $cols[
"ttype"] = array(
95 "txt" => $lng->txt(
"question_type"),
98 $cols[
"created"] = array(
99 "txt" => $lng->txt(
"create_date"),
102 $cols[
"updated"] = array(
103 "txt" => $lng->txt(
"last_update"),
122 if (strcmp($c,
'description') == 0)
124 $this->tpl->setCurrentBlock(
'description');
126 $this->tpl->parseCurrentBlock();
128 if (strcmp($c,
'author') == 0)
130 $this->tpl->setCurrentBlock(
'author');
132 $this->tpl->parseCurrentBlock();
134 if (strcmp($c,
'ttype') == 0)
136 $this->tpl->setCurrentBlock(
'ttype');
138 $this->tpl->parseCurrentBlock();
140 if(strcmp($c,
'created') == 0)
142 $this->tpl->setCurrentBlock(
'created');
144 $this->tpl->parseCurrentBlock();
146 if(strcmp($c,
'updated') == 0)
148 $this->tpl->setCurrentBlock(
'updated');
150 $this->tpl->parseCurrentBlock();
153 if ((strcmp($this->outputmode,
"detailed") == 0) || (strcmp($this->outputmode,
"detailed_printview") == 0))
155 $this->tpl->setCurrentBlock(
"overview_row_detail");
156 include_once
"./Modules/TestQuestionPool/classes/class.assQuestion.php";
158 if (strcmp($this->outputmode,
"detailed") == 0)
160 $solutionoutput = $question_gui->getSolutionOutput($active_id =
"",
$pass = NULL, $graphicalOutput = FALSE, $result_output = FALSE, $show_question_only = FALSE, $show_feedback = FALSE, $show_correct_solution =
true, $show_manual_scoring =
false);
161 if (strlen($solutionoutput) == 0) $solutionoutput = $question_gui->getPreview();
162 $this->tpl->setVariable(
"DETAILS", $solutionoutput);
166 $this->tpl->setVariable(
"DETAILS", $question_gui->getPreview());
168 $this->tpl->parseCurrentBlock();
179 if(in_array($column, array(
'created',
'updated')))