morningtrain/menumanager

Simple menu includer for Laravel

1.0.3 2016-01-19 17:34 UTC

This package is auto-updated.

Last update: 2024-10-29 04:31:05 UTC


README

Software License

Install

Via Composer

$ composer require morningtrain/menumanager

Add this service provider to your config/app.php file.

morningtrain\menumanager\menumanagerServiceProvider::class,

Usage

	Menu::addItem('admin', ['routealias' => 'someroute', 'title' => 'Menu item title']);
		
	Menu::addItem('admin', ['as' => 'unique_name', 'routealias' => 'someroute', 'title' => 'Indhold', 'children' => [
		['routealias' => 'someroute', 'title' => 'Menu item 1'],
		['routealias' => 'someroute', 'title' => 'Menu item 2'],
		['routealias' => 'someroute', 'title' => 'Menu item 3'],
		['routealias' => 'someroute', 'title' => 'Menu item 4'],
		['routealias' => 'someroute', 'title' => 'Menu item 5'],
	]]);
	
	Menu::addItem('admin', ['as' => 'unique_name', 'routealias' => 'someroute', 'title' => 'Indhold', 'children' => [
		['routealias' => 'someroute', 'title' => 'Menu item 1'],
		['routealias' => 'someroute', 'title' => 'Menu item 2'],
		['routealias' => 'someroute', 'title' => 'Menu item 3'],
		['routealias' => 'someroute', 'title' => 'Menu item 4'],
		['routealias' => 'someroute', 'title' => 'Menu item 5'],
	]]);
	{!! Menu::get('admin') !!}

Change log

Please see CHANGELOG for more information what has changed recently.

Security

If you discover any security related issues, please email mail@morningtrain.dk instead of using the issue tracker.

Credits

License

GNU General Public License v3.0. Please see License File for more information.