@php $config = config('audit.letter'); $malay = fn ($date) => $date?->locale('ms')->translatedFormat('d F Y'); $issuedOn = $report->approved_at ?? $report->updated_at ?? $report->created_at; @endphp {{-- Full-bleed letterhead: page 1 only, matching the official stationery. --}} {!! $letterheadTop !!}
@if ($hasAuthoredLetter) {{-- Rendered whole and untouched. The letter authored in "Kandungan Surat" already carries its own reference block, signature, QR and footnote, so adding any of those here would duplicate them. --}}
{!! $letterBody !!}
@else {{-- Fallback for a report whose cover letter has not been written yet. --}}
No. Laporan  : {{ $report->reference_number }}
Tarikh  : {{ $malay($issuedOn) }}

KEPADA SESIAPA YANG BERKENAAN

YBhg. Dato’ / Datin / Prof. / Dr. / Tuan / Puan,

{{ \App\Support\Text::upper($report->letter_title ?: $report->title) }} BAGI BULAN {{ \App\Support\Text::upper($report->periodLabel()) }}

Dengan segala hormatnya perkara di atas adalah dirujuk.

2.    Sukacita dikemukakan {{ $report->title }} bagi Bulan {{ $report->periodLabel() }} untuk makluman dan rujukan pihak tuan/puan. Laporan penuh boleh diakses di pautan: {{ $publicUrl }}

3.    Semua dapatan dalam laporan ini adalah hak milik eksklusif {{ $config['issuing_office'] }}. Sebarang pertanyaan lanjut berhubung laporan ini boleh dikemukakan kepada {{ $config['support_contact']['name'] }}, {{ $config['support_contact']['post'] }} atau e-mel {{ $config['support_contact']['email'] }}. Perhatian dan sokongan berterusan daripada pihak tuan/puan amatlah dihargai.

Sekian, terima kasih.

{!! implode('
', $config['slogans']) !!}

Yang benar,

{{ \App\Support\Text::upper($report->creator->displayName()) }}
{{ $report->creator->user_post ?: $config['default_signatory_post'] }}

Dokumen ini adalah janaan komputer. Tiada tanda tangan fizikal diperlukan. Imbas Kod QR untuk pengesahan.

@endif {{-- Closing band sits directly beneath the page 1 content, also full bleed. --}}
{!! $letterheadBottom !!}