From af8573c92903ddb17d3ed84cb000125402a2bab6 Mon Sep 17 00:00:00 2001 From: Luca Haid Date: Tue, 11 Mar 2025 18:00:30 +0100 Subject: [PATCH] fixed pagination issue --- public/plugins/vue/tt-components/tt-table.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/public/plugins/vue/tt-components/tt-table.js b/public/plugins/vue/tt-components/tt-table.js index f543b07a9..f6b7576f0 100644 --- a/public/plugins/vue/tt-components/tt-table.js +++ b/public/plugins/vue/tt-components/tt-table.js @@ -779,6 +779,9 @@ Vue.component('tt-table', { // Pagination and slice logic this.pagination.total_pages = Math.ceil(this.computedRows.length / this.pagination.per_page); this.pagination.filtered_available = this.computedRows.length; + if (this.pagination.page > this.pagination.total_pages) { + this.pagination.page = this.pagination.total_pages; + } const perPage = this.pagination.per_page; const page = this.pagination.page; const startIndex = (page - 1) * perPage;