Method | Description | |
---|---|---|
addMenuItem ( string $category, integer $position, array $menu ) : void | Add an item to menu. | |
addRoute ( Closure $callback ) | Add a route. A router instance will be passed to the given callback. |
public static addMenuItem ( string $category, integer $position, array $menu ) : void | ||
$category | string | 'user' or 'admin' |
$position | integer | Where to insert the given item, start from 0. |
$menu | array | e.g. [ 'title' => 'Title', # will be translated by translator 'link' => 'user/config', # route link 'icon' => 'fa-book' # font-awesome icon ] |
return | void |