<?php $__env->startSection('page-title', 'Transaction Details'); ?>

<?php $__env->startSection('content'); ?>
<div class="container-fluid">
    <div class="row mb-4">
        <div class="col-md-12">
            <a href="<?php echo e(route('transactions.index')); ?>" class="btn btn-secondary">
                <i class="fas fa-arrow-left"></i> Back to Transactions
            </a>
        </div>
    </div>

    <div class="row">
        <div class="col-md-6 offset-md-3">
            <div class="card">
                <div class="card-header">
                    <h5>Transaction Details</h5>
                </div>
                <div class="card-body">
                    <table class="table table-borderless">
                        <tr>
                            <th>Date:</th>
                            <td><?php echo e($transaction->date->format('M d, Y')); ?></td>
                        </tr>
                        <tr>
                            <th>Type:</th>
                            <td>
                                <span class="badge bg-<?php echo e($transaction->type == 'income' ? 'success' : 'danger'); ?>">
                                    <?php echo e(ucfirst($transaction->type)); ?>

                                </span>
                            </td>
                        </tr>
                        <tr>
                            <th>Amount:</th>
                            <td><?php echo e(number_format($transaction->amount, 2)); ?></td>
                        </tr>
                        <tr>
                            <th>Payment Method:</th>
                            <td><?php echo e(ucfirst($transaction->payment_method)); ?></td>
                        </tr>
                        <?php if($transaction->bankAccount): ?>
                        <tr>
                            <th>Bank Account:</th>
                            <td><?php echo e($transaction->bankAccount->bank_name); ?> - <?php echo e($transaction->bankAccount->account_name); ?></td>
                        </tr>
                        <?php endif; ?>
                        <?php if($transaction->digitalPayment): ?>
                        <tr>
                            <th>Digital Payment:</th>
                            <td><?php echo e($transaction->digitalPayment->provider); ?></td>
                        </tr>
                        <?php endif; ?>
                        <?php if($transaction->expenseType): ?>
                        <tr>
                            <th>Expense Type:</th>
                            <td><?php echo e($transaction->expenseType->name); ?></td>
                        </tr>
                        <?php endif; ?>
                        <tr>
                            <th>Balance Before:</th>
                            <td><?php echo e(number_format($transaction->balance_before, 2)); ?></td>
                        </tr>
                        <tr>
                            <th>Balance After:</th>
                            <td><?php echo e(number_format($transaction->balance_after, 2)); ?></td>
                        </tr>
                        <tr>
                            <th>Details:</th>
                            <td><?php echo e($transaction->details ?? '-'); ?></td>
                        </tr>
                        <tr>
                            <th>Reference:</th>
                            <td><?php echo e($transaction->reference ?? '-'); ?></td>
                        </tr>
                        <tr>
                            <th>Notes:</th>
                            <td><?php echo e($transaction->notes ?? '-'); ?></td>
                        </tr>
                    </table>
                </div>
            </div>
        </div>
    </div>
</div>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('layouts.app', array_diff_key(get_defined_vars(), ['__data' => 1, '__path' => 1]))->render(); ?><?php /**PATH C:\Users\startup sabbir\Desktop\jannat\sarvice-accounts\accounting-system\resources\views/transactions/show.blade.php ENDPATH**/ ?>