PHP code example of cdebattista / laravel-permission
1. Go to this page and download the library: Download cdebattista/laravel-permission 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/ */
cdebattista / laravel-permission example snippets
$user->hasPermissions(['view_user', 'view_group', 'view_permission']);
Route::group(['permissions' => ['administrator', 'create_user', 'view_user', 'edit_user', 'delete_user']], function (){
Route::resource('users', Inertia\UserController::class)->except(['show']);
});