ILIAS  release_7 Revision v7.30-3-g800a261c036
ilContainerBlockPropertiesStorageGUI Class Reference

Save container block property. More...

+ Collaboration diagram for ilContainerBlockPropertiesStorageGUI:

Public Member Functions

 __construct ()
 Constructor. More...
 
executeCommand ()
 execute command More...
 
 store ()
 Store property. More...
 

Static Public Member Functions

static storeProperty ($a_block_id, $a_user_id, $a_property, $a_value)
 Store property in session or db. More...
 
static getProperty ($a_block_id, $a_user_id, $a_property)
 Get property in session or db. More...
 

Protected Attributes

 $ctrl
 
 $user
 

Detailed Description

Save container block property.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e

Definition at line 9 of file class.ilContainerBlockPropertiesStorageGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilContainerBlockPropertiesStorageGUI::__construct ( )

Constructor.

Definition at line 24 of file class.ilContainerBlockPropertiesStorageGUI.php.

25 {
26 global $DIC;
27
28 $this->ctrl = $DIC->ctrl();
29 $this->user = $DIC->user();
30 }
user()
Definition: user.php:4
global $DIC
Definition: goto.php:24

References $DIC, and user().

+ Here is the call graph for this function:

Member Function Documentation

◆ executeCommand()

& ilContainerBlockPropertiesStorageGUI::executeCommand ( )

execute command

Definition at line 35 of file class.ilContainerBlockPropertiesStorageGUI.php.

36 {
37 $ilCtrl = $this->ctrl;
38
39 $cmd = $ilCtrl->getCmd();
40 if (in_array($cmd, array("store"))) {
41 $this->$cmd();
42 }
43 }

References $ctrl.

◆ getProperty()

static ilContainerBlockPropertiesStorageGUI::getProperty (   $a_block_id,
  $a_user_id,
  $a_property 
)
static

Get property in session or db.

Parameters
string$a_block_id
int$a_user_id
string$a_property
Returns
bool|string

Definition at line 87 of file class.ilContainerBlockPropertiesStorageGUI.php.

88 {
89 $val = false;
90 if (isset($_SESSION["cont_block"][$a_block_id][$a_user_id][$a_property])) {
91 $val = $_SESSION["cont_block"][$a_block_id][$a_user_id][$a_property];
92 }
94 ->debug("block id: " . $a_block_id . ", user id: " . $a_user_id . ", property: " . $a_property . ", val: " . print_r($val, true));
95 return $val;
96 }
$_SESSION["AccountId"]
static getLogger($a_component_id)
Get component logger.

References $_SESSION, and ilLoggerFactory\getLogger().

Referenced by ilContainerContentGUI\renderItemGroup().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ store()

ilContainerBlockPropertiesStorageGUI::store ( )

Store property.

Definition at line 48 of file class.ilContainerBlockPropertiesStorageGUI.php.

49 {
51
52 switch ($_GET["act"]) {
53
54 case "expand":
55 self::storeProperty($_GET["cont_block_id"], (int) $ilUser->getId(), "opened", "1");
56 break;
57
58 case "collapse":
59 self::storeProperty($_GET["cont_block_id"], (int) $ilUser->getId(), "opened", "0");
60 break;
61 }
62 }
$_GET["client_id"]
static storeProperty($a_block_id, $a_user_id, $a_property, $a_value)
Store property in session or db.
$ilUser
Definition: imgupload.php:18

References $_GET, $ilUser, $user, and storeProperty().

+ Here is the call graph for this function:

◆ storeProperty()

static ilContainerBlockPropertiesStorageGUI::storeProperty (   $a_block_id,
  $a_user_id,
  $a_property,
  $a_value 
)
static

Store property in session or db.

Parameters
string$a_block_id
int$a_user_id
string$a_property
string$a_value

Definition at line 72 of file class.ilContainerBlockPropertiesStorageGUI.php.

73 {
74 $_SESSION["cont_block"][$a_block_id][$a_user_id][$a_property] = $a_value;
76 ->debug("block id: " . $a_block_id . ", user id: " . $a_user_id . ", property: " . $a_property . ", val: " . print_r($a_value, true));
77 }

References $_SESSION, and ilLoggerFactory\getLogger().

Referenced by store().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ $ctrl

ilContainerBlockPropertiesStorageGUI::$ctrl
protected

Definition at line 14 of file class.ilContainerBlockPropertiesStorageGUI.php.

Referenced by executeCommand().

◆ $user

ilContainerBlockPropertiesStorageGUI::$user
protected

Definition at line 19 of file class.ilContainerBlockPropertiesStorageGUI.php.

Referenced by store().


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