@extends('layouts.app') @section('content')

Journal Voucher - {{ $voucher->voucher_no }}

Print Back
{{ $voucher->voucher_no }}
{{ $voucher->date->format('d-M-Y') }}
Rs. {{ number_format($voucher->amount, 2) }}
{{ $voucher->type }} VOUCHER
@if($voucher->narration)
{{ $voucher->narration }}
@endif

Journal Entries

@foreach($voucher->entries->where('debit', '>', 0) as $entry) @endforeach @foreach($voucher->entries->where('credit', '>', 0) as $entry) @endforeach
Account Code Debit Credit
{{ $entry->account->name }} {{ $entry->account->code }} Rs. {{ number_format($entry->debit, 2) }} -
    To: {{ $entry->account->name }} {{ $entry->account->code }} - Rs. {{ number_format($entry->credit, 2) }}
Total: Rs. {{ number_format($voucher->entries->sum('debit'), 2) }} Rs. {{ number_format($voucher->entries->sum('credit'), 2) }}
Created by: {{ $voucher->user->name ?? 'System' }} | {{ $voucher->created_at->format('d-M-Y h:i A') }}
Print Voucher
@csrf @method('DELETE')
New Journal Voucher
@endsection