Bugzilla – Attachment 173485 Details for
Bug 33484
Ability to remember user's selected table configuration and search filters for tables
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33484: Include patron search code if no patron selected yet
Bug-33484-Include-patron-search-code-if-no-patron-.patch (text/plain), 3.12 KB, created by
Jonathan Druart
on 2024-10-28 09:46:53 UTC
(
hide
)
Description:
Bug 33484: Include patron search code if no patron selected yet
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2024-10-28 09:46:53 UTC
Size:
3.12 KB
patch
obsolete
>From c1036ed64cc2cf38a641f16378afdb8427cde184 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 24 Oct 2024 10:37:59 +0200 >Subject: [PATCH] Bug 33484: Include patron search code if no patron selected > yet > >When placing a hold we should not display the patron search code >(html+js) if we have picked a patron already, otherwise a get a JS error > Uncaught TypeError: table_dt.settings()[0] is undefined > >koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc >781 let table_dt = patrons_table.DataTable(); >782 let loaded_from_state = table_dt.settings()[0].loaded_from_state; > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > .../prog/en/modules/reserve/request.tt | 20 +++++++++++-------- > 1 file changed, 12 insertions(+), 8 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >index 2141e06c512..8d1c1fddc3f 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >@@ -1998,16 +1998,20 @@ > table_settings = [% TablesSettings.GetTableSettings( 'circ', 'circulation', 'table_borrowers', 'json' ) | $raw %]; > </script> > >- [% SET search_results_block_id = 'holds_patronsearch_pane_panel' %] [%# adjusting variable for patron-search.inc %] >- [% PROCESS patron_search_js table_id => 'table_borrowers', categories => categories, libraries => libraries, columns => columns, open_on_row_click => 1, on_click_url => '/cgi-bin/koha/reserve/request.pl?' _ url_biblio_params, redirect_if_one_result => 1, redirect_url => '/cgi-bin/koha/reserve/request.pl?' _ url_biblio_params, redirect_if_attribute_equal => 'cardnumber' %] >+ [% UNLESS patron %] >+ [% SET search_results_block_id = 'holds_patronsearch_pane_panel' %] [%# adjusting variable for patron-search.inc %] >+ [% PROCESS patron_search_js table_id => 'table_borrowers', categories => categories, libraries => libraries, columns => columns, open_on_row_click => 1, on_click_url => '/cgi-bin/koha/reserve/request.pl?' _ url_biblio_params, redirect_if_one_result => 1, redirect_url => '/cgi-bin/koha/reserve/request.pl?' _ url_biblio_params, redirect_if_attribute_equal => 'cardnumber' %] >+ <script> >+ $(document).ready(function() { >+ $("#holds_patronsearch").on("submit", filter); >+ }); >+ </script> >+ [% END %] > <script> >- $(document).ready(function() { >- $("#holds_patronsearch").on("submit", filter); >- }); > $('.printholdslip').click(function(){ >- var reserve_id = $(this).attr('data-reserve_id'); >- window.open("/cgi-bin/koha/circ/hold-transfer-slip.pl?reserve_id=" + reserve_id); >- return false; >+ var reserve_id = $(this).attr('data-reserve_id'); >+ window.open("/cgi-bin/koha/circ/hold-transfer-slip.pl?reserve_id=" + reserve_id); >+ return false; > }) > </script> > [% END %] >-- >2.34.1
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 33484
:
149444
|
149445
|
149447
|
149448
|
149449
|
149925
|
149926
|
149927
|
149928
|
149929
|
149930
|
149974
|
149975
|
149976
|
149977
|
149978
|
149979
|
173443
|
173444
|
173445
|
173446
|
173447
|
173448
|
173449
|
173450
|
173451
|
173452
|
173453
|
173454
|
173455
|
173456
|
173457
|
173458
|
173459
|
173460
|
173461
|
173462
|
173463
|
173464
|
173465
|
173466
|
173467
|
173468
|
173469
|
173470
|
173471
|
173472
|
173473
|
173474
|
173475
|
173476
|
173477
|
173478
|
173479
|
173480
|
173481
|
173482
|
173483
|
173484
| 173485 |
173486
|
173546
|
173606
|
173607
|
173985
|
174219