@php // Reusable print/report template — Bangladeshi traditional style. // Variables (all optional): // $orientation : 'portrait' | 'landscape' (default portrait) // $paper : 'A4' | 'Letter' ... (default A4) // $compact : bool (default true) // $organization : organization model (default current_organization()) // $signatures : array of signature labels (default 3 standard ones) $orientation = in_array($orientation ?? 'portrait', ['portrait', 'landscape']) ? ($orientation ?? 'portrait') : 'portrait'; $paper = $paper ?? 'A4'; $compact = $compact ?? true; $organization = $organization ?? (function_exists('current_organization') ? current_organization() : null); $signatures = $signatures ?? [_lang('Prepared By'), _lang('Checked By'), _lang('Authorised Signature')]; // For screen preview only — A4 dimensions per orientation. $sheetW = $orientation === 'landscape' ? '297mm' : '210mm'; // Toggle URL (flips orientation, keeps other query params). $flip = $orientation === 'landscape' ? 'portrait' : 'landscape'; $flipUrl = request()->fullUrlWithQuery(['orientation' => $flip]); @endphp
@include('partials.fonts')