{{-- Filters --}} {{ $this->form }} {{-- Report Header --}} @php $data = $this->balanceSheetData; @endphp Balance Sheet - As of {{ \Carbon\Carbon::parse($data['date'])->format('M d, Y') }} {{-- Balance Sheet Table --}}
@foreach($data['sections'] as $sectionIndex => $section) {{-- Section Header --}} {{-- Subsections --}} @foreach($section['subsections'] as $subsection) @php $hasAccounts = count($subsection['accounts']) > 0; $showSubsection = $hasAccounts || !isset($subsection['show_if_empty']) || $subsection['show_if_empty']; @endphp @if($showSubsection) {{-- Subsection Header --}} {{-- Accounts --}} @if($hasAccounts) @foreach($subsection['accounts'] as $account) @endforeach {{-- Subsection Total --}} @endif @endif @endforeach {{-- Section Total --}} @endforeach {{-- Grand Total --}}
Account Balance
{{ $section['title'] }}
{{ $subsection['title'] }}
{{ $account['code'] ? $account['code'] . ' - ' : '' }}{{ $account['name'] }} {{ number_format($account['balance'], 2) }}
{{ $subsection['total_label'] }} {{ number_format($subsection['total'], 2) }}
{{ $section['total_label'] }} {{ number_format($section['total'], 2) }}
{{ $data['grand_total_label'] }} {{ number_format($data['grand_total'], 2) }}