PHP code example of patryk-sawicki / admin-gentelella
1. Go to this page and download the library: Download patryk-sawicki/admin-gentelella 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/ */
patryk-sawicki / admin-gentelella example snippets
`
php artisan lite:install
`
php artisan lite:admin
`
function __construct()
{
$this->middleware('auth:admin', ['except' => ['logout']]);
$this->middleware('role:Super Admin');
// multiple assingment roles per middleware
$this->middleware('role:Super Admin|Another Role|My Role');
}
// by permission in (for example) RolesController
function __construct()
{
$this->middleware('auth:admin', ['except' => ['logout']]);
$this->middleware('permission:role-read');
$this->middleware('permission:role-create', ['only' => ['create','store']]);
$this->middleware('permission:role-update', ['only' => ['edit','update']]);
$this->middleware('permission:role-delete', ['only' => ['destroy']]);
}
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.