src folder refactoring

This commit is contained in:
Peter Papp
2021-07-18 14:43:50 +02:00
parent fc952d089b
commit 5046071f3a
134 changed files with 11976 additions and 42 deletions

View File

@@ -0,0 +1,34 @@
<?php
namespace App\Providers;
use Illuminate\Support\Facades\Gate;
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
//use Laravel\Passport\Passport;
class AuthServiceProvider extends ServiceProvider
{
/**
* The policy mappings for the application.
*
* @var array
*/
protected $policies = [
// 'App\Model' => 'App\Policies\ModelPolicy',
];
/**
* Register any authentication / authorization services.
*
* @return void
*/
public function boot()
{
$this->registerPolicies();
// Define admin maintenance gate
Gate::define('maintenance', function ($user) {
return $user->role === 'admin';
});
}
}