staffmanager/app/Providers/AuthServiceProvider.php

38 lines
859 B
PHP
Raw Normal View History

2020-04-26 04:09:32 +00:00
<?php
namespace App\Providers;
use App\Http\Controllers\ProfileController;
use App\Policies\ProfilePolicy;
use App\Policies\UserPolicy;
use App\User;
2020-04-26 04:09:32 +00:00
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
use Illuminate\Support\Facades\Gate;
class AuthServiceProvider extends ServiceProvider
{
/**
* The policy mappings for the application.
*
* @var array
*/
protected $policies = [
// 'App\Model' => 'App\Policies\ModelPolicy',
'App\Application' => 'App\Policies\ApplicationPolicy',
ProfileController::class => ProfilePolicy::class,
User::class => UserPolicy::class
2020-04-26 04:09:32 +00:00
];
/**
* Register any authentication / authorization services.
*
* @return void
*/
public function boot()
{
$this->registerPolicies();
//
}
}