@extends('layouts.app', ['title' => 'Invoices']) @section('content') @php($cur = $currentAccount->currency)

Invoices

GST invoices with CGST and SGST, or IGST for other states. Numbered in sequence.

@can('payments.manage') New invoice@endcan
Unpaid
{{ money_format_short($totals['outstanding'], $cur) }}
Paid this month
{{ money_format_short($totals['paid_month'], $cur) }}
Drafts
{{ $totals['drafts'] }}
@foreach (['' => 'All', 'draft' => 'Drafts', 'sent' => 'Unpaid', 'overdue' => 'Overdue', 'paid' => 'Paid', 'void' => 'Void'] as $k => $l) {{ $l }} @endforeach
@if ($invoices->isEmpty())
No invoices here.
@else
@foreach ($invoices as $inv) @endforeach
NumberCustomerIssuedDueTotalBalanceStatus
{{ $inv->number }} {{ $inv->billing_name }} {{ $inv->issue_date->format('d M Y') }} {{ $inv->due_date?->format('d M Y') ?? '—' }} {{ money_full($inv->total, $inv->currency) }} {{ in_array($inv->status, ['void', 'draft'], true) ? '—' : money_full($inv->balance(), $inv->currency) }} {{ $inv->displayStatus() }}
{{ $invoices->links() }}
@endif
@endsection