Class humhub\modules\space\widgets\Menu

Inheritancehumhub\modules\space\widgets\Menu » humhub\widgets\BaseMenu » yii\base\Widget
Available since version0.5

The Main Navigation for a space. It includes the Modules the Stream

Public Methods

Hide inherited methods

MethodDescriptionDefined By
addItem() Adds new Item to the menu humhub\widgets\BaseMenu
addItemGroup() Adds new Item Group to the menu humhub\widgets\BaseMenu
deleteItemByUrl() Removes Item by URL humhub\widgets\BaseMenu
getActive() humhub\widgets\BaseMenu
getAvailablePages() Searches for urls of modules which are activated for the current space and offer an own site over the space menu. humhub\modules\space\widgets\Menu
getDefaultPageUrl() Returns space default / homepage humhub\modules\space\widgets\Menu
getGuestsDefaultPageUrl() Returns space default / homepage humhub\modules\space\widgets\Menu
getItemGroups() Returns all Item Groups humhub\widgets\BaseMenu
getItems() Returns Items of this Navigation humhub\widgets\BaseMenu
init() humhub\modules\space\widgets\Menu
markAsActive() Add the active class from a menue item. humhub\widgets\BaseMenu
markAsInactive() Remove the active class from a menue item. humhub\widgets\BaseMenu
run() Executes the Menu Widget humhub\widgets\BaseMenu
setActive() Activates the menu item with the given url humhub\widgets\BaseMenu
setInactive() humhub\widgets\BaseMenu
setViewState() This function is used in combination with pjax to get sure the required menu is active humhub\widgets\BaseMenu

Constants

Hide inherited constants

ConstantValueDescriptionDefined By
EVENT_INIT 'init' humhub\widgets\BaseMenu
EVENT_RUN 'run' humhub\widgets\BaseMenu

Property Details

$space public property
$template public property
public $template '@humhub/widgets/views/leftNavigation'

Method Details

getAvailablePages() public static method

Searches for urls of modules which are activated for the current space and offer an own site over the space menu.

The urls are associated with a module label.

Returns an array of urls with associated module labes for modules

public static void getAvailablePages ( )
getDefaultPageUrl() public static method

Returns space default / homepage

public static string|null getDefaultPageUrl ( $space )
$space
return string|null

The url to redirect or null for default home

getGuestsDefaultPageUrl() public static method

Returns space default / homepage

public static string|null getGuestsDefaultPageUrl ( $space )
$space
return string|null

The url to redirect or null for default home

init() public method

public void init ( )