@extends('print.layout') @section('title', 'Purchase_Ledger_' . ($dfrom ?? 'All') . '_to_' . ($dto ?? 'Current')) @section('content')
| Sr. | Date | Reference | Description | Debit | Credit | Balance |
|---|---|---|---|---|---|---|
| {{ $index++ }} | {{ $dfrom ?? 'Start' }} | - | Opening Balance | {{ $oBalance > 0 ? number_format($oBalance, 2) : '-' }} | {{ $oBalance < 0 ? number_format(abs($oBalance), 2) : '-' }} | {{ number_format($runningBalance, 2) }} |
| {{ $index++ }} | {{ isset($transaction->purchase_date) ? $transaction->purchase_date : (isset($transaction->return_date) ? $transaction->return_date : ($transaction->transaction_date ?? 'N/A')) }} | {{ $refNo }} | {{ strip_tags($description) }} | {{ $debit > 0 ? number_format($debit, 2) : '-' }} | {{ $credit > 0 ? number_format($credit, 2) : '-' }} | {{ number_format($runningBalance, 2) }} |
| Total: | {{ number_format($totalDebit, 2) }} | {{ number_format($totalCredit, 2) }} | {{ number_format($runningBalance, 2) }} | |||
No purchase ledger records found for the selected period.