24 include_once(
'./Services/Table/classes/class.ilTable2GUI.php');
50 parent::__construct($a_parent_obj, $a_parent_cmd);
52 $lng = $DIC->language();
61 $this->
setStyle(
'table',
'fullwidth');
66 $this->
addColumn($this->lng->txt(
"name"),
'name',
'');
67 $this->
addColumn($this->lng->txt(
"login"),
'login',
'');
68 $this->
addColumn($this->lng->txt(
"last_access"),
'last_access',
'');
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_maintenance_row.html",
"Modules/Survey");
75 $this->
addCommandButton(
'confirmDeleteSelectedUserData', $this->lng->txt(
'confirm'));
76 $this->
addCommandButton(
'cancelDeleteSelectedUserData', $this->lng->txt(
'cancel'));
78 $this->
addMultiCommand(
'deleteSingleUserResults', $this->lng->txt(
'delete_user_data'));
81 $this->
setFormAction($this->ctrl->getFormAction($a_parent_obj, $a_parent_cmd));
95 $this->
enable(
'select_all');
109 if (!$this->confirmdelete) {
110 $this->tpl->setCurrentBlock(
'checkbox');
111 $this->tpl->setVariable(
"CB_USER_ID",
$data[
'id']);
112 $this->tpl->parseCurrentBlock();
114 $this->tpl->setCurrentBlock(
'hidden');
115 $this->tpl->setVariable(
'HIDDEN_USER_ID',
$data[
"id"]);
116 $this->tpl->parseCurrentBlock();
118 $this->tpl->setVariable(
"USER_ID",
$data[
"id"]);
119 $this->tpl->setVariable(
"VALUE_USER_NAME",
$data[
'name']);
120 $this->tpl->setVariable(
"VALUE_USER_LOGIN",
$data[
'login']);
122 $this->tpl->setVariable(
"WORKINGTIME", $this->
formatTime(
$data[
'workingtime']));
124 if (
$data[
"finished"] !== null) {
125 if (
$data[
"finished"] !==
false) {
130 $this->tpl->setVariable(
"FINISHED", $finished);
132 $this->tpl->setVariable(
"FINISHED",
" ");
138 if (is_null($timeinseconds)) {
140 } elseif ($timeinseconds == 0) {
141 return $this->lng->txt(
'not_available');
143 return sprintf(
"%02d:%02d:%02d", ($timeinseconds / 3600), ($timeinseconds / 60) % 60, $timeinseconds % 60);
addCommandButton($a_cmd, $a_text, $a_onclick='', $a_id="", $a_class=null)
Add Command button.
setDefaultOrderField($a_defaultorderfield)
Set Default order field.
__construct($a_parent_obj, $a_parent_cmd, $confirmdelete=false)
Constructor.
numericOrdering($a_field)
public
setStyle($a_element, $a_style)
static formatDate(ilDateTime $date, $a_skip_day=false, $a_include_wd=false)
Format a date public.
setDefaultOrderDirection($a_defaultorderdirection)
Set Default order direction.
addMultiCommand($a_cmd, $a_text)
Add Command button.
enable($a_module_name)
enables particular modules of table
setRowTemplate($a_template, $a_template_dir="")
Set row template.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
disable($a_module_name)
diesables particular modules of table
setFormName($a_formname="")
Set Form name.
addColumn( $a_text, $a_sort_field="", $a_width="", $a_is_checkbox_action_column=false, $a_class="", $a_tooltip="", $a_tooltip_with_html=false)
Add a column to the header.
setShowRowsSelector($a_value)
Toggle rows-per-page selector.
setSelectAllCheckbox($a_select_all_checkbox)
Set the name of the checkbox that should be toggled with a select all button.
formatTime($timeinseconds)