Commit 078e54e4 authored by dj3c1t's avatar dj3c1t

menu service returns array of items

parent 0af28575
Pipeline #46 skipped
......@@ -81,11 +81,18 @@ class Menus {
$menu_item = array();
if(isset($menu_item_infos["method"])) {
$menu_service = $this->container->get($menu_item_infos["service"]);
$menu_item = $menu_service->$menu_item_infos["method"]();
$menu_items = $menu_service->$menu_item_infos["method"]();
foreach($menu_items as $menu_item) {
if(isset($menu_item["route"])) {
$this->menu[] = $menu_item;
}
}
}
}
if(isset($menu_item["route"])) {
$this->menu[] = $menu_item;
else {
if(isset($menu_item["route"])) {
$this->menu[] = $menu_item;
}
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment