class MenuHelper (View source)

A helper class for menu generation in backend controllers / view helpers

Properties

protected SiteRepository $siteRepository
protected PrivilegeManagerInterface $privilegeManager
protected array $settings
protected IconNameMappingService $iconMapper

Methods

injectSettings(array $settings)

No description

array
buildSiteList(ControllerContext $controllerContext)

Build a list of sites

array
buildModuleList(ControllerContext $controllerContext)

No description

bool
isModuleEnabled(string $modulePath)

Checks whether a module is enabled or disabled in the configuration

array
collectModuleData(ControllerContext $controllerContext, string $module, array $moduleConfiguration, string $modulePath)

No description

Details

injectSettings(array $settings)

No description

Parameters

array $settings

array buildSiteList(ControllerContext $controllerContext)

Build a list of sites

Parameters

ControllerContext $controllerContext

Return Value

array

array buildModuleList(ControllerContext $controllerContext)

No description

Parameters

ControllerContext $controllerContext

Return Value

array

bool isModuleEnabled(string $modulePath)

Checks whether a module is enabled or disabled in the configuration

Parameters

string $modulePath

name of the module including parent modules ("mainModule/subModule/subSubModule")

Return Value

bool

true if module is enabled (default), false otherwise

protected array collectModuleData(ControllerContext $controllerContext, string $module, array $moduleConfiguration, string $modulePath)

No description

Parameters

ControllerContext $controllerContext
string $module
array $moduleConfiguration
string $modulePath

Return Value

array