A Laravel package for advanced access list aplication
The aim of this library is to be as simple as possible. We won't mess with Laravel users, auth, session...
Just add in the part of code that you need to verify access, be it in the path, controller or view
You can install the package via composer:
composer require sefirosweb/laravel-access-list
Or manually add this to your composer.json:
composer.json
"sefirosweb/laravel-access-list": "*"
If you are using Laravel 5.5 and up, the service provider will automatically get registered.
For older versions of Laravel (<5.5), you have to add the service provider:
config/app.php
'providers' => [
...
Sefirosweb\LaravelAccessList\LaravelAccessListServiceProvider::class,
]
Install database migrations
php artisan migrate
Publish frontend:
php artisan vendor:publish --provider="Sefirosweb\LaravelAccessList\LaravelAccessListServiceProvider" --tag=acl-assets --force
If you need edit prefix of tool or middleware you can publish the config:
php artisan vendor:publish --provider="Sefirosweb\LaravelAccessList\LaravelAccessListServiceProvider" --tag=config --force
Add in to routes of web.php or api.php
Route::group(['middleware' => ['checkAcl:foo_role_1']], function () {
return view('foo_View');
});
Add more ACLs for your application: http://your_app/acl/view/users
npm install
composer install
npm run watch
npm run prod
git tag X.X.X
git push --tag