@foreach($tables as $index => $table)
{{ $table['title'] }}
@foreach($table['columns'] as $column) @endforeach @forelse($table['rows'] as $row) @foreach($table['columns'] as $column) @endforeach @empty @endforelse @if(!empty($table['totals']) && !empty($table['rows'])) @foreach($table['columns'] as $column) @endforeach @endif
{{ $column['label'] }}
@if($column['type'] === 'currency') ${{ number_format($row[$column['id']] ?? 0, 2) }} @elseif($column['type'] === 'number') {{ number_format($row[$column['id']] ?? 0) }} @elseif($column['type'] === 'percentage') {{ number_format($row[$column['id']] ?? 0, 2) }}% @else {{ $row[$column['id']] ?? '' }} @endif
No data found for this report
@if($column['type'] === 'currency') ${{ number_format($table['totals'][$column['id']] ?? 0, 2) }} @elseif($column['type'] === 'number') {{ number_format($table['totals'][$column['id']] ?? 0) }} @elseif($column['type'] === 'percentage') {{ number_format($table['totals'][$column['id']] ?? 0, 2) }}% @else {{ $table['totals'][$column['id']] ?? '' }} @endif
@endforeach