prepareMenuItemsForRequest()
Overview
public array function prepareMenuItemsForRequest(
required array menuItems
, string legacyViewBase = "/admin/layout/sidebar/"
)
Main entry point. Prepares menu items ready for rendering for the current request/user.
Arguments
Name | Type | Required | Description |
---|---|---|---|
menuItems | array | Yes | Array of top level menu items |
legacyViewBase | string | No (default="/admin/layout/sidebar/") | Base view path to be used for menu backward compatibility. e.g. for default Preside admin sidebar menu, this is /admin/layout/sidebar/{itemid} |