Bugzilla – Attachment 144634 Details for
Bug 31579
Improve reserve/request.pl to avoid mistakes with pick up locations
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 31579: Improve reserve/request.pl to avoid mistakes with pick up locations
Bug-31579-Improve-reserverequestpl-to-avoid-mistak.patch (text/plain), 3.33 KB, created by
Hammat wele
on 2022-12-15 18:40:53 UTC
(
hide
)
Description:
Bug 31579: Improve reserve/request.pl to avoid mistakes with pick up locations
Filename:
MIME Type:
Creator:
Hammat wele
Created:
2022-12-15 18:40:53 UTC
Size:
3.33 KB
patch
obsolete
>From 50b49245a9f9549ae8c9f59b4218806f9468c46e Mon Sep 17 00:00:00 2001 >From: Hammat Wele <hammat.wele@inlibro.com> >Date: Thu, 15 Dec 2022 18:35:10 +0000 >Subject: [PATCH] Bug 31579: Improve reserve/request.pl to avoid mistakes with > pick up locations > >This patch improve the behavior of the intranet reservation page cgi-bin/koha/reserve/request.pl >It ensures that when you change the 'pickup at' value in the 'Hold details' section, the 'Allowed pickup locations' values of each item are also changed (in the table) > >Prerequisites > > have 3 different branches (libraries) > library A - logged in library, the one used to log into the intranet by the employee > library B - item's home library > library C - item's holding library found in the file of the user who will have the reservation > > have a record with multiple copies > create one item for each library A, B, C with homebranch = holdingbranch (with barcode) > >Test plan > > 1- Find a user record > 2- Change the user library (put library C) and Save > 3- Find the notice > 4- Click on 'Place Hold' > 5- Enter user name > 6- Check the 'pickup at' field of the top section and those in the coluumn 'Allowed pickup locations' > 7- Change the library of the top 'pickup at' field > 8- Check the 'Allowed pickup locations' of each item > 9- Notice that the 'Allowed pickup locations' columns are not adjusted > 10- Apply the path > 11- Repeat step 3,4,5,6,7,8 > 12- Notice that all the 'Allowed pickup locations' columns are now adjusted and are the same that the selected 'pickup at' field >--- > .../prog/en/modules/reserve/request.tt | 18 +++++++++++++----- > 1 file changed, 13 insertions(+), 5 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 e2d33c5415..7d637349c2 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >@@ -1375,15 +1375,23 @@ > ToggleHoldsToPlace(); > }); > >- [% IF Koha.Preference('UseBranchTransferLimits') %] >- $("#pickup").on('change', function(){ >- var pickup = $("#pickup").val(); >+ $("#pickup").on('change', function(){ >+ var pickup = $("#pickup").val(); >+ [% IF Koha.Preference('UseBranchTransferLimits') %] > var url = "?pickup=" + pickup; > url += "&borrowernumber=" + borrowernumber; > url += "&biblionumber=" + biblionumbers[0]; > window.location.replace(url); >- }); >- [% END %] >+ [% ELSE %] >+ $(".pickup_locations").each(function () { >+ if ($(this).find("option[value='"+pickup+"']").length == 0){ >+ $(this).append("<option value='"+pickup+"'>"+$("#pickup > option[value='"+pickup+"']").text()+"</option>"); >+ } >+ $(this).val(pickup); >+ $(this).pickup_locations_dropdown(); >+ }); >+ [% END %] >+ }); > > var my_table = $("#requestspecific").dataTable($.extend(true, {}, dataTablesDefaults, { > 'bPaginate': false, >-- >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 31579
:
140907
|
140917
|
140997
|
141007
|
141033
|
144634
|
154550
|
158100
|
158104
|
166636