<?php

namespace App\Http\Resources\Admin;

use Illuminate\Http\Request;
use Illuminate\Http\Resources\Json\JsonResource;

class AdminNotificationAlertsResource extends JsonResource
{
    public function toArray(Request $request): array
    {
        return [
            'admins' => $this['admins'] ?? [],
            'subjects' => $this['subjects'] ?? [],
            'assigned_subjects' => $this['assigned_subjects'] ?? [],
            'table_ready' => (bool) ($this['table_ready'] ?? false),
        ];
    }
}