Detailed Description
TreeController is used to visualize nodes in a tree view.
The controller supports the following actions:
Parameter | Description |
---|---|
in oid | The object id of the parent Node whose children should be loaded (optional) |
in sort | The attribute to sort the children by (optional) |
in rootTypes | Name of a configuration value in configuration section 'application', that defines an array of root types of the tree (optional, defaults to 'rootTypes') |
out list | An array of associative arrays with keys 'oid', 'displayText', 'isFolder', 'hasChildren' |
Response Actions | |
ok | In all cases |
Definition at line 42 of file TreeController.php.
Protected Member Functions | |
doExecute ($method=null) | |
getChildren ($oid) | |
getRootOIDs () | |
getViewNode (Node $node, $displayText='') | |
isVisible (Node $node) | |
getDisplayText (Node $node) | |
getRootTypes () | |
isRootTypeNode (ObjectId $oid) | |
Protected Member Functions inherited from Controller | |
validate () | |
executeSubAction ($action) | |
redirect ($location, $key=null, $data=null) | |
getLogger () | |
getSession () | |
getPersistenceFacade () | |
getPermissionManager () | |
getActionMapper () | |
getLocalization () | |
getMessage () | |
getConfiguration () | |
requireTransaction () | |
endTransaction ($commit) | |
isLocalizedRequest () | |
checkLanguageParameter () | |
generateCsrfToken ($name, $refresh=true) | |
validateCsrfToken ($name, $invalidate=true) | |
getLocalSessionValue ($key, $default=null) | |
setLocalSessionValue ($key, $value) | |
clearLocalSessionValues () | |
Additional Inherited Members | |
Public Member Functions inherited from Controller | |
__construct (Session $session, PersistenceFacade $persistenceFacade, PermissionManager $permissionManager, ActionMapper $actionMapper, Localization $localization, Message $message, Configuration $configuration) | |
initialize (Request $request, Response $response) | |
execute ($method=null) | |
getRequest () | |
getResponse () | |
Public Attributes inherited from Controller | |
const | CSRF_TOKEN_PARAM = 'csrf_token' |
Member Function Documentation
◆ doExecute()
|
protected |
- See also
- Controller::doExecute()
Reimplemented from Controller.
Definition at line 47 of file TreeController.php.
◆ getChildren()
|
protected |
Get the children for a given oid.
- Parameters
-
$oid The object id
- Returns
- Array of Node instances.
Definition at line 88 of file TreeController.php.
◆ getRootOIDs()
|
protected |
Get the oids of the root nodes.
- Returns
- An array of object ids.
Definition at line 128 of file TreeController.php.
◆ getViewNode()
|
protected |
Get the view of a Node.
- Parameters
-
$node The Node to create the view for $displayText The text to display (will be taken from TreeController::getDisplayText() if not specified) (default: '')
- Returns
- An associative array whose keys correspond to Ext.tree.TreeNode config parameters
Definition at line 139 of file TreeController.php.
◆ isVisible()
|
protected |
Test if a Node should be displayed in the tree.
- Parameters
-
$node Node to display
- Returns
- Boolean
Definition at line 162 of file TreeController.php.
◆ getDisplayText()
|
protected |
Get the display text for a Node.
- Parameters
-
$node Node to display
- Returns
- The display text.
Definition at line 171 of file TreeController.php.
◆ getRootTypes()
|
protected |
Get all root types.
- Returns
- Array of Node instances
Definition at line 185 of file TreeController.php.
◆ isRootTypeNode()
|
protected |
Check if the given oid belongs to a root type node.
- Parameters
-
$oid The object id
- Returns
- Boolean
Definition at line 222 of file TreeController.php.