2017-11-03 05:26:07 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Providers;
|
|
|
|
|
2018-06-05 11:13:57 +00:00
|
|
|
use Laravel\Passport\Passport;
|
2017-11-03 05:26:07 +00:00
|
|
|
use Illuminate\Support\Facades\Gate;
|
|
|
|
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
|
|
|
|
|
|
|
|
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();
|
2018-06-05 11:13:57 +00:00
|
|
|
Passport::routes();
|
|
|
|
// Passport::enableImplicitGrant();
|
2017-11-03 05:26:07 +00:00
|
|
|
}
|
|
|
|
}
|