ILIAS  release_9 Revision v9.13-25-g2c18ec4c24f
class.ilChatroomInfoGUI.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
29 {
31  {
32  return new ilInfoScreenGUI($gui);
33  }
34 
35  public function executeDefault(string $requestedMethod): void
36  {
37  $this->redirectIfNoPermission('visible');
38 
39  $this->gui->switchToVisibleMode();
40 
41  $info = $this->createInfoScreenGUI($this->gui);
42 
43  $info->enablePrivateNotes();
44 
45  $refId = $this->getRequestValue('ref_id', $this->refinery->kindlyTo()->int());
46  if (ilChatroom::checkUserPermissions('read', $refId, false)) {
47  $info->enableNews();
48  }
49 
50  if ($requestedMethod === '') {
51  $this->ilCtrl->setCmd('showSummary');
52  } else {
53  $this->ilCtrl->setCmd($requestedMethod);
54  }
55  $this->ilCtrl->forwardCommand($info);
56  }
57 }
static checkUserPermissions($permissions, int $ref_id, bool $send_info=true)
Checks user permissions by given array and ref_id.
Class ilInfoScreenGUI.
redirectIfNoPermission($permission)
Checks for requested permissions and redirects if the permission check failed.
getRequestValue(string $key, Transformation $trafo, $default=null)
createInfoScreenGUI(ilChatroomObjectGUI $gui)
$refId
Definition: xapitoken.php:58
executeDefault(string $requestedMethod)
Class ilChatroomGUIHandler.
Class ilChatroomInfoGUI Provides methods to prepare and display the info task.