@foreach ($invoices as $invoice) @foreach ($invoice->ancillaryCosts as $ancillaryCost) @endforeach @endforeach
{{ __('Type') }} {{ __('Invoice Number') }} {{ __('Customer') }} {{ __('Date') }} {{ __('Price') }}
{{ __('Invoice') }} {{ $invoice->invoice_type->label() }} {{ formatDocumentNumber($invoice->number) }} {{ $invoice->customer->name }} {{ $invoice->date ? formatDate($invoice->date) : '' }} {{ formatNumber($invoice->amount - $invoice->subtraction) }}
{{ $ancillaryCost->type->label() }} {{ formatDocumentNumber($ancillaryCost->invoice->number) }} {{ $ancillaryCost->customer->name ?? '' }} {{ $ancillaryCost->date ? formatDate($ancillaryCost->date) : '' }} {{ formatNumber($ancillaryCost->amount - $ancillaryCost->subtraction) }}
{{-- TODO: No need to show the Invoice of ancillary costs those their status are not approved inactive --}} @if ($invoices->hasPages())
{{ $invoices->withQueryString()->links() }}
@endif