<?php

namespace App\Policies;

use App\Models\EmailTemplate;
use App\Models\User;

class EmailTemplatePolicy
{
    public function viewAny(User $user): bool
    {
        return $user->can('email.view');
    }

    public function view(User $user, EmailTemplate $template): bool
    {
        return $user->can('email.view');
    }

    public function create(User $user): bool
    {
        return $user->can('email.create');
    }

    public function update(User $user, EmailTemplate $template): bool
    {
        return $user->can('email.update');
    }

    public function delete(User $user, EmailTemplate $template): bool
    {
        return $user->can('email.delete');
    }
}
