PHP code example of osi / airs
1. Go to this page and download the library: Download osi/airs 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/ */
osi / airs example snippets
return [
'guards' => [
// laravel-permission 相对应的 guard
'admin' => [
'model' => \Osi\Airs\Models\AdminUser::class, //登录鉴权的模型
'login_fields' => [ // 登录验证的字段,支持多个
'username',
],
'conditions' => [ // 登录验证的额外条件
['status', '=', 1]
]
]
]
];
php artisan airs:install
php artisan migrate
php artisan db:seed --class="Osi\Airs\Database\AirsTableSeeder"