INVOICE

{{ config('app.name', 'Embroidery Business') }}

Invoice Number: {{ $invoice->invoice_number }}
Date: {{ $invoice->invoice_date->format('M d, Y') }}
Due Date: {{ $invoice->due_date ? $invoice->due_date->format('M d, Y') : 'N/A' }}
Status: {{ ucfirst($invoice->status) }}
@if($invoice->order) Order Number: {{ $invoice->order->order_number }}
Order Date: {{ $invoice->order->created_at->format('M d, Y') }} @endif

Bill To:

{{ $invoice->customer_name }}
{{ $invoice->customer_email }}
@if($invoice->billing_company) {{ $invoice->billing_company }}
@endif @if($invoice->billing_address) {!! nl2br(e($invoice->billing_address)) !!} @endif

Items:

@php $lineItems = $invoice->line_items ?? []; @endphp @forelse($lineItems as $item) @empty @endforelse
Description Quantity Price Total
{{ $item['description'] ?? 'N/A' }} {{ $item['quantity'] ?? 0 }} ${{ number_format($item['price'] ?? 0, 2) }} ${{ number_format(($item['quantity'] ?? 0) * ($item['price'] ?? 0), 2) }}
No items found
Subtotal: ${{ number_format($invoice->subtotal, 2) }}
Tax: ${{ number_format($invoice->tax_amount, 2) }}
Total: ${{ number_format($invoice->total_amount, 2) }}
@if($invoice->notes)

Notes:

{{ $invoice->notes }}

@endif
Generated on {{ now()->format('M d, Y \a\t g:i A') }}