4 require_once
'Modules/Chatroom/classes/class.ilChatroom.php';
5 require_once
'Modules/Chatroom/classes/class.ilChatroomUser.php';
18 public function delete()
26 $users = $_REQUEST[
'banned_user_id'];
31 $ilCtrl->redirect($this->gui,
'ban-show');
35 $room->unbanUser($users);
37 $ilCtrl->redirect($this->gui,
'ban-show');
51 public function show()
58 include_once
'Modules/Chatroom/classes/class.ilChatroom.php';
62 $this->gui->switchToVisibleMode();
64 require_once
'Modules/Chatroom/classes/class.ilBannedUsersTableGUI.php';
67 $table->setFormAction($ilCtrl->getFormAction($this->gui,
'ban-show'));
73 $table->setData($room->getBannedUsers());
76 $this->gui->tpl->setVariable(
'ADM_CONTENT', $table->getHTML());
87 $subRoomId = $_REQUEST[
'sub'];
88 $userToBan = $_REQUEST[
'user'];
92 $connector = $this->gui->getConnector();
93 $response = $connector->sendBan($room->getRoomId(), $subRoomId, $userToBan);
97 $room->banUser($_REQUEST[
'user']);
98 $room->disconnectUser($_REQUEST[
'user']);
redirectIfNoPermission($permission)
Checks for requested permissions and redirects if the permission check failed.
sendResponse($response)
Sends a json encoded response and exits the php process.
exitIfNoRoomExists($room)
Checks if a ilChatroom exists.
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
static checkUserPermissions($permissions, $ref_id, $send_info=true)
Checks user permissions by given array and ref_id.
Class ilChatroomGUIHandler.
Class ilBannedUsersTableGUI.
active()
Kicks and bans user, fetched from $_REQUEST['user'] and adds history entry.
isSuccessful($response)
Checks for success param in an json decoded response.
Create styles array
The data for the language used.
static byObjectId($object_id)
Returns ilChatroom object by given $object_id.
executeDefault($method)
{}