ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
class.ilSettingsTemplateTableGUI.php
Go to the documentation of this file.
1<?php
2/* Copyright (c) 1998-2009 ILIAS open source, Extended GPL, see docs/LICENSE */
3
4include_once("./Services/Table/classes/class.ilTable2GUI.php");
5
15{
16
20 function __construct($a_parent_obj, $a_parent_cmd, $a_type)
21 {
22 global $ilCtrl, $lng, $ilAccess, $lng;
23
24 $this->setId("admsettemp".$a_type);
25
26 parent::__construct($a_parent_obj, $a_parent_cmd);
27
28 include_once("./Services/Administration/classes/class.ilSettingsTemplate.php");
30 $this->setTitle($lng->txt("adm_settings_templates")." - ".
31 $lng->txt("obj_".$a_type));
32
33 $this->addColumn("", "", "1", true);
34 $this->addColumn($this->lng->txt("title"), "title");
35 $this->addColumn($this->lng->txt("description"));
36 $this->addColumn($this->lng->txt("actions"));
37
38 $this->setFormAction($ilCtrl->getFormAction($a_parent_obj));
39 $this->setRowTemplate("tpl.settings_template_row.html",
40 "Services/Administration");
41
42 $this->addMultiCommand("confirmSettingsTemplateDeletion", $lng->txt("delete"));
43 //$this->addCommandButton("", $lng->txt(""));
44 }
45
49 protected function fillRow($a_set)
50 {
51 global $lng, $ilCtrl;
52
53 $ilCtrl->setParameter($this->parent_obj, "templ_id", $a_set["id"]);
54 $this->tpl->setVariable("VAL_ID", $a_set["id"]);
55 // begin-patch lok
56 $this->tpl->setVariable("VAL_TITLE", ilSettingsTemplate::translate($a_set["title"]));
57 $this->tpl->setVariable("VAL_DESCRIPTION", ilSettingsTemplate::translate($a_set["description"]));
58 // end-patch lok
59 $this->tpl->setVariable("TXT_EDIT", $lng->txt("edit"));
60 $this->tpl->setVariable("HREF_EDIT",
61 $ilCtrl->getLinkTarget($this->parent_obj, "editSettingsTemplate"));
62 $ilCtrl->setParameter($this->parent_obj, "templ_id", "");
63 }
64
65}
66?>
__construct($a_parent_obj, $a_parent_cmd, $a_type)
Constructor.
static getAllSettingsTemplates($a_type, $a_include_auto_generated=false)
Get all settings templates of type.
static translate($a_title_desc)
Class ilTable2GUI.
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.
setTitle($a_title, $a_icon=0, $a_icon_alt=0)
Set title and title icon.
setData($a_data)
set table data @access public
setRowTemplate($a_template, $a_template_dir="")
Set row template.
addMultiCommand($a_cmd, $a_text)
Add Command button.
setId($a_val)
Set id.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
global $ilCtrl
Definition: ilias.php:18
global $lng
Definition: privfeed.php:40