Backend\VueComponents\TreeView\SectionDefinition

Overview

SectionDefinition encapsulates Treeview section information.


Protected Properties

protected string $key

protected mixed $menuItems

protected mixed $createMenuItems

protected string $label

protected array $nodes

protected mixed $childKeyPrefix

protected bool $hasApiMenuItems

protected mixed $userData


Public Methods

public __construct()

public __construct($label, $key): void

public addCreateMenuItem()

public addCreateMenuItem($type, $label = null, $command = null): void

public addMenuItem()

public addMenuItem($type, $label = null, $command = null): void

public addMenuItemObject()

public addMenuItemObject($item): void

public addNode()

public addNode($label, $key): void

public getNodes()

public getNodes(): void

public setChildKeyPrefix()

public setChildKeyPrefix($prefix): void

public setHasApiMenuItems()

public setHasApiMenuItems($hasApiMenuItems): void

Indicates that the section supports API-generated menu items.

public setUserData()

public setUserData($userData): void

Sets optional user data object.

public setUserDataElement()

public setUserDataElement($key, $value): void

public toArray()

public toArray(): void