◆ __construct()
ilSingleUserShareGUI::__construct |
( |
|
$wsp_access_handler = null , |
|
|
|
$wsp_node_id = null |
|
) |
| |
Definition at line 16 of file class.ilSingleUserShareGUI.php.
References $DIC.
20 $this->tpl = $DIC[
'tpl'];
21 $this->ctrl = $DIC[
'ilCtrl'];
22 $this->lng = $DIC[
'lng'];
25 $this->wsp_access_handler = $wsp_access_handler;
26 $this->wsp_node_id = $wsp_node_id;
◆ cancel()
ilSingleUserShareGUI::cancel |
( |
| ) |
|
◆ executeCommand()
ilSingleUserShareGUI::executeCommand |
( |
| ) |
|
Definition at line 29 of file class.ilSingleUserShareGUI.php.
References $cmd.
31 $forward_class = $this->ctrl->getNextClass($this);
33 switch($forward_class)
36 if (!(
$cmd = $this->ctrl->getCmd()))
38 $cmd =
"initShareForm";
◆ getShareForm()
ilSingleUserShareGUI::getShareForm |
( |
| ) |
|
Definition at line 55 of file class.ilSingleUserShareGUI.php.
References ilTextInputGUI\setSize().
Referenced by initShareForm(), and saveShare().
57 include_once
'./Services/Form/classes/class.ilPropertyFormGUI.php';
60 $form->setTitle($this->lng->txt(
"share_content"));
61 $form->setId(
'share_usr');
63 $form->setFormAction($this->ctrl->getFormAction($this,
'saveShare'));
69 $form->addCommandButton(
'saveShare', $this->lng->txt(
"share"));
70 $form->addCommandButton(
'cancel', $this->lng->txt(
"cancel"));
setSize($a_size)
Set Size.
This class represents a text property in a property form.
◆ initShareForm()
◆ saveShare()
ilSingleUserShareGUI::saveShare |
( |
| ) |
|
|
protected |
Definition at line 75 of file class.ilSingleUserShareGUI.php.
References ilObjUser\_lookupId(), getShareForm(), ilUtil\sendFailure(), ilUtil\sendInfo(), and ilUtil\sendSuccess().
79 if($form->checkInput())
83 $existing = $this->wsp_access_handler->getPermissions($this->wsp_node_id);
85 if(!in_array($user_id, $existing))
87 $this->wsp_access_handler->addPermission($this->wsp_node_id, $user_id);
94 $this->ctrl->returnToParent($this);
101 $this->ctrl->redirect($this);
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
static _lookupId($a_user_str)
Lookup id by login.
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
◆ $ctrl
ilSingleUserShareGUI::$ctrl |
|
protected |
◆ $lng
ilSingleUserShareGUI::$lng |
|
protected |
◆ $tpl
ilSingleUserShareGUI::$tpl |
|
protected |
The documentation for this class was generated from the following file: