<table class="w-full border-collapse border border-gray-300 text-sm">
    <thead class="bg-gray-100 dark:bg-gray-800">
        <tr>
            <th class="border">#</th>
            <th class="border">Date</th>
            <th class="border">Title</th>
            <th class="border">Debit (gm)</th>
            <th class="border">Credit (gm)</th>
            <th class="border">Balance (gm)</th>
        </tr>
    </thead>
    <tbody>

        <?php $__currentLoopData = $results; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $row): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
            <tr>
                <td class="border"><?php echo e($row['no'] + 2); ?></td>
                <td class="border"><?php echo e($row['date']); ?></td>
                <td class="border"><?php echo e($row['title']); ?></td>
                <td class="border "><?php echo e($row['debit']); ?></td>
                <td class="border "><?php echo e($row['credit']); ?></td>
                <td class="border "><?php echo e($row['balance']); ?></td>
            </tr>
        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
    </tbody>
    <tfoot class="bg-gray-100 dark:bg-gray-800">
        <tr>
            <td colspan="3" class="">Total</td>
            <td class="">
                <?php echo e(number_format($results->sum(fn($r) => (float) $r['debit']), 2)); ?>

            </td>
            <td class="">
                <?php echo e(number_format($results->sum(fn($r) => (float) $r['credit']), 2)); ?>

            </td>
            <td></td>
        </tr>
    </tfoot>

</table>
<?php /**PATH D:\wamp\www\LaravelPHP\GoldPlus\resources\views\ReportElems\item-ledger-table.blade.php ENDPATH**/ ?>