ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
class.ilObjChatroomAdminGUI.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (c) 1998-2016 ILIAS open source, Extended GPL, see docs/LICENSE */
3 
4 require_once 'Services/Object/classes/class.ilObjectGUI.php';
5 require_once 'Modules/Chatroom/classes/class.ilObjChatroom.php';
6 require_once 'Modules/Chatroom/classes/class.ilObjChatroomAccess.php';
7 require_once 'Modules/Chatroom/classes/class.ilChatroomObjectGUI.php';
8 
20 {
24  public function __construct($a_data = null, $a_id = null, $a_call_by_reference = true)
25  {
29  global $lng;
30 
31  $lng->loadLanguageModule('chatroom_adm');
32 
33  if($a_data == null)
34  {
35  if($_GET['serverInquiry'])
36  {
37  require_once dirname(__FILE__) . '/class.ilChatroomServerHandler.php';
39  return;
40  }
41  }
42 
43  $this->type = 'chta';
44  parent::__construct($a_data, $a_id, $a_call_by_reference, false);
45  }
46 
51  public static function _goto($ref_id)
52  {
53  include_once 'Services/Object/classes/class.ilObjectGUI.php';
55  }
56 
62  protected function getObjectDefinition()
63  {
65  'Chatroom', 'admin'
66  );
67  }
68 
73  public function _forwards()
74  {
75  return array();
76  }
77 
81  public function executeCommand()
82  {
86  global $ilCtrl;
87 
88  $next_class = $ilCtrl->getNextClass();
89 
90  require_once 'Modules/Chatroom/classes/class.ilChatroomTabGUIFactory.php';
91 
92  $tabFactory = new ilChatroomTabGUIFactory($this);
93  $tabFactory->getAdminTabsForCommand($ilCtrl->getCmd());
94 
95  switch($next_class)
96  {
97  case 'ilpermissiongui':
98  include_once 'Services/AccessControl/classes/class.ilPermissionGUI.php';
99  $this->prepareOutput();
100  $perm_gui = new ilPermissionGUI($this);
101  $ilCtrl->forwardCommand($perm_gui);
102  break;
103 
104  default:
105  $res = explode('-', $ilCtrl->getCmd(), 2);
106  if(!array_key_exists(1, $res))
107  {
108  $res[1] = '';
109  }
110  $this->dispatchCall($res[0], $res[1]);
111  }
112  }
113 
117  public function getConnector()
118  {
119  require_once 'Modules/Chatroom/classes/class.ilChatroomServerConnector.php';
120  require_once 'Modules/Chatroom/classes/class.ilChatroomServerSettings.php';
121 
122  $settings = ilChatroomServerSettings::loadDefault();
123  $connector = new ilChatroomServerConnector($settings);
124 
125  return $connector;
126  }
127 
132  public function getRefId()
133  {
134  return $this->object->getRefId();
135  }
136 }
Class ilObjChatroomAdminGUI GUI class for chatroom objects.
Class ilChatroomServerHandler.
static _goto($ref_id)
Overwrites $_GET[&#39;ref_id&#39;] with given $ref_id.
$_GET["client_id"]
_forwards()
Returns empty array.
global $ilCtrl
Definition: ilias.php:18
prepareOutput($a_show_subobjects=true)
prepare output
static _gotoRepositoryNode($a_ref_id, $a_cmd="frameset")
Goto repository root.
Class ilChatroomServerConnector.
static getDefaultDefinitionWithCustomGUIPath($moduleName, $guiScope='')
Returns an Instance of ilChatroomObjectDefinition, using given $moduleName and $guiScope as parameter...
Create styles array
The data for the language used.
Class ilChatroomTabGUIFactory.
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
getObjectDefinition()
Returns object definition by calling getDefaultDefinitionWithCustomGUIPath method in ilChatroomObject...
executeCommand()
execute command