<?php

namespace App\Http\Resources\Attendance;

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

class LateSlipLogResource extends JsonResource
{
    public function toArray(Request $request): array
    {
        return [
            'id' => $this->resource->id ?? null,
            'school_year' => $this->resource->school_year ?? null,
            'semester' => $this->resource->semester ?? null,
            'student_name' => $this->resource->student_name ?? null,
            'slip_date' => $this->resource->slip_date ?? null,
            'time_in' => $this->resource->time_in ?? null,
            'grade' => $this->resource->grade ?? null,
            'reason' => $this->resource->reason ?? null,
            'admin_name' => $this->resource->admin_name ?? null,
            'printed_by' => $this->resource->printed_by ?? null,
            'printed_at' => $this->resource->printed_at ?? null,
            'created_at' => $this->resource->created_at ?? null,
            'updated_at' => $this->resource->updated_at ?? null,
        ];
    }
}
