<div class="content-wrapper">
    <div class="container-xxl flex-grow-1 container-p-y">
        <div class="card shadow">
            <div class="card-header text-uppercase custom-header bg-primary text-bg-info fw-bold">
                <i class="menu-icon ti ti-device-desktop-cog"></i> Collection Transfer
            </div>
            <div class="card-body">
                <table class="table table-striped" id="collectionTransferTable">
                    <thead>
                        <tr>
                            <th>#</th>
                            <th>Date</th>
                            <th>Deposit By</th>
                            <th>Amount</th>
                            <th>Slip No</th>
                            <th>Approved By</th>
                            <th>Approved Date</th>
                            <th>Bank</th>
                            <td>Status</td>
                            <th></th>
                        </tr>
                    </thead>
                    <tbody>
                        <?php
                            $count = 1;
                        ?>
                        <?php $__currentLoopData = $getCollectionTransferData; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $data): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                            <tr>
                                <td><?php echo e($count++); ?></td>
                                <td><?php echo e(\Carbon\Carbon::parse($data->created_at)->format('Y-m-d')); ?></td>
                                <td>
                                    <?php $__currentLoopData = $getUser; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $user): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <?php if($user->id == $data->depositBy): ?>
                                            <?php echo e($user->name); ?>

                                        <?php endif; ?>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </td>
                                <td><?php echo e(number_format($data->amount, 2)); ?></td>
                                <td><?php echo e($data->slipNo); ?></td>
                                <td>
                                    <?php $__currentLoopData = $getUser; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $user): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <?php if($user->id == $data->approveBy): ?>
                                            <?php echo e($user->name); ?>

                                        <?php endif; ?>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </td>
                                <td>
                                    <?php if($data->approveDate != null): ?>
                                        <?php echo e(\Carbon\Carbon::parse($data->approveDate)->format('Y-m-d')); ?>

                                    <?php endif; ?>
                                </td>
                                <td>
                                    <?php $__currentLoopData = $getAccountData; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $accdata): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <?php if($accdata->id == $data->bank): ?>
                                            <?php echo e($accdata->name); ?>

                                        <?php endif; ?>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </td>
                                <td>
                                    <?php if($data->status == 'Pending'): ?>
                                        <span class="badge bg-warning">Pending</span>
                                    <?php else: ?>
                                        <span class="badge bg-success">Approved</span>
                                    <?php endif; ?>
                                </td>
                                <td>
                                    <?php if($data->status == 'Pending'): ?>
                                        <button class="btn btn-primary btn-sm btnApproveModal"
                                            data-id="<?php echo e($data->id); ?>">Approve</button>
                                    <?php endif; ?>
                                </td>
                            </tr>
                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                    </tbody>
                </table>
            </div>
        </div>
    </div>
</div>


<!-- Import Death History Modal -->
<div class="modal fade" id="collectionTransferApproveModal" tabindex="-1" aria-hidden="true">
    <div class="modal-dialog modal-dialog-centered modal-simple">
        <div class="modal-content">
            <div class="modal-body">
                <button type="button" class="btn-close btn-pinned" data-bs-dismiss="modal" aria-label="Close"></button>
                <div class="text-center mb-4">
                    <h4 class="mb-2">Collection Transfer Approve</h4>
                    <p>Collection Transfer function</p>
                </div>
                <input type="text" id="txtCollectionTransferId" hidden>
                <!-- File Input -->
                <div class="col-12 mb-4">
                    <label class="form-label">Choose Bank</label>
                    <select class="selectize" id="txtBank">
                        <?php $__currentLoopData = $getAccountData; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $data): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                            <option value="<?php echo e($data->id); ?>"><?php echo e($data->name); ?></option>
                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                    </select>
                </div>

                <!-- Action Buttons -->
                <div class="col-12 text-center demo-vertical-spacing">
                    <button class="btn btn-primary me-4" id="btnCollectionApprove">Collection Approve</button>
                    <button type="reset" class="btn btn-label-secondary" data-bs-dismiss="modal" aria-label="Close">
                        Discard
                    </button>
                </div>
            </div>
        </div>
    </div>
</div>
<!--/ Import Death History Modal -->
<?php /**PATH /Users/anlex/Desktop/untitled folder/ngo/resources/views/pages/allpages/account/collection_transfer.blade.php ENDPATH**/ ?>