PHP code example of winex01 / backpack-menu

1. Go to this page and download the library: Download winex01/backpack-menu library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

winex01 / backpack-menu example snippets


//RolesAndPermissionsSeeder.php
protected $rolesAndPermissions = [
    // more arrays here...

    'menus' => [
        'menus_list',
        'menus_create',
        'menus_show',
        'menus_update',
        'menus_delete',
        'menus_reorder',
    ],
];

//menu_items.blade.php
@

php artisan vendor:publish --provider="Winex01\BackpackMenu\BackpackMenuServiceProvider" --tag="migrations"

// dont forget to run migrate after

php artisan vendor:publish --provider="Winex01\BackpackMenu\BackpackMenuServiceProvider" --tag="seeders"

php artisan db:seed --class=MenusTableSeeder.php

// or you can add it to default seeder file, DatabaseSeeder.php