@php // Helper function to get test data value $getData = function($key, $default = '') use ($testResult) { if (!$testResult || !$testResult->test_data) return $default; return data_get($testResult->test_data, $key, $default); }; // Helper function to format date $formatDate = function($date) { if (!$date) return '-'; try { return \Carbon\Carbon::parse($date)->format('d/m/Y'); } catch (\Exception $e) { return '-'; } }; @endphp

Antenatal Blood Screening

Ujian Darah Saringan Antenatal

Keputusan Ujian Darah Saringan Antenatal

Your antenatal blood screening test results

@php $tests = [ ['key' => 'rhesus_blood_group', 'name' => 'Kumpulan darah Rhesus', 'icon' => 'tint'], ['key' => 'vdrl_tpha', 'name' => 'VDRL +/- TPHA', 'icon' => 'microscope'], ['key' => 'syphilis_rapid_ibu', 'name' => 'Syphilis / Rapid Test (Ibu)', 'icon' => 'virus'], ['key' => 'syphilis_rapid_pasangan', 'name' => 'Syphilis / Rapid Test (Pasangan)', 'icon' => 'user-friends'], ['key' => 'hiv_rapid_ibu', 'name' => 'HIV / Rapid Test (Ibu)', 'icon' => 'shield-virus'], ['key' => 'hiv_rapid_pasangan', 'name' => 'HIV / Rapid Test (Pasangan)', 'icon' => 'user-friends'], ['key' => 'hepatitis_b', 'name' => 'Hepatitis B', 'icon' => 'disease'], ['key' => 'malaria_bfmp', 'name' => 'Malaria (BFMP)', 'icon' => 'bug'], ]; @endphp @foreach($tests as $index => $test) @endforeach
Bil. Jenis Ujian Test I Test II
Tarikh Keputusan Tarikh Keputusan
{{ $index + 1 }} {{ $test['name'] }} {{ $formatDate($getData($test['key'] . '.taken_at_1')) }} {{ $getData($test['key'] . '.result_1') ?: '-' }} {{ $formatDate($getData($test['key'] . '.taken_at_2')) }} {{ $getData($test['key'] . '.result_2') ?: '-' }}
Back to Health Record