ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
class.ilChatroomInfoGUI.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (c) 1998-2009 ILIAS open source, Extended GPL, see docs/LICENSE */
3 
12 {
18  public function executeDefault($method)
19  {
20  include_once 'Modules/Chatroom/classes/class.ilChatroom.php';
21 
22  $this->redirectIfNoPermission('read');
23 
24  $this->gui->switchToVisibleMode();
25 
26  if (!ilChatroom::checkUserPermissions("visible", $this->gui->ref_id, false)) {
27  $this->gui->ilias->raiseError(
28  $this->ilLng->txt("msg_no_perm_read"),
29  $this->ilias->error_obj->MESSAGE
30  );
31  }
32 
33  $info = $this->createInfoScreenGUI($this->gui);
34 
35  $info->enablePrivateNotes();
36 
37  if (ilChatroom::checkUserPermissions("read", (int) $_GET["ref_id"], false)) {
38  $info->enableNews();
39  }
40 
41  $info->addMetaDataSections(
42  $this->gui->object->getId(),
43  0,
44  $this->gui->object->getType()
45  );
46  if (!$method) {
47  $this->ilCtrl->setCmd('showSummary');
48  } else {
49  $this->ilCtrl->setCmd($method);
50  }
51  $this->ilCtrl->forwardCommand($info);
52  }
53 
58  protected function createInfoScreenGUI($gui)
59  {
60  require_once 'Services/InfoScreen/classes/class.ilInfoScreenGUI.php';
61  return new ilInfoScreenGUI($gui);
62  }
63 }
This class provides processing control methods.
Class ilInfoScreenGUI.
$_GET["client_id"]
redirectIfNoPermission($permission)
Checks for requested permissions and redirects if the permission check failed.
setCmd($a_cmd)
Set the current command.
executeDefault($method)
Prepares and displays the info screen.
static checkUserPermissions($permissions, $ref_id, $send_info=true)
Checks user permissions by given array and ref_id.
Class ilChatroomGUIHandler.
redirection script todo: (a better solution should control the processing via a xml file) ...
Class ilChatroomInfoGUI Provides methods to prepare and display the info task.
$info
Definition: index.php:5
forwardCommand($a_gui_object)
Forward flow of control to next gui class this invokes the executeCommand() method of the gui object ...