LaravelRUS / SleepingOwlAdmin

🦉 Administrative interface builder for Laravel (Laravel admin)
http://sleepingowladmin.ru/
MIT License
805 stars 217 forks source link

navigation.php and single pages (without a model) #37

Closed denistorresan closed 8 years ago

denistorresan commented 8 years ago

Hello, in the previous version (v3) there was the configuration for manage static navigation menu, I mean adding for example Dashboard link to menu or a static page (with a static controller) in this way:

Admin::menu()->url('/')->label('Dashboard')->icon('fa-dashboard');

Admin::menu(\App\Models\Customer::class)->icon('fa-user')->label('Customers');

Admin::menu()->url('/stats')->label('Stats')->icon('fa-trello');

There's a way to manage it with the new configuration using navigation.php? I only see that you can manage groups of pages, but not single page, eg:

    [
        'title' => 'Permissions',
        'icon' => 'fa fa-group',
        'pages' => [
            (new Page(\App\User::class))
                ->setIcon('fa fa-user')
                ->setPriority(0),
            (new Page(\App\Role::class))
                ->setIcon('fa fa-group')
                ->setPriority(100)
        ]
    ]

but, something like this is not working:

    [
        'title' => 'Permissions',
        'icon' => 'fa fa-group',
        'pages' =>
            (new Page(null))
                ->setIcon('fa fa-user')
                ->setPriority(0),
               -->setUrl("/stats")
    ]

Any suggestion? bye!

butschster commented 8 years ago

https://github.com/LaravelRUS/SleepingOwlAdmin-docs/blob/master/menu_configuration.md

denistorresan commented 8 years ago

Oh sorry! Now I see where the docs is placed... :D thanks!

butschster commented 8 years ago

Questions?