ILIAS  release_7 Revision v7.30-3-g800a261c036
All Data Structures Namespaces Files Functions Variables Modules Pages
class.ilGlobalUnitConfigurationGUI.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (c) 1998-2013 ILIAS open source, Extended GPL, see docs/LICENSE */
3 
4 require_once 'Modules/TestQuestionPool/classes/class.ilUnitConfigurationGUI.php';
5 
10 {
11  const REQUEST_PARAM_SUB_CONTEXT = 'context';
12 
16  protected function getDefaultCommand()
17  {
18  return 'showGlobalUnitCategories';
19  }
20 
25  {
26  return 'showGlobalUnitCategories';
27  }
28 
32  public function isCRUDContext()
33  {
34  return true;
35  }
36 
40  public function getUniqueId()
41  {
42  return $this->repository->getConsumerId() . '_global';
43  }
44 
48  protected function showGlobalUnitCategories()
49  {
53  global $DIC;
54  $ilToolbar = $DIC['ilToolbar'];
55  $rbacsystem = $DIC->rbac()->system();
56 
57  if ($rbacsystem->checkAccess('write', $_GET['ref_id'])) {
58  $ilToolbar->addButton($this->lng->txt('un_add_category'), $this->ctrl->getLinkTarget($this, 'showUnitCategoryCreationForm'));
59  }
60 
61  parent::showGlobalUnitCategories();
62  }
63 
67  protected function showUnitCategories(array $categories)
68  {
69  require_once 'Modules/TestQuestionPool/classes/tables/class.ilGlobalUnitCategoryTableGUI.php';
71  $table->setData($categories);
72 
73  $this->tpl->setContent($table->getHTML());
74  }
75 }
$_GET["client_id"]
Class ilGlobalUnitConfigurationGUI.
Class ilUnitConfigurationGUI .
repository()
Definition: repository.php:5
global $DIC
Definition: goto.php:24
Class ilGlobalUnitCategoryTableGUI.