ILIAS  Release_4_4_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
class.ilSkillProfileTableGUI.php
Go to the documentation of this file.
1 <?php
2 
3 /* Copyright (c) 1998-2011 ILIAS open source, Extended GPL, see docs/LICENSE */
4 
5 include_once("./Services/Table/classes/class.ilTable2GUI.php");
6 
16 {
20  function __construct($a_parent_obj, $a_parent_cmd)
21  {
22  global $ilCtrl, $lng, $ilAccess, $lng;
23 
24  parent::__construct($a_parent_obj, $a_parent_cmd);
25  $this->setData($this->getProfiles());
26  $this->setTitle($lng->txt("skmg_skill_profiles"));
27 
28  $this->addColumn("", "", "1px", true);
29  $this->addColumn($this->lng->txt("title"), "title");
30  $this->addColumn($this->lng->txt("users"));
31  $this->addColumn($this->lng->txt("actions"));
32 
33  $this->setFormAction($ilCtrl->getFormAction($a_parent_obj));
34  $this->setRowTemplate("tpl.skill_profile_row.html", "Services/Skill");
35 
36  $this->addMultiCommand("confirmDeleteProfiles", $lng->txt("delete"));
37  //$this->addCommandButton("", $lng->txt(""));
38  }
39 
45  function getProfiles()
46  {
47  include_once("./Services/Skill/classes/class.ilSkillProfile.php");
49  }
50 
51 
55  protected function fillRow($a_set)
56  {
57  global $lng, $ilCtrl;
58 
59  $this->tpl->setCurrentBlock("cmd");
60  $this->tpl->setVariable("CMD", $lng->txt("edit"));
61  $ilCtrl->setParameter($this->parent_obj, "sprof_id", $a_set["id"]);
62  $this->tpl->setVariable("CMD_HREF", $ilCtrl->getLinkTarget($this->parent_obj, "showUsers"));
63  $ilCtrl->setParameter($this->parent_obj, "sprof_id", $_GET["sprof_id"]);
64  $this->tpl->parseCurrentBlock();
65 
66  $this->tpl->setVariable("ID", $a_set["id"]);
67  $this->tpl->setVariable("TITLE", $a_set["title"]);
68  $this->tpl->setVariable("NUM_USERS", ilSkillProfile::countUsers($a_set["id"]));
69  }
70 
71 }
72 ?>