24 include_once(
'./Services/Table/classes/class.ilTable2GUI.php');
47 $this->
setId(
"svy_usr");
58 $this->
setStyle(
'table',
'fullwidth');
60 $this->
addColumn($this->lng->txt(
"username"),
'username',
'');
67 $this->
addColumn($this->lng->txt(
"question"),
'',
'');
68 $this->
addColumn($this->lng->txt(
"results"),
'',
'');
69 $this->
addColumn($this->lng->txt(
"workingtime"),
'workingtime',
'');
70 $this->
addColumn($this->lng->txt(
"survey_results_finished"),
'finished',
'');
72 $this->
setRowTemplate(
"tpl.il_svy_svy_results_user_row.html",
"Modules/Survey");
74 $this->
setFormAction($this->ctrl->getFormAction($a_parent_obj, $a_parent_cmd));
86 if (is_null($timeinseconds))
90 else if ($timeinseconds == 0)
92 return $this->lng->txt(
'not_available');
96 return sprintf(
"%02d:%02d:%02d", ($timeinseconds / 3600), ($timeinseconds / 60) % 60, $timeinseconds % 60);
117 $this->tpl->setVariable(
"USERNAME",
$data[
'username']);
118 $this->tpl->setVariable(
"QUESTION",
$data[
'question']);
119 $this->tpl->setVariable(
"RESULTS",
$data[
'results']);
120 $this->tpl->setVariable(
"WORKINGTIME", $this->
formatTime(
$data[
'workingtime']));
122 if(
$data[
"finished"] !== null)
124 if(
$data[
"finished"] !==
false)
132 $this->tpl->setVariable(
"FINISHED", $finished);
136 $this->tpl->setVariable(
"FINISHED",
" ");
139 if(
$data[
"subitems"])
141 $this->tpl->setCurrentBlock(
"tbl_content");
142 $this->tpl->parseCurrentBlock();
144 foreach(
$data[
"subitems"] as $subitem)
148 $this->tpl->setCurrentBlock(
"tbl_content");
149 $this->css_row = ($this->css_row !=
"tblrow1")
152 $this->tpl->setVariable(
"CSS_ROW", $this->css_row);
153 $this->tpl->parseCurrentBlock();