24 include_once(
"Services/Table/classes/class.ilTable2GUI.php");
39 function __construct($a_temp_type, $a_parent_obj, $a_parent_cmd, $a_style_obj)
46 include_once(
"./Services/Accordion/classes/class.ilAccordionGUI.php");
49 $this->
setTitle($lng->txt(
"sty_templates"));
50 $this->style_obj = $a_style_obj;
51 $this->temp_type = $a_temp_type;
54 $this->
addColumn($this->lng->txt(
"sty_template_name"),
"");
55 $this->
addColumn($this->lng->txt(
"sty_preview"),
"");
56 $this->
addColumn($this->lng->txt(
"sty_commands"),
"",
"1");
59 $this->
setRowTemplate(
"tpl.style_template_row.html",
"Services/Style");
64 $this->
addMultiCommand(
"deleteTemplateConfirmation", $lng->txt(
"delete"));
66 if ($a_temp_type ==
"table")
68 $this->
addCommandButton(
"generateTemplate", $this->lng->txt(
"sty_generate_template"));
80 $this->
setData($this->style_obj->getTemplates($this->temp_type));
90 $this->tpl->setVariable(
"T_PREVIEW",
91 $this->style_obj->lookupTemplatePreview($a_set[
"id"]));
92 $this->tpl->setVariable(
"TID", $a_set[
"id"]);
93 $this->tpl->setVariable(
"TEMPLATE_NAME", $a_set[
"name"]);
94 $ilCtrl->setParameter($this->parent_obj,
"t_id", $a_set[
"id"]);
95 $this->tpl->setVariable(
"LINK_EDIT_TEMPLATE",
96 $ilCtrl->getLinkTarget($this->parent_obj,
"editTemplate"));
97 $this->tpl->setVariable(
"TXT_EDIT", $lng->txt(
"edit"));