From 044237c121440bf44b16da2bb594bc088abc007e Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Mon, 9 Mar 2026 14:09:09 +0100 Subject: [PATCH] Bug 41992: Do not restore pagination offset When "Save configuration state on page change" is enabled, the page number is kept in localStorage and restored. To prevent that we can set the attribute "start" of the state to 0. Test plan: Go on a page with several pages, go to another page than the first one Go the another view and get back Without this patch the last visited page was preserved when returning to the previous view With this patch applied the view now defaults to the first page Note that this does not affect shareable links. Signed-off-by: Laura_Escamilla Signed-off-by: Lucas Gass (cherry picked from commit 91f2e47f4925fae93257bed99ac5a1dbab321b75) Signed-off-by: Baptiste Wojtkowski --- koha-tmpl/intranet-tmpl/prog/js/datatables.js | 1 + 1 file changed, 1 insertion(+) diff --git a/koha-tmpl/intranet-tmpl/prog/js/datatables.js b/koha-tmpl/intranet-tmpl/prog/js/datatables.js index 1d2ced2ff0..d2496ed2c3 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/datatables.js +++ b/koha-tmpl/intranet-tmpl/prog/js/datatables.js @@ -1245,6 +1245,7 @@ function _dt_save_restore_state(table_settings, external_filter_nodes = {}) { } state = _dt_force_visibility(table_settings, this.api(), state); + state.start = 0; return state; };