@extends('layouts.app') @section('title', $party->business_name ?? $party->name) @section('page_title', 'Party Overview & Transaction History') @section('content')
Back to Parties

{{ $party->business_name ?? $party->name }}

Role: {{ ucfirst($party->type) }} | State: {{ $party->state }} ({{ $party->state_code }})
Current Balance

₹{{ number_format($party->current_balance, 2) }}

{{ $party->current_balance > 0 ? 'Outstanding Due' : 'Settled' }}
GSTIN
{{ $party->gstin ?? 'Unregistered B2C' }}
PAN: {{ $party->pan ?? 'N/A' }}
Contact
{{ $party->phone ?? '-' }}
{{ $party->email ?? '-' }}
Billing Address
{{ $party->billing_address ?? 'No address provided' }}
@if($party->type == 'customer' || $party->type == 'both')
Sales Invoices
+ New Invoice
@forelse($party->invoices as $inv) @empty @endforelse
Invoice # Date Amount Status
{{ $inv->invoice_number }} {{ $inv->invoice_date->format('d M Y') }} ₹{{ number_format($inv->grand_total, 2) }} {{ ucfirst($inv->payment_status) }}
No sales invoices yet.
@endif @if($party->type == 'supplier' || $party->type == 'both')
Purchase Bills
+ New Bill
@forelse($party->purchases as $pur) @empty @endforelse
Bill # Date Amount Status
{{ $pur->purchase_number }} {{ $pur->purchase_date->format('d M Y') }} ₹{{ number_format($pur->grand_total, 2) }} {{ ucfirst($pur->payment_status) }}
No purchase bills yet.
@endif
@endsection