@extends('layouts.main_dashboard.app') @section('title', app()->getLocale() === 'ar' ? 'إدارة العيادة' : 'Clinic Management') @section('skip_page_hero', true) @php $isArabic = app()->getLocale() === 'ar'; @endphp @section('content')

{{ $isArabic ? 'الزيارات والإعفاءات والإجازات المرضية' : 'Visits, Exemptions & Sick Leaves' }}

{{ $isArabic ? 'سجل زيارات العيادة' : 'Clinic visit log' }}

@foreach($visits as $visit)
{{ $visit->student?->name }}
{{ $visit->checked_in_at?->format('Y-m-d h:i A') }}{{ $visit->checked_out_at ? ' → ' . $visit->checked_out_at->format('h:i A') : '' }}
{{ $visit->symptoms }}
@if($visit->treatment_provided)
{{ $isArabic ? 'العلاج:' : 'Treatment:' }} {{ $visit->treatment_provided }}
@endif
{{ $visit->disposition }} @if(!$visit->checked_out_at)
@csrf @method('PATCH')
@endif
@endforeach @if($visits->isEmpty())
{{ $isArabic ? 'لا توجد زيارات مسجلة.' : 'No clinic visits logged.' }}
@endif
{{ $visits->links() }}
@csrf

{{ $isArabic ? 'زيارة جديدة' : 'New visit' }}

{{ $isArabic ? 'الإعفاءات الطبية' : 'Medical exemptions' }}

@csrf
@foreach($exemptions as $exemption)
{{ $exemption->student?->name }}
{{ $exemption->exemption_type }} • {{ $exemption->starts_on?->format('Y-m-d') }} - {{ $exemption->ends_on?->format('Y-m-d') }}
{{ $isArabic ? 'الإدارة:' : 'Admin:' }} {{ $exemption->administration_status }}
@endforeach
{{ $exemptions->links() }}

{{ $isArabic ? 'الإجازات المرضية' : 'Sick leaves' }}

@csrf
@foreach($sickLeaves as $leave)
{{ $leave->student?->name }}
{{ $leave->start_date?->format('Y-m-d') }} - {{ $leave->end_date?->format('Y-m-d') }}
{{ $isArabic ? 'الإدارة:' : 'Admin:' }} {{ $leave->administration_status }}
@endforeach
{{ $sickLeaves->links() }}
@endsection