ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
ilChatroomCreateTask Class Reference

Class ilChatroomCreateTask. More...

+ Inheritance diagram for ilChatroomCreateTask:
+ Collaboration diagram for ilChatroomCreateTask:

Public Member Functions

 __construct (ilChatroomObjectGUI $gui)
 Constructor. More...
 
 executeDefault ($method)
 Switches gui to visible mode. More...
 
 save ()
 Inserts new object into gui. More...
 
 __construct (ilChatroomObjectGUI $gui)
 
 executeDefault ($requestedMethod)
 

Private Attributes

 $gui
 

Detailed Description

Class ilChatroomCreateTask.

Author
Jan Posselt jposs.nosp@m.elt@.nosp@m.datab.nosp@m.ay.d.nosp@m.e
Version
$Id$

Definition at line 13 of file class.ilChatroomCreateTask.php.

Constructor & Destructor Documentation

◆ __construct()

ilChatroomCreateTask::__construct ( ilChatroomObjectGUI  $gui)

Constructor.

Sets $this->gui using given $gui

Parameters
ilChatroomObjectGUI$gui

Reimplemented from ilChatroomTaskHandler.

Definition at line 25 of file class.ilChatroomCreateTask.php.

26 {
27 $this->gui = $gui;
28 }

References $gui.

Member Function Documentation

◆ executeDefault()

ilChatroomCreateTask::executeDefault (   $method)

Switches gui to visible mode.

Instantiates and prepares form.

@global ilTemplate $tpl @global ilObjUser $ilUser @global ilCtrl2 $ilCtrl

Parameters
string$method

Reimplemented from ilChatroomTaskHandler.

Definition at line 38 of file class.ilChatroomCreateTask.php.

39 {
40 $this->gui->switchToVisibleMode();
41 return $this->gui->createObject();
42 }

Referenced by save().

+ Here is the caller graph for this function:

◆ save()

ilChatroomCreateTask::save ( )

Inserts new object into gui.

@global ilCtrl2 $ilCtrl

Definition at line 49 of file class.ilChatroomCreateTask.php.

50 {
51 global $ilCtrl;
52
53 require_once 'Modules/Chatroom/classes/class.ilChatroomFormFactory.php';
54 $formFactory = new ilChatroomFormFactory();
55 $form = $formFactory->getCreationForm();
56
57 if( $form->checkInput() )
58 {
59 $this->gui->insertObject();
60 $ilCtrl->setParameter( $this->gui, 'ref_id', $this->gui->getRefId() );
61 $ilCtrl->redirect( $this->gui, 'settings-general' );
62 }
63 else
64 {
65 $this->executeDefault( 'create' );
66 }
67 }
executeDefault($method)
Switches gui to visible mode.
Class ilChatroomFormFactory.
global $ilCtrl
Definition: ilias.php:18

References $ilCtrl, and executeDefault().

+ Here is the call graph for this function:

Field Documentation

◆ $gui

ilChatroomCreateTask::$gui
private

Definition at line 16 of file class.ilChatroomCreateTask.php.

Referenced by __construct().


The documentation for this class was generated from the following file: