Bugzilla – Attachment 180990 Details for
Bug 39634
Other holdings table paging numbers not correct initially
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 39634: Correct paging number on initial load of other_holdings table
Bug-39634-Correct-paging-number-on-initial-load-of.patch (text/plain), 2.19 KB, created by
PTFS Europe Sandboxes
on 2025-04-15 19:24:02 UTC
(
hide
)
Description:
Bug 39634: Correct paging number on initial load of other_holdings table
Filename:
MIME Type:
Creator:
PTFS Europe Sandboxes
Created:
2025-04-15 19:24:02 UTC
Size:
2.19 KB
patch
obsolete
>From 61d77134e15e88532b5a7742eb0a5dc70be51b5d Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Mon, 14 Apr 2025 22:33:57 +0000 >Subject: [PATCH] Bug 39634: Correct paging number on initial load of > other_holdings table > >To test: >1. Turn on SeparateHoldings >2. Have an item with many items at another branch, so 'Other holdings' table is large. I added 50 items to FPL. >3. Logged in as CPL go to the record in normal view. >4. Click on the 'Other holdings' tab, which should have 50+ items >5. Notice you only see the number 1 in the paging tools. >6. Click 'Next', the paging numbers correct themselves. >7. APPLY PATCH >8. Try again, this time the paging numbers should be correct initially. > >Signed-off-by: George Williams <george@nekls.org> >--- > .../html_helpers/tables/items/catalogue_detail.inc | 9 ++++++++- > 1 file changed, 8 insertions(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/html_helpers/tables/items/catalogue_detail.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/html_helpers/tables/items/catalogue_detail.inc >index 5345a936b8..56145c2ede 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/html_helpers/tables/items/catalogue_detail.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/html_helpers/tables/items/catalogue_detail.inc >@@ -288,7 +288,6 @@ > otherholdings: "[% PROCESS 'build_table' tab="otherholdings" | collapse | $tojson %]", > }; > function build_items_table (tab_id, add_filters, dt_options, drawcallback) { >- > let table_dt; > if ( dt_options && dt_options.hasOwnProperty('destroy') ) { > // Keep a copy of the user settings, the destroy is going to trigger the column-visibility.dt event for all columns >@@ -920,5 +919,13 @@ > node.textContent = link_text; > return node; > } >+ >+ $('a[data-bs-toggle="tab"]').on('shown.bs.tab', function (e) { >+ const table = $(e.target).attr('href').replace('_panel' , '_table'); >+ const selector = $(table); >+ if ($.fn.DataTable.isDataTable(selector)) { >+ selector.DataTable().columns.adjust().draw(false); >+ } >+ }); > </script> > [% END %] >-- >2.39.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 39634
:
180945
|
180946
| 180990