<?php

namespace App\Http\Requests\AttendanceTracking;

use App\Http\Requests\ApiFormRequest;

class RecordAttendanceTrackingRequest extends ApiFormRequest
{
    public function authorize(): bool
    {
        return true;
    }

    public function rules(): array
    {
        return [
            'student_id'   => ['required', 'integer', 'min:1'],
            'date'         => ['required', 'date_format:Y-m-d'],
            'parent_email' => ['nullable', 'email'],
            'parent_name'  => ['nullable', 'string'],
            'subject_type' => ['nullable', 'string'],
            'semester'     => ['nullable', 'string'],
            'school_year'  => ['nullable', 'string'],
        ];
    }
}
