@php
$topFields = [
'passport_file' => ['label' => 'جواز السفر', 'icon' => '🪪', 'prop' => 'uploadedPassport'],
'certificate_file' => ['label' => 'الشهادة الدراسية', 'icon' => '🎓', 'prop' => 'uploadedCertificate'],
'personal_photo_file' => ['label' => 'الصورة الشخصية', 'icon' => '📸', 'prop' => 'uploadedPersonalPhoto'],
];
$bottomFields = [
'preliminary_acceptance_file' => ['label' => 'القبول المبدئي', 'icon' => '📄', 'prop' => 'uploadedPreliminary'],
'payment_receipt_file' => ['label' => 'إيصال الدفع', 'icon' => '🧾', 'prop' => 'uploadedPaymentReceipt'],
'final_acceptance_file' => ['label' => 'القبول النهائي', 'icon' => '✅', 'prop' => 'uploadedFinal'],
];
@endphp
@foreach ($topFields as $field => $info)
@php $prop = $info['prop']; $selectedName = $fileNames[$field] ?? null; @endphp
{{ $info['icon'] }}
{{ $info['label'] }}
@if ($selectedApp->$field)
👁 معاينة
⬇ تحميل
@else
غير مرفوع
@endif
@endforeach
@foreach ($bottomFields as $field => $info)
@php $prop = $info['prop']; $selectedName = $fileNames[$field] ?? null; @endphp
{{ $info['icon'] }}
{{ $info['label'] }}
@if ($selectedApp->$field)
👁 معاينة
⬇ تحميل
@else
غير مرفوع
@endif
@endforeach
{{-- Additional Attachments --}}
@php $hasAnyFile = $selectedApp->passport_file || $selectedApp->certificate_file || $selectedApp->personal_photo_file || $selectedApp->preliminary_acceptance_file || $selectedApp->payment_receipt_file || $selectedApp->final_acceptance_file; @endphp
@if ($hasAnyFile && $selectedApp->lead_id)