public function SimpleMegaMenuHelper::getTargetMenus in Simple Mega Menu 8
Same name and namespace in other branches
- 2.0.x src/SimpleMegaMenuHelper.php \Drupal\simple_megamenu\SimpleMegaMenuHelper::getTargetMenus()
Gets the menus targeted by a specific Simple mega menu type.
Parameters
\Drupal\simple_megamenu\Entity\SimpleMegaMenuTypeInterface $entity: The Simple mega menu type entity.
Return value
array The menus targeted by the config entity.
Overrides SimpleMegaMenuHelperInterface::getTargetMenus
2 calls to SimpleMegaMenuHelper::getTargetMenus()
- SimpleMegaMenuHelper::getMegaMenuTypeWhichTargetMenu in src/
SimpleMegaMenuHelper.php - Get SimpleMegaMenuType entities which target a menu.
- SimpleMegaMenuHelper::menuIsTargetedByMegaMenuType in src/
SimpleMegaMenuHelper.php - Is the menu is referenced by a SimpleMegaMenuType entity.
File
- src/
SimpleMegaMenuHelper.php, line 35
Class
- SimpleMegaMenuHelper
- Class SimpleMegaMenuHelper.
Namespace
Drupal\simple_megamenuCode
public function getTargetMenus(SimpleMegaMenuTypeInterface $entity) {
return array_filter($entity
->getTargetMenu());
}