<div class="table-responsive">
    <table id="basic-datatables" class="display table table-striped table-hover dataTable" role="grid">
        <thead>
            <tr role="row">
                <th>Tên Khóa Học</th>
                <th>Tạo</th>
                <th>Sửa</th>
                <th>Hành Động</th>
            </tr>
        </thead>
        <tbody>
            <?php $__empty_1 = true; $__currentLoopData = $getAllCourse; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $items): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); $__empty_1 = false; ?>
                <tr role="row" class="odd">
                    <td><?php echo e($items->name); ?></td>
                    <td><?php echo e($items->creator_name); ?> (<?php echo e($items->created_at->format('d-m-Y')); ?>)</td>
                    <td>
                        <?php if($items->deleted_at): ?>
                            Đã xóa bởi <?php echo e($items->deleter_name ?? 'Không Có'); ?>

                        <?php else: ?>
                            <?php echo e($items->updater_name ?? 'Không Có'); ?>

                            <?php echo e(!empty($items->updated_at) ? '(' . $items->updated_at->format('d-m-Y') . ')' : ''); ?>

                        <?php endif; ?>
                    </td>
                    <td>
                        <a href="<?php echo e($items->deleted_at ? route('course.restore', ['id' => $items->id]) : route('course.edit', ['id' => $items->id])); ?>" class="btn btn-sm <?php echo e($items->deleted_at ? 'btn-success' : 'btn-black'); ?>">
                            <i class="fa <?php echo e($items->deleted_at ? 'fa-undo' : 'fa-edit'); ?>"></i>
                        </a>
                        <?php if($items->deleted_at): ?>
                            <a href="#" class="btn btn-sm btn-danger" data-toggle="modal" data-target="#deleteModal<?php echo e($items->id); ?>">
                                <i class="fas fa-trash-alt"></i>
                            </a>
                        <?php else: ?>
                            <form action="<?php echo e(route('course.destroy', $items)); ?>" method="POST" style="display:inline-block;">
                                <?php echo csrf_field(); ?>
                                <?php echo method_field('DELETE'); ?>
                                <button type="submit" class="btn btn-sm btn-danger">
                                    <i class="fas fa-trash"></i>
                                </button>
                            </form>
                        <?php endif; ?>
                        <?php echo $__env->make('admin.course.course.components.modal', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
                    </td>
                </tr>
            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); if ($__empty_1): ?>
                <tr>
                    <td colspan="4" class="text-center">Không có dữ liệu</td>
                </tr>
            <?php endif; ?>
        </tbody>
    </table>

    <!-- Phần thông tin phân trang -->
    <div class="dataTables_info">
        Hiển thị <?php echo e($info['from']); ?> đến <?php echo e($info['to']); ?> của <?php echo e($info['total']); ?> khóa học
    </div>

    <!-- Phần phân trang -->
    <div class="dataTables_paginate paging_simple_numbers">
        <ul class="pagination">
            <?php if($getAllCourse->onFirstPage()): ?>
                <li class="paginate_button page-item previous disabled">
                    <a href="#" class="page-link">Trước</a>
                </li>
            <?php else: ?>
                <li class="paginate_button page-item previous">
                    <a href="<?php echo e($getAllCourse->previousPageUrl()); ?>" class="page-link">Trước</a>
                </li>
            <?php endif; ?>

            <?php $__currentLoopData = $getAllCourse->getUrlRange(1, $getAllCourse->lastPage()); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $page => $url): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                <li class="paginate_button page-item <?php echo e($page == $getAllCourse->currentPage() ? 'active' : ''); ?>">
                    <a href="<?php echo e($url); ?>" class="page-link"><?php echo e($page); ?></a>
                </li>
            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>

            <?php if($getAllCourse->hasMorePages()): ?>
                <li class="paginate_button page-item next">
                    <a href="<?php echo e($getAllCourse->nextPageUrl()); ?>" class="page-link">Tiếp</a>
                </li>
            <?php else: ?>
                <li class="paginate_button page-item next disabled">
                    <a href="#" class="page-link">Tiếp</a>
                </li>
            <?php endif; ?>
        </ul>
    </div>
</div>
<?php /**PATH C:\Users\phama\OneDrive\Desktop\Tai_Nguyen_Hoc_Tap\DuAnPHP3\SchoolManagementSystem\resources\views/admin/course/course/components/pagination.blade.php ENDPATH**/ ?>