Tax Summary
{{ $filters['mode'] ?? 'monthly' }} • {{ $filters['year'] }}
Currency: {{ $filters['currency_id'] ?: 'All' }}
Source: texes table (amount * ex_rate for base)
Records
{{ (int)($totals['count'] ?? 0) }}
Total Amount
{{ $fmt($totals['amount'] ?? 0) }}
Total Base
{{ $fmt($totals['base'] ?? 0) }}
{{-- Filters --}}
Filters
Monthly or Annual
{{-- Summary Table --}}
Summary
Rows: {{ $rows->count() }}
| Period |
Currency |
Count |
Total Amount |
Total Base |
@forelse($rows as $r)
@php
$cur = $currencyLookup[$r['currency_id']] ?? null;
$curName = $cur->title_en ?? $cur->title_ps ?? ('CUR #'.$r['currency_id']);
@endphp
| {{ $r['period'] }} |
{{ $curName }} |
{{ $r['count'] }} |
{{ $fmt($r['total_amount']) }} |
{{ $fmt($r['total_base']) }} |
@empty
| No data found. |
@endforelse
@if($rows->count())
| Totals |
{{ (int)($totals['count']??0) }} |
{{ $fmt($totals['amount']??0) }} |
{{ $fmt($totals['base']??0) }} |
@endif
{{-- Detail List --}}
@if(($filters['detail']??0)==1)
Detail
{{ $detail->count() }} rows
| Date |
Title |
Currency |
Amount |
Ex Rate |
Base |
Status |
@forelse($detail as $d)
@php
$cur = $currencyLookup[$d->currency_id] ?? null;
$curName = $cur->title_en ?? $cur->title_ps ?? ('CUR #'.$d->currency_id);
$ex = (float)($d->ex_rate ?: 1);
$base = (float)$d->amount * $ex;
@endphp
| {{ $d->date }} |
{{ $d->title }} |
{{ $curName }} |
{{ $fmt($d->amount) }} |
{{ $fmt($ex) }} |
{{ $fmt($base) }} |
{{ $d->status }} |
@empty
| No detail rows. |
@endforelse
@endif
@endsection