<?php $__env->startSection('title', __('Chart of Accounts')); ?>
<?php $__env->startSection('content'); ?>
<div class="card">
    <div class="card-body p-4">
        <?php echo $__env->make('reports.partials.header', ['title' => __('Chart of Accounts'), 'period' => __('As of').' '.\App\Support\DualDate::format(now(), 'Y-m-d')], array_diff_key(get_defined_vars(), ['__data' => 1, '__path' => 1]))->render(); ?>
        <div class="text-end mb-3 no-print"><button onclick="window.print()" class="btn btn-light btn-sm"><i class="fa-solid fa-print me-1"></i><?php echo e(__('Print')); ?></button></div>
        <div class="table-responsive">
            <table class="table align-middle">
                <thead><tr><th><?php echo e(__('Group')); ?></th><th><?php echo e(__('Account Name')); ?></th><th><?php echo e(__('Type')); ?></th><th class="text-end"><?php echo e(__('Debit')); ?></th><th class="text-end"><?php echo e(__('Credit')); ?></th></tr></thead>
                <tbody>
                    <?php $__currentLoopData = $accounts; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $account): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                        <tr><td><?php echo e($account['group']); ?></td><td><?php echo e($account['name']); ?></td><td><?php echo e($account['type']); ?></td><td class="text-end money"><?php echo e($account['debit'] ? number_format($account['debit'], 2).' '.$moneyCode : '-'); ?></td><td class="text-end money"><?php echo e($account['credit'] ? number_format($account['credit'], 2).' '.$moneyCode : '-'); ?></td></tr>
                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                </tbody>
                <tfoot><tr><th colspan="3"><?php echo e(__('Total')); ?></th><th class="text-end money"><?php echo e(number_format($accounts->sum('debit'), 2)); ?> <?php echo e($moneyCode); ?></th><th class="text-end money"><?php echo e(number_format($accounts->sum('credit'), 2)); ?> <?php echo e($moneyCode); ?></th></tr></tfoot>
            </table>
        </div>
    </div>
</div>
<?php if(!empty($appSettings['report_footer'])): ?><p class="text-center text-muted small mt-3"><?php echo e($appSettings['report_footer']); ?></p><?php endif; ?>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('layouts.app', array_diff_key(get_defined_vars(), ['__data' => 1, '__path' => 1]))->render(); ?><?php /**PATH C:\xampp\htdocs\TradeERP\resources\views/reports/chart-of-accounts.blade.php ENDPATH**/ ?>