Class humhub\modules\directory\widgets\Menu
Inheritance | humhub\modules\directory\widgets\Menu » humhub\modules\ui\menu\widgets\LeftNavigation » humhub\modules\ui\menu\widgets\Menu » humhub\widgets\JsWidget » humhub\components\Widget » yii\base\Widget |
---|---|
Available since version | 0.21 |
Directory module navigation
Public Properties
Property | Type | Description | Defined By |
---|---|---|---|
$container | string | Html container element. | humhub\widgets\JsWidget |
$content | string | Html content. | humhub\widgets\JsWidget |
$events | [] | humhub\widgets\JsWidget | |
$fadeIn | boolean|string|integer | humhub\widgets\JsWidget | |
$id | string | humhub\widgets\JsWidget | |
$init | mixed | humhub\widgets\JsWidget | |
$jsWidget | string | humhub\widgets\JsWidget | |
$options | humhub\widgets\JsWidget | ||
$panelTitle | string | The title of the panel | humhub\modules\ui\menu\widgets\LeftNavigation |
$render | boolean | If set to false this widget won't be rendered | humhub\components\Widget |
$template | string | Template view file of the navigation | humhub\modules\ui\menu\widgets\LeftNavigation |
$visible | boolean | humhub\widgets\JsWidget | |
$widgetLayout | string | Defines an optional layout | humhub\components\Widget |
Protected Properties
Property | Type | Description | Defined By |
---|---|---|---|
$entries | humhub\modules\ui\menu\MenuEntry[] | The menu entries | humhub\modules\ui\menu\widgets\Menu |
Public Methods
Method | Description | Defined By |
---|---|---|
addEntry() | Add new menu entry to the navigation | humhub\modules\ui\menu\widgets\Menu |
addItem() | humhub\modules\ui\menu\widgets\Menu | |
addItemGroup() | humhub\modules\ui\menu\widgets\Menu | |
deleteItemByUrl() | humhub\modules\ui\menu\widgets\Menu | |
getActive() | humhub\modules\ui\menu\widgets\Menu | |
getActiveEntry() | Returns the first active menu entry | humhub\modules\ui\menu\widgets\Menu |
getAttributes() | Returns all html attributes for used by this widget and will normally inserted in the widgets root html element. | humhub\modules\ui\menu\widgets\LeftNavigation |
getEntries() | Returns all entries filtered by $type. If no $type filter is given all entries are returned. | humhub\modules\ui\menu\widgets\Menu |
getEntryById() | Returns the first entry with the given id | humhub\modules\ui\menu\widgets\Menu |
getEntryByUrl() | Returns the first entry with the given URL | humhub\modules\ui\menu\widgets\Menu |
getFirstEntry() | humhub\modules\ui\menu\widgets\Menu | |
getId() | Returns the html id of this widget, if no id is set this function will generate an id if $autoGenerate is set to true (default). | humhub\widgets\JsWidget |
getItemGroups() | humhub\modules\ui\menu\widgets\Menu | |
getItems() | humhub\modules\ui\menu\widgets\Menu | |
getLayoutViewParams() | Returns an array of view parameter used if \humhub\components\layout is set. | humhub\components\Widget |
getSortedEntries() | Sorts the entry list by sortOrder and returns the sorted entry list. | humhub\modules\ui\menu\widgets\Menu |
hasMultipleEntries() | Checks if this menu contains multiple entries of the given $type, or at all if no $type filter is given. | humhub\modules\ui\menu\widgets\Menu |
init() | humhub\modules\directory\widgets\Menu | |
markAsActive() | This function provides static menu entry activation, by entry id or url. | humhub\modules\ui\menu\widgets\Menu |
markAsInactive() | This function provides static menu entry inactivation, by entry id or url. | humhub\modules\ui\menu\widgets\Menu |
process() | Process is a wrapper for the run method | humhub\components\Widget |
removeEntry() | Removes the entry from the navigation | humhub\modules\ui\menu\widgets\Menu |
run() | Default implementation of JsWidget. | humhub\widgets\JsWidget |
setActive() | Activates an entry by given id or url search string. | humhub\modules\ui\menu\widgets\Menu |
setDefaultOptions() | Sets some default data options required by all widgets as the widget implementation and the widget events and initialization trigger. | humhub\widgets\JsWidget |
setEntryActive() | Sets an menu entry active and inactive all other entries | humhub\modules\ui\menu\widgets\Menu |
setInactive() | humhub\modules\ui\menu\widgets\Menu | |
setViewState() | humhub\modules\ui\menu\widgets\Menu | |
widget() | Creates a widget instance and runs it. | humhub\components\Widget |
Protected Methods
Method | Description | Defined By |
---|---|---|
getData() | Returns an array of data-* attributes to configure your clientside js widget. | humhub\widgets\JsWidget |
getOptions() | Assembles all widget attributes and data settings of this widget. | humhub\widgets\JsWidget |
getViewParams() | Returns the parameters which are passed to the view template | humhub\modules\ui\menu\widgets\Menu |
Events
Event | Type | Description | Defined By |
---|---|---|---|
EVENT_CREATE | humhub\libs\WidgetCreateEvent | An event raised before creating a widget. | humhub\components\Widget |
EVENT_RUN | \humhub\modules\ui\menu\widgets\MenuEvent | An event raised before running the navigation widget. | humhub\modules\ui\menu\widgets\Menu |