@if (!isset($student))
@endif
@php
$customLabels = [
'avatar' => 'Foto',
'identity_card' => 'NISN',
'family_card' => 'KK',
'certificate' => 'Sertifikat',
'transcript' => 'Rapot',
'ex_certificate' => 'Halaman Rapot',
'born_card' => 'Akte Lahir',
'qr_code' => 'Bar Code',
];
@endphp
@foreach(['avatar', 'family_card', 'identity_card', 'ex_certificate', 'transcript', 'certificate', 'born_card', 'qr_code'] as $document)
@php
$documentName = isset($student) ? $student->{$document} : null;
$documentExtension = pathinfo($documentName, PATHINFO_EXTENSION);
@endphp
@endforeach