Installing Laravel ACL
Laravel ACL can be installed with Composer. More details about this package in Composer can be found here.
Run the following command in your project to get the latest version of the package:
composer require yajra/laravel-acl:^6.1
Open the file
config/app.php and then add following service provider.
'providers' => [// ...Yajra\Acl\AclServiceProvider::class,],
Kernel.php file in
app\Http\Kernel.php and add this to used it as middleware :
'canAtLeast' => \Yajra\Acl\Middleware\CanAtLeastMiddleware::class,'permission' => \Yajra\Acl\Middleware\PermissionMiddleware::class,'role' => \Yajra\Acl\Middleware\RoleMiddleware::class,
Note: This step is (optional) for the publication of configuration files.
After completing the step above, use the following command to publish configuration settings:
php artisan vendor:publish --tag=laravel-acl
You'll need to run the provided migrations against your database:
php artisan migrate