<?php

namespace App\Policies;

use App\Models\User;
use Illuminate\Auth\Access\HandlesAuthorization;
use Spatie\Permission\Models\Role;

class PermissionsPolicy
{
    use HandlesAuthorization;

    /**
     * Create a new policy instance.
     *
     * @return void
     */
    public function __construct()
    {
        //
    }


    public function create(User $user){
        return false;
    }
    public function update(User $user){
        return false;
    }
    public function view(User $user){
        return $user->hasAnyPermission(['control roles and permissions']);
    }
    public function delete(User $user){
        return false;
    }
    public function viewAny(User $user){
        return $user->hasAnyPermission(['control roles and permissions']);
    }
}
