ILIAS
release_8 Revision v8.23
|
Explorer class that works on tree objects (Services/Tree) More...
Public Member Functions | |
__construct (string $a_expl_id, $a_parent_obj, string $a_parent_cmd, ilTree $a_tree, string $a_node_parameter_name="node_id") | |
getTree () | |
setOrderField (string $a_val, bool $a_numeric=false) | |
getOrderField () | |
setTypeWhiteList (array $a_val) | |
Set type white list. More... | |
getTypeWhiteList () | |
Get type white list. More... | |
setTypeBlackList (array $a_val) | |
Set type black list. More... | |
getTypeBlackList () | |
Get type black list. More... | |
setPreloadChilds (bool $a_val) | |
getPreloadChilds () | |
getSuccessorNode ( $a_node_id, string $a_type="") | |
Get successor node (currently only(!) based on lft/rgt tree values) More... | |
getChildsOfNode ($a_parent_node_id) | |
Get childs of node. More... | |
getNodeId ($a_node) | |
Get id for node. More... | |
getNodeIconAlt ($a_node) | |
Get node icon alt attribute. More... | |
getRootNode () | |
Get root node. More... | |
setRootId ($a_root) | |
setPathOpen ($a_id) | |
Set node path to be opened. More... | |
getHTML ($new=false) | |
Get HTML. More... | |
getChildren ($record, $environment=null) | |
Get a list of records (that list can also be empty). More... | |
build (\ILIAS\UI\Component\Tree\Node\Factory $factory, $record, $environment=null) | |
getTreeLabel () | |
getTreeComponent () | |
toggleExplorerNodeState () | |
Should be called by an ilCtrl-enabled command class if a tree node toggle action should be processed. More... | |
![]() | |
setChildLimit (int $a_val) | |
getChildLimit () | |
setSearchTerm (string $a_val) | |
getSearchTerm () | |
setMainTemplate (ilGlobalTemplateInterface $a_main_tpl=null) | |
getRootNode () | |
Get root node. More... | |
getChildsOfNode ($a_parent_node_id) | |
Get children of node. More... | |
getNodeContent ($a_node) | |
Get content of a node. More... | |
getNodeId ($a_node) | |
Get id of a node. More... | |
getNodeHref ($a_node) | |
Get href for node. More... | |
nodeHasVisibleChilds ($a_node) | |
Node has children Please note that this standard method may not be optimal depending on what a derived class does in isNodeVisible. More... | |
sortChilds (array $a_childs, $a_parent_node_id) | |
Sort childs. More... | |
getNodeIcon ($a_node) | |
Get node icon path. More... | |
getNodeIconAlt ($a_node) | |
Get node icon alt attribute. More... | |
getNodeTarget ($a_node) | |
Get node target (frame) attribute. More... | |
getNodeOnClick ($a_node) | |
Get node onclick attribute. More... | |
isNodeVisible ($a_node) | |
Is node visible? More... | |
isNodeHighlighted ($a_node) | |
Is node highlighted? More... | |
isNodeClickable ($a_node) | |
Is node clickable? More... | |
getId () | |
Get id of explorer element. More... | |
setSkipRootNode (bool $a_val) | |
getSkipRootNode () | |
setAjax (bool $a_val) | |
getAjax () | |
setSecondaryHighlightedNodes (array $a_val) | |
Set secondary (background) highlighted nodes. More... | |
getSecondaryHighlightedNodes () | |
Get secondary (background) highlighted nodes. More... | |
setNodeOpen ($a_id) | |
Set node to be opened (additional custom opened node, not standard expand behaviour) More... | |
setSelectMode (string $a_postvar, bool $a_multi=false) | |
Set select mode (to deactivate, pass an empty string as postvar) More... | |
setNodeSelected ($a_id) | |
Set node to be opened (additional custom opened node, not standard expand behaviour) More... | |
setOfflineMode (bool $a_val) | |
getOfflineMode () | |
handleCommand () | |
Handle explorer internal command. More... | |
getContainerId () | |
openNode () | |
Open node. More... | |
closeNode () | |
Close node. More... | |
getNodeAsync () | |
Get node asynchronously. More... | |
beforeRendering () | |
Before rendering. More... | |
getOnLoadCode () | |
Get on load code. More... | |
getHTML () | |
renderNode ($a_node, ilTemplate $tpl) | |
Render node. More... | |
renderChilds ($a_node_id, ilTemplate $tpl) | |
Render childs. More... | |
getDomNodeIdForNodeId ($a_node_id) | |
Get DOM node id for node id. More... | |
getNodeIdForDomNodeId (string $a_dom_node_id) | |
Get node id for dom node id. More... | |
listItemStart (ilTemplate $tpl, $a_node) | |
List item start. More... | |
listItemEnd (ilTemplate $tpl) | |
listStart (ilTemplate $tpl) | |
listEnd (ilTemplate $tpl) | |
isNodeOnclickEnabled () | |
setNodeOnclickEnabled (bool $nodeOnclickEnabled) | |
isEnableDnd () | |
setEnableDnd (bool $enable_dnd) | |
![]() | |
build (Node\Factory $factory, $record, $environment=null) | |
Build and return a Node. More... | |
Protected Member Functions | |
preloadChilds () | |
matches ($node) | |
Does a node match a search term (or is search term empty) More... | |
getRootId () | |
createNode (\ILIAS\UI\Component\Tree\Node\Factory $factory, $record) | |
Creates at tree node, can be overwritten in derivatives if another node type should be used. More... | |
getNodeStateToggleCmdClasses ($record) | |
Should return an array of ilCtrl-enabled command classes which should be used to build the URL for the expand/collapse actions applied on a tree node. More... | |
render () | |
![]() | |
isNodeSelectable ($a_node) | |
Is node selectable? More... | |
getNodeToggleOnClick ($a_node) | |
Get onclick attribute for node toggling. More... | |
getSelectOnClick ($a_node) | |
Get onclick attribute for selecting radio/checkbox. More... | |
isNodeOpen ($node_id) | |
Get all open nodes. More... | |
getJSTreePlugins () | |
isNodeRequested (string $a_node_id) | |
Additional Inherited Members | |
![]() | |
static | getLocalExplorerJsPath () |
static | getLocalJsTreeJsPath () |
static | getLocalJsTreeCssPath () |
static | createHTMLExportDirs (string $a_target_dir) |
static | init (ilGlobalTemplateInterface $a_main_tpl=null) |
![]() | |
static string | $js_tree_path = "./node_modules/jstree/dist/jstree.js" |
static string | $js_tree_path_css = "./node_modules/jstree/dist/themes/default/style.min.css" |
static string | $js_expl_path = "./Services/UIComponent/Explorer2/js/Explorer2.js" |
Explorer class that works on tree objects (Services/Tree)
Definition at line 26 of file class.ilTreeExplorerGUI.php.
ilTreeExplorerGUI::__construct | ( | string | $a_expl_id, |
$a_parent_obj, | |||
string | $a_parent_cmd, | ||
ilTree | $a_tree, | ||
string | $a_node_parameter_name = "node_id" |
||
) |
Definition at line 44 of file class.ilTreeExplorerGUI.php.
References $DIC, ILIAS\GlobalScreen\Provider\__construct(), ILIAS\Repository\lng(), and ILIAS\Repository\ui().
ilTreeExplorerGUI::build | ( | \ILIAS\UI\Component\Tree\Node\Factory | $factory, |
$record, | |||
$environment = null |
|||
) |
Definition at line 375 of file class.ilTreeExplorerGUI.php.
References ilExplorerBaseGUI\$id, $url, createNode(), ILIAS\Repository\ctrl(), ilExplorerBaseGUI\getNodeHref(), getNodeId(), getNodeStateToggleCmdClasses(), and ilExplorerBaseGUI\isNodeOpen().
|
protected |
Creates at tree node, can be overwritten in derivatives if another node type should be used.
Definition at line 346 of file class.ilTreeExplorerGUI.php.
References ilExplorerBaseGUI\getNodeContent(), ilExplorerBaseGUI\getNodeIcon(), getNodeIconAlt(), and ILIAS\Repository\ui().
Referenced by build().
ilTreeExplorerGUI::getChildren | ( | $record, | |
$environment = null |
|||
) |
Get a list of records (that list can also be empty).
Each record will be relayed to $this->build to retrieve a Node. Also, each record will be asked for Sub-Nodes using this function.
Implements ILIAS\UI\Component\Tree\TreeRecursion.
Definition at line 338 of file class.ilTreeExplorerGUI.php.
References getChildsOfNode().
Referenced by ilLMTOCExplorerGUI\renderLSTocNode().
ilTreeExplorerGUI::getChildsOfNode | ( | $a_parent_node_id | ) |
Get childs of node.
int | string | $a_parent_node_id | parent id |
Definition at line 206 of file class.ilTreeExplorerGUI.php.
References $c, getOrderField(), ilExplorerBaseGUI\getSearchTerm(), getTypeBlackList(), getTypeWhiteList(), ilExplorerBaseGUI\isNodeRequested(), and matches().
Referenced by ilPublicSectionExplorerGUI\getAllNodes(), and getChildren().
ilTreeExplorerGUI::getHTML | ( | $new = false | ) |
Get HTML.
Definition at line 325 of file class.ilTreeExplorerGUI.php.
References getPreloadChilds(), preloadChilds(), and render().
ilTreeExplorerGUI::getNodeIconAlt | ( | $a_node | ) |
Get node icon alt attribute.
object | array | $a_node | node |
Definition at line 273 of file class.ilTreeExplorerGUI.php.
References $lng, and ilLanguage\txt().
Referenced by ilTaxonomyClassificationExplorerGUI\createNode(), ilForumExplorerGUI\createNode(), and createNode().
ilTreeExplorerGUI::getNodeId | ( | $a_node | ) |
Get id for node.
object | array | $a_node |
Definition at line 263 of file class.ilTreeExplorerGUI.php.
Referenced by build(), ilTaxonomyClassificationExplorerGUI\createNode(), ilPublicSectionExplorerGUI\getAllNodes(), ilMediaPoolExplorerGUI\getNodeContent(), ilAdministrationExplorerGUI\getNodeContent(), ilLMExplorerGUI\getNodeContent(), ilRepositoryExplorerGUI\getNodeContent(), ilRepositorySelectorExplorerGUI\getNodeContent(), ilMailExplorer\getNodeContent(), ilLMTOCExplorerGUI\getNodeContent(), ilMailExplorer\getNodeHref(), ilLMEditorExplorerGUI\getNodeIcon(), ilPublicSectionExplorerGUI\getNodeIcon(), ilMediaPoolExplorerGUI\getNodeIcon(), ilMailExplorer\getNodeIcon(), ilAdministrationExplorerGUI\getNodeIconAlt(), ilRepositoryExplorerGUI\getNodeIconAlt(), ilRepositorySelectorExplorerGUI\getNodeIconAlt(), ilMediaPoolExplorerGUI\isNodeHighlighted(), ilLMExplorerGUI\isNodeHighlighted(), ilAdministrationExplorerGUI\isNodeHighlighted(), ilRepositoryExplorerGUI\isNodeHighlighted(), and ilRepositorySelectorExplorerGUI\isNodeHighlighted().
|
protected |
Should return an array of ilCtrl-enabled command classes which should be used to build the URL for the expand/collapse actions applied on a tree node.
$record |
Definition at line 370 of file class.ilTreeExplorerGUI.php.
Referenced by build().
ilTreeExplorerGUI::getOrderField | ( | ) |
Definition at line 73 of file class.ilTreeExplorerGUI.php.
References $order_field.
Referenced by getChildsOfNode().
ilTreeExplorerGUI::getPreloadChilds | ( | ) |
Definition at line 119 of file class.ilTreeExplorerGUI.php.
References $preload_childs.
Referenced by getHTML().
|
protected |
Definition at line 301 of file class.ilTreeExplorerGUI.php.
References getTree().
Referenced by getRootNode(), and ilWorkspaceExplorerGUI\isNodeHighlighted().
ilTreeExplorerGUI::getRootNode | ( | ) |
Get root node.
Definition at line 285 of file class.ilTreeExplorerGUI.php.
References $root_node_data, getRootId(), and getTree().
Referenced by ilPublicSectionExplorerGUI\getAllNodes(), ilTaxonomyClassificationExplorerGUI\getNodeContent(), ilMediaPoolExplorerGUI\getNodeContent(), ilTaxonomyExplorerGUI\getNodeContent(), ilAdministrationExplorerGUI\getNodeContent(), ilLMExplorerGUI\getNodeContent(), ilRepositorySelectorExplorerGUI\getNodeContent(), ilLMEditorExplorerGUI\getNodeIcon(), ilPublicSectionExplorerGUI\getNodeIcon(), ilMediaPoolExplorerGUI\getNodeIcon(), ilAdministrationExplorerGUI\getNodeIconAlt(), ilRepositorySelectorExplorerGUI\getNodeIconAlt(), ilTaxonomyClassificationExplorerGUI\getTreeComponent(), getTreeComponent(), ilMediaPoolExplorerGUI\isNodeHighlighted(), ilLMExplorerGUI\isNodeHighlighted(), ilAdministrationExplorerGUI\isNodeHighlighted(), ilRepositorySelectorExplorerGUI\isNodeHighlighted(), and preloadChilds().
ilTreeExplorerGUI::getSuccessorNode | ( | $a_node_id, | |
string | $a_type = "" |
||
) |
Get successor node (currently only(!) based on lft/rgt tree values)
int | string | $a_node_id | node id |
Definition at line 177 of file class.ilTreeExplorerGUI.php.
References getTree().
Referenced by ilLMTOCExplorerGUI\isNodeClickable().
ilTreeExplorerGUI::getTree | ( | ) |
Definition at line 60 of file class.ilTreeExplorerGUI.php.
References $tree.
Referenced by ilLMTOCExplorerGUI\getNodeHref(), getRootId(), ilSkillTemplateTreeExplorerGUI\getRootNode(), ilOrgUnitExplorerGUI\getRootNode(), ilRepositoryExplorerGUI\getRootNode(), ilLMTOCExplorerGUI\getRootNode(), getRootNode(), getSuccessorNode(), ilTaxonomyClassificationExplorerGUI\getTreeComponent(), getTreeComponent(), ilLMTOCExplorerGUI\isNodeClickable(), and setPathOpen().
ilTreeExplorerGUI::getTreeComponent | ( | ) |
Definition at line 416 of file class.ilTreeExplorerGUI.php.
References $data, Vendor\Package\$f, $tree, ilExplorerBaseGUI\getNodeContent(), ilTree\getNodeData(), getRootNode(), getTree(), getTreeLabel(), ilTree\readRootId(), and ILIAS\Repository\ui().
Referenced by render().
ilTreeExplorerGUI::getTreeLabel | ( | ) |
Definition at line 411 of file class.ilTreeExplorerGUI.php.
References $tree_label.
Referenced by ilTaxonomyClassificationExplorerGUI\getTreeComponent(), and getTreeComponent().
ilTreeExplorerGUI::getTypeBlackList | ( | ) |
Get type black list.
Definition at line 109 of file class.ilTreeExplorerGUI.php.
References $type_black_list.
Referenced by getChildsOfNode(), and preloadChilds().
ilTreeExplorerGUI::getTypeWhiteList | ( | ) |
Get type white list.
Definition at line 91 of file class.ilTreeExplorerGUI.php.
References $type_white_list.
Referenced by ilIntLinkRepItemExplorerGUI\__construct(), getChildsOfNode(), preloadChilds(), ilConditionSelector\setRefId(), and ilRepositorySelectorExplorerGUI\sortChilds().
|
protected |
Does a node match a search term (or is search term empty)
object | array | $node |
Definition at line 248 of file class.ilTreeExplorerGUI.php.
References ilExplorerBaseGUI\getNodeContent(), and ilExplorerBaseGUI\getSearchTerm().
Referenced by getChildsOfNode().
|
protected |
Definition at line 124 of file class.ilTreeExplorerGUI.php.
References $c, getRootNode(), getTypeBlackList(), getTypeWhiteList(), and ilArrayUtil\sortArray().
Referenced by getHTML().
|
protected |
Definition at line 458 of file class.ilTreeExplorerGUI.php.
References getTreeComponent(), and ILIAS\Repository\ui().
Referenced by getHTML().
ilTreeExplorerGUI::setOrderField | ( | string | $a_val, |
bool | $a_numeric = false |
||
) |
Definition at line 65 of file class.ilTreeExplorerGUI.php.
Referenced by ilMediaPoolExplorerGUI\__construct(), ilMailExplorer\__construct(), ilTaxonomyExplorerGUI\__construct(), ilAdministrationExplorerGUI\__construct(), and ilSkillTemplateTreeExplorerGUI\__construct().
ilTreeExplorerGUI::setPathOpen | ( | $a_id | ) |
Set node path to be opened.
string | $a_id | node id |
Definition at line 312 of file class.ilTreeExplorerGUI.php.
References ilExplorerBaseGUI\$id, $path, getTree(), and ilExplorerBaseGUI\setNodeOpen().
Referenced by ilGroupActionTargetExplorerGUI\__construct(), ilLMExplorerGUI\__construct(), ilAdministrationExplorerGUI\__construct(), ilWorkspaceExplorerGUI\__construct(), and SurveyQuestionGUI\addMaterial().
ilTreeExplorerGUI::setPreloadChilds | ( | bool | $a_val | ) |
Definition at line 114 of file class.ilTreeExplorerGUI.php.
Referenced by ilLMExplorerGUI\__construct(), ilForumExplorerGUI\__construct(), and ilTaxonomyExplorerGUI\__construct().
ilTreeExplorerGUI::setRootId | ( | $a_root | ) |
int | string | $a_root |
Definition at line 296 of file class.ilTreeExplorerGUI.php.
ilTreeExplorerGUI::setTypeBlackList | ( | array | $a_val | ) |
Set type black list.
array | $a_val | array of strings of node types that should be filtered out |
Definition at line 100 of file class.ilTreeExplorerGUI.php.
ilTreeExplorerGUI::setTypeWhiteList | ( | array | $a_val | ) |
Set type white list.
array | $a_val | array of strings of node types that should be retrieved |
Definition at line 82 of file class.ilTreeExplorerGUI.php.
Referenced by ilMaterialExplorer\__construct(), ilForumMoveTopicsExplorer\__construct(), ilTestQuestionPoolSelectorExplorer\__construct(), ilMediaPoolExplorerGUI\__construct(), ilPCFileItemFileSelectorGUI\__construct(), ilIntLinkRepItemExplorerGUI\__construct(), ilAdministrationExplorerGUI\__construct(), ilLMTOCExplorerGUI\__construct(), ilSkillTemplateTreeExplorerGUI\__construct(), ilOrgUnitExplorerGUI\__construct(), ilWorkspaceExplorerGUI\__construct(), ilPersonalSkillsGUI\assignMaterial(), ilWorkspaceGSToolProvider\getTree(), ilObjWorkspaceFolderGUI\render(), ilExSubmissionObjectGUI\renderWorkspaceExplorer(), and ilObjWorkspaceFolderGUI\showMoveIntoObjectTree().
ilTreeExplorerGUI::toggleExplorerNodeState | ( | ) |
Should be called by an ilCtrl-enabled command class if a tree node toggle action should be processed.
Definition at line 440 of file class.ilTreeExplorerGUI.php.
References ILIAS\LTI\ToolProvider\$key, ilExplorerBaseGUI\$node_parameter_name, exit, and ILIAS\Repository\int().
Referenced by ilObjForumGUI\toggleExplorerNodeStateObject().
|
protected |
Definition at line 40 of file class.ilTreeExplorerGUI.php.
|
protected |
Definition at line 36 of file class.ilTreeExplorerGUI.php.
Referenced by ilSkillTemplateTreeExplorerGUI\getChildsOfNode(), ilPersonalSkillExplorerGUI\getChildsOfNode(), ilRepositoryExplorerGUI\getChildsOfNode(), ilAdministrationExplorerGUI\sortChilds(), ilRepositorySelectorExplorerGUI\sortChilds(), and ilRepositoryExplorerGUI\sortChilds().
|
protected |
Definition at line 29 of file class.ilTreeExplorerGUI.php.
|
protected |
Definition at line 28 of file class.ilTreeExplorerGUI.php.
Referenced by ilAdministrationExplorerGUI\getNodeContent(), ilSkillTemplateTreeExplorerGUI\getNodeContent(), ilRepositoryExplorerGUI\getNodeContent(), ilRepositorySelectorExplorerGUI\getNodeContent(), ilWorkspaceExplorerGUI\getNodeContent(), ilPersonalSkillExplorerGUI\getNodeContent(), ilLMEditorExplorerGUI\getNodeIconAlt(), ilAdministrationExplorerGUI\getNodeIconAlt(), ilRepositoryExplorerGUI\getNodeIconAlt(), ilRepositorySelectorExplorerGUI\getNodeIconAlt(), ilSkillTemplateTreeExplorerGUI\getNodeIconAlt(), ilPersonalSkillExplorerGUI\getNodeIconAlt(), and getNodeIconAlt().
|
protected |
Definition at line 32 of file class.ilTreeExplorerGUI.php.
Referenced by getOrderField().
|
protected |
Definition at line 33 of file class.ilTreeExplorerGUI.php.
|
protected |
Definition at line 38 of file class.ilTreeExplorerGUI.php.
Referenced by getPreloadChilds().
|
protected |
Definition at line 37 of file class.ilTreeExplorerGUI.php.
|
protected |
Definition at line 41 of file class.ilTreeExplorerGUI.php.
Referenced by ilLMTOCExplorerGUI\getRootNode().
|
protected |
Definition at line 39 of file class.ilTreeExplorerGUI.php.
Referenced by getRootNode().
|
protected |
Definition at line 30 of file class.ilTreeExplorerGUI.php.
Referenced by ilMaterialExplorer\__construct(), ilPublicSectionExplorerGUI\__construct(), ilLMExplorerGUI\__construct(), ilAdministrationExplorerGUI\__construct(), ilSkillTemplateTreeExplorerGUI\__construct(), ilPersonalSkillExplorerGUI\__construct(), ilRepositoryExplorerGUI\getTopNodeForRefId(), getTree(), ilTaxonomyClassificationExplorerGUI\getTreeComponent(), getTreeComponent(), ilConditionSelector\isNodeVisible(), and ilRepositoryExplorerGUI\isNodeVisible().
|
protected |
Definition at line 31 of file class.ilTreeExplorerGUI.php.
Referenced by getTreeLabel().
|
protected |
Definition at line 35 of file class.ilTreeExplorerGUI.php.
Referenced by getTypeBlackList().
|
protected |
Definition at line 34 of file class.ilTreeExplorerGUI.php.
Referenced by getTypeWhiteList().
|
protected |
Definition at line 42 of file class.ilTreeExplorerGUI.php.