ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
class.ilGlossaryForeignTermTableGUI.php
Go to the documentation of this file.
1 <?php
2 
3 /* Copyright (c) 1998-2016 ILIAS open source, Extended GPL, see docs/LICENSE */
4 
5 include_once("./Services/Table/classes/class.ilTable2GUI.php");
6 
16 {
20  protected $ctrl;
21 
25  protected $lng;
26 
30  protected $glossary;
31 
39  public function __construct($a_parent_obj, $a_parent_cmd, ilObjGlossary $a_glossary)
40  {
41  global $DIC;
42 
43  $this->lng = $DIC->language();
44  $this->ctrl = $DIC->ctrl();
45  $this->glossary = $a_glossary;
46 
47  parent::__construct($a_parent_obj, $a_parent_cmd);
48  $terms = $this->glossary->getTermList();
49 
50  $this->setData($terms);
51  $this->setTitle($this->glossary->getTitle() . ": " . $this->lng->txt("glo_select_terms"));
52 
53  $this->addColumn("", "", "1");
54  $this->addColumn($this->lng->txt("glo_term"));
55 
56  $this->setFormAction($this->ctrl->getFormAction($a_parent_obj));
57  $this->setRowTemplate("tpl.glo_foreign_term_row.html", "Modules/Glossary");
58 
59  $this->addMultiCommand("copyTerms", $this->lng->txt("glo_copy_terms"));
60  $this->addMultiCommand("referenceTerms", $this->lng->txt("glo_reference_terms"));
61 
62  //$this->addCommandButton("", $lng->txt(""));
63  }
64 
68  protected function fillRow($a_set)
69  {
70  $this->tpl->setVariable("TERM", $a_set["term"]);
71  $this->tpl->setVariable("TERM_ID", $a_set["id"]);
72  }
73 }
global $DIC
Definition: saml.php:7
Class ilObjGlossary.
setTitle($a_title, $a_icon=0, $a_icon_alt=0)
Set title and title icon.
Class ilTable2GUI.
__construct($a_parent_obj, $a_parent_cmd, ilObjGlossary $a_glossary)
ilGlossaryForeignTermTableGUI constructor.
addMultiCommand($a_cmd, $a_text)
Add Command button.
setRowTemplate($a_template, $a_template_dir="")
Set row template.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
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.
TableGUI class for collecting foreign terms.