wmenu-builder
wmenu-builder copied to clipboard
How to use menu builder
I am trying to bring up the menu builder. Can you please provide some steps in how to.
I looked at @extends('app')
@section('contents') {!! Menu::render() !!} @endsection
//YOU MUST HAVE JQUERY LOADED BEFORE menu scripts @push('scripts') {!! Menu::scripts() !!} @endpush
I am not sure what route to use, what to call etc
basically you don't need to setup any routes, it's configured inside the package but you can still set custom path and middleware inside config/menu.php you can just put {!! Menu::render() !!} and {!! Menu::scripts() !!} inside your blade.php file.
don't forget to put jquery above the Menu::scripts() for example
<!doctype html>
<html>
<head>
//your header script here
</head>
<body>
{!! Menu::render() !!}
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.2.4/jquery.min.js"></script>
{!! Menu::scripts() !!}
</body>
</html>
Thanks for that - worked perfectly. Is it possible to extend this to add Roles to a menu item?
Hi I figured out the roles by enabling the following app.php 'use_roles' => true,
But had issues as it cannot find roles tables. So I had to create my own roles table.
However allocating a role to a menu and trying to save, how does it allocate a menu to a role - there is no DB structure for it.
You should put this guide on home document, I lost 2 hours to config but it can not working until I read this issue.