diff --git a/backend/resources/views/admin/kategori_fitur/index.blade.php b/backend/resources/views/admin/kategori_fitur/index.blade.php index c64a643..32b7618 100644 --- a/backend/resources/views/admin/kategori_fitur/index.blade.php +++ b/backend/resources/views/admin/kategori_fitur/index.blade.php @@ -35,55 +35,104 @@ @endif - -
-
- - - - - - - - - - @forelse ($kategoriFitur as $item) - - - - - - @empty + +
+
+
IDDeskripsiAksi
- {{ $item->id }} - - {{ $item->deskripsi }} - -
- - -
-
+ - + + + - @endforelse - -
Belum ada kategori fiturIDDeskripsiAksi
-
+ + + @forelse ($kategoriFitur as $item) + + + {{ $item->id }} + + + {{ $item->deskripsi }} + + +
+ + +
+ + + @empty + + Belum ada kategori fitur + + @endforelse + + +
- -
- {{ $kategoriFitur->links() }} -
+ +
+
+ {{-- Tombol Previous --}} + @if ($kategoriFitur->onFirstPage()) + Prev + @else + Prev + @endif + + @php + $total = $kategoriFitur->lastPage(); + $current = $kategoriFitur->currentPage(); + @endphp + + {{-- Selalu tampilkan halaman pertama --}} + @if ($current > 2) + 1 + @if ($current > 3) + ... + @endif + @endif + + {{-- Halaman tengah --}} + @for ($i = max(1, $current - 1); $i <= min($total, $current + 1); $i++) + @if ($i == $current) + {{ $i }} + @else + {{ $i }} + @endif + @endfor + + {{-- Selalu tampilkan halaman terakhir --}} + @if ($current < $total - 1) + @if ($current < $total - 2) + ... + @endif + {{ $total }} + @endif + + {{-- Tombol Next --}} + @if ($kategoriFitur->hasMorePages()) + Next + @else + Next + @endif
+ +