@extends('layouts.app') @section('title', $invoice->invoice_no) @php $statusBadge = [ 'pending' => 'bg-warning-transparent', 'partial' => 'bg-info-transparent', 'paid' => 'bg-success-transparent', 'overdue' => 'bg-danger-transparent', 'waived' => 'bg-secondary-transparent', 'cancelled' => 'bg-secondary-transparent', ]; $subBadge = [ 'active' => 'bg-success-transparent', 'grace' => 'bg-warning-transparent', 'restricted' => 'bg-danger-transparent', 'suspended' => 'bg-dark-transparent', 'cancelled' => 'bg-secondary-transparent', ]; $sub = $invoice->subscription; $outstanding = max(0, $invoice->total_amount - $invoice->paid_amount); @endphp @section('content')
@include('partials.alerts')| {{ _lang('Plan') }} | {{ $invoice->plan_name }} ({{ _lang('up to') }} {{ $invoice->max_members }}) |
| {{ _lang('Peak members in cycle') }} | {{ $invoice->peak_members }} @if($invoice->over_limit){{ _lang('Over limit') }}@endif |
| {{ _lang('Interval') }} | {{ ucfirst($invoice->billing_interval) }} |
| {{ _lang('Base amount') }} | ৳{{ number_format($invoice->base_amount / 100) }} |
| {{ _lang('Discount') }} | − ৳{{ number_format($invoice->discount_amount / 100) }} |
| {{ _lang('Waived') }} | − ৳{{ number_format($invoice->waived_amount / 100) }} |
| {{ _lang('Total') }} | ৳{{ number_format($invoice->total_amount / 100) }} |
| {{ _lang('Paid') }} | ৳{{ number_format($invoice->paid_amount / 100) }} |
| {{ _lang('Outstanding') }} | ৳{{ number_format($outstanding / 100) }} |
| {{ _lang('Issued') }} | {{ optional($invoice->issued_on)->format('d M Y') }} |
| {{ _lang('Due') }} | {{ optional($invoice->due_on)->format('d M Y') }} |
| {{ _lang('Date') }} | {{ _lang('Method') }} | {{ _lang('Amount') }} | {{ _lang('Status') }} | {{ _lang('Trx') }} |
|---|---|---|---|---|
| {{ optional($p->created_at)->format('d M Y, h:i A') }} | {{ ucfirst($p->method) }} | ৳{{ number_format($p->amount / 100) }} | {{ ucfirst($p->status) }} | {{ $p->gateway_trx_id ?? '—' }} |
| {{ _lang('No payments yet.') }} | ||||
{{ _lang('Interval') }}: {{ ucfirst($sub->billing_interval) }} • {{ _lang('Next invoice') }}: {{ optional($sub->current_period_end)->format('d M Y') }}
{{-- Standing discount for this business (auto-applies to future invoices) --}}