ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
class.ilTimingOverviewTableGUI.php
Go to the documentation of this file.
1<?php
2/* Copyright (c) 1998-2013 ILIAS open source, Extended GPL, see docs/LICENSE */
3
4require_once 'Services/Table/classes/class.ilTable2GUI.php';
5
10{
15 public function __construct($a_parent_obj, $a_parent_cmd)
16 {
17 global $DIC;
18 $lng = $DIC['lng'];
19 $ilCtrl = $DIC['ilCtrl'];
20
21 parent::__construct($a_parent_obj, $a_parent_cmd);
22
23 $this->lng = $lng;
24 $this->ctrl = $ilCtrl;
25
26 $this->setTitle($this->lng->txt('timing'));
27 $this->setRowTemplate("tpl.il_as_tst_timing_overview_row.html", "Modules/Test");
28 $this->setFormAction($this->ctrl->getFormAction($a_parent_obj, $a_parent_cmd));
29
30 $this->addColumn($this->lng->txt("login"), 'login', '');
31 $this->addColumn($this->lng->txt("name"), 'name', '');
32 $this->addColumn($this->lng->txt("tst_started"), 'started', '');
33 $this->addColumn($this->lng->txt("timing"), 'extratime', '');
34 }
35
39 public function fillRow($data)
40 {
41 $this->tpl->setVariable("LOGIN", $data['login']);
42 $this->tpl->setVariable("NAME", $data['name']);
43 $this->tpl->setVariable("STARTED", $data['started']);
44 $this->tpl->setVariable("EXTRATIME", ilDatePresentation::secondsToString($data['extratime'] * 60));
45 }
46}
An exception for terminatinating execution or to throw for unit testing.
static secondsToString($seconds, $force_with_seconds=false, $a_lng=null)
converts seconds to string: Long: 7 days 4 hour(s) ...
Class ilTable2GUI.
setTitle($a_title, $a_icon=0, $a_icon_alt=0)
Set title and title icon.
setRowTemplate($a_template, $a_template_dir="")
Set row template.
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.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
Class ilTimingOverviewTableGUI.
__construct($a_parent_obj, $a_parent_cmd)
global $ilCtrl
Definition: ilias.php:18
global $DIC
Definition: saml.php:7