<?php

namespace App\Policies;

use App\Models\LaundrySaleCategory;
use App\Models\User;

class LaundrySaleCategoryPolicy
{
    public function viewAny(User $user): bool
    {
        return $user->hasRole('Administrador') && $user->can('administracion.areas');
    }

    public function create(User $user): bool
    {
        return $user->hasRole('Administrador') && $user->can('administracion.areas');
    }

    public function update(User $user, LaundrySaleCategory $laundrySaleCategory): bool
    {
        return $user->hasRole('Administrador') && $user->can('administracion.areas');
    }

    public function delete(User $user, LaundrySaleCategory $laundrySaleCategory): bool
    {
        return $user->hasRole('Administrador') && $user->can('administracion.areas');
    }
}
