<?php

namespace App\Policies;

use App\Models\Admin;
use Illuminate\Auth\Access\HandlesAuthorization;

class ReportsPolicy
{
    use HandlesAuthorization;

    /**
     * Determine whether the admin can view any reports.
     */
    public function viewAny(Admin $admin): bool
    {
        return $admin->hasPermissionTo('view reports');
    }

    /**
     * Determine whether the admin can view reports.
     */
    public function view(Admin $admin): bool
    {
        return $admin->hasPermissionTo('view reports');
    }

    /**
     * Determine whether the admin can generate reports.
     */
    public function generate(Admin $admin): bool
    {
        return $admin->hasPermissionTo('generate reports');
    }

    /**
     * Determine whether the admin can export reports.
     */
    public function export(Admin $admin): bool
    {
        return $admin->hasPermissionTo('export reports');
    }
}
