Download the PHP package nanuc/laravel-admin without Composer
On this page you can find all versions of the php package nanuc/laravel-admin. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package laravel-admin
This package adds an admin panel to your app.
Installation
composer require nanuc/laravel-admin
Publish config
php artisan vendor:publish --provider="Nanuc\LaravelAdmin\LaravelAdminServiceProvider" --tag=config
This package assumes you want to access your admin panel at /admin
and have a route dashboard
(to return to from the admin panel). You can setup change this values in the config.
You can enable/disable modules in the modules
parameter. You can add own modules too - see "Customization".
Edit .env
Add the user accounts that are supposed to be admins to your .env.
[email protected],[email protected]
Impersonation
Add the trait Nanuc\LaravelAdmin\Traits\InteractsWithAdmin
to your User model.
Usage
Link to admin area
Place a link to the route admin.home
somewhere in your navigation. Make sure that only admins will see it.
If you use Jetstream you can use <x-admin::admin-link/>
and <x-admin::admin-link-responsive/>
in your dropdown navigation menus. Only admins will see it by default.
Impersonation information
Add <x-admin::impersonation/>
to the top of your layout to show information about who is being impersonated.
Blade views
You can use the @admin
directive in your blade views.
Customization
Custom Modules
You can create own modules that will appear in the navigation. You have to create a class that extends Nanuc\LaravelAdmin\Modules\AdminModule
. See how Nanuc\LaravelAdmin\Modules\Users\Users
is built and start from there.
Custom CSS/JS
To import your own CSS/JS go to your laravel-admin config.
'styles' => [
env('APP_URL').'/path/to/your/custom.css',
],
'scripts' => [
env('APP_URL').'/path/to/your/custom.js',
],
All versions of laravel-admin with dependencies
blade-ui-kit/blade-heroicons Version ^1.1
livewire/livewire Version ^2.3
lab404/laravel-impersonate Version ^1.7
rappasoft/laravel-livewire-tables Version ^1.15