[Bug 28118] New: Fix missing "selected" attribute in "Pickup at" dropdown
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Bug ID: 28118 Summary: Fix missing "selected" attribute in "Pickup at" dropdown Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: Hold requests Assignee: koha-bugs@lists.koha-community.org Reporter: magnus@libriotech.no QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com In 20.05.06, when i find a record, click on "Place hold" and search for a patron, I get a form that contains a dropdown labeled "Pickup at". This dropdown has a "selected" attribute on one of the libraries: <select name="pickup" size="1" id="pickup"> <option value="A" selected="selected">A public library</option> <option value="B">B public library</option> </select> In 20.05.10 and 20.12.00.027 (current master), this "selected" attribute seems to be missing. I have not looked deeply at how different settings might affect which library is selected, but I think either way, one library should always be selected? -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@bugs.koha-c | |ommunity.org Status|NEW |ASSIGNED Assignee|koha-bugs@lists.koha-commun |tomascohen@gmail.com |ity.org | Depends on| |27071 --- Comment #1 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Certainly caused by commit aa221e0c8bcf0fa0377d6c2154bad0ef61c97a2b Bug 27071: Use GetReservesControlBranch to pick the branch -my $pickup = $input->param('pickup') || C4::Context->userenv->{'branch'}; +my $pickup = $input->param('pickup'); Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27071 [Bug 27071] Hold pickup library match not enforced correctly on intranet when using hold groups -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 --- Comment #2 from Tomás Cohen Arazi <tomascohen@gmail.com> --- (In reply to Jonathan Druart from comment #1)
Certainly caused by commit aa221e0c8bcf0fa0377d6c2154bad0ef61c97a2b Bug 27071: Use GetReservesControlBranch to pick the branch
-my $pickup = $input->param('pickup') || C4::Context->userenv->{'branch'}; +my $pickup = $input->param('pickup');
That change slipped in inadvertently! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Trivial patch Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 --- Comment #3 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 119469 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119469&action=edit Bug 28118: Default to current branch when placing hold During bug 27071 development, this line got inadvertedly changed. This patch restores the original behaviour. To test: 1. Search for a title 2. Go try place a hold => FAIL: Look at the HTML, there's no pickup location with selected="selected" 3. Switch branch and repeat 2 => FAIL: Still the same 4. Apply this patch 5. Repeat 2 and 3 => SUCCESS: Branch is selected, chosen current branch is picked 6. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 --- Comment #4 from Tomás Cohen Arazi <tomascohen@gmail.com> --- BTW: Sorry for this, Magnus :-/ -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 --- Comment #5 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- I don't think your patch is correct, Tomas. The main point of the commit I cited is to not pick the logged in branchcode. In the following line we will never pick the expected branchcode: 554 my $reserves_control_branch = $pickup // C4::Reserves::GetReservesControlBranch( $item, $patron_unblessed ); -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |rel_21_05_candidate -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |tomascohen@gmail.com Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #119469|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 --- Comment #6 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 119565 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119565&action=edit Bug 28118: Default to current branch when placing hold During bug 27071 development, this line got inadvertedly changed. This patch restores the original behaviour. To test: 1. Search for a title 2. Go try place a hold => FAIL: Look at the HTML, there's no pickup location with selected="selected" 3. Switch branch and repeat 2 => FAIL: Still the same 4. Apply this patch 5. Repeat 2 and 3 => SUCCESS: Branch is selected, chosen current branch is picked 6. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Henry Bolshaw <bolshawh@parliament.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Henry Bolshaw <bolshawh@parliament.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #119565|0 |1 is obsolete| | --- Comment #7 from Henry Bolshaw <bolshawh@parliament.uk> --- Created attachment 119602 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119602&action=edit Bug 28118: Default to current branch when placing hold During bug 27071 development, this line got inadvertedly changed. This patch restores the original behaviour. To test: 1. Search for a title 2. Go try place a hold => FAIL: Look at the HTML, there's no pickup location with selected="selected" 3. Switch branch and repeat 2 => FAIL: Still the same 4. Apply this patch 5. Repeat 2 and 3 => SUCCESS: Branch is selected, chosen current branch is picked 6. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Henry Bolshaw <bolshawh@parliament.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #119602|0 |1 is obsolete| | --- Comment #8 from Henry Bolshaw <bolshawh@parliament.uk> --- Created attachment 119603 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119603&action=edit Bug 28118: Default to current branch when placing hold During bug 27071 development, this line got inadvertedly changed. This patch restores the original behaviour. To test: 1. Search for a title 2. Go try place a hold => FAIL: Look at the HTML, there's no pickup location with selected="selected" 3. Switch branch and repeat 2 => FAIL: Still the same 4. Apply this patch 5. Repeat 2 and 3 => SUCCESS: Branch is selected, chosen current branch is picked 6. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Henry Bolshaw <bolshawh@parliament.uk> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Henry Bolshaw <bolshawh@parliament.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |bolshawh@parliament.uk --- Comment #9 from Henry Bolshaw <bolshawh@parliament.uk> --- Signed off. This patch changes the default pickup branch selected when placing a hold on the staff interface. When testing without the patch, the pickup branch for the hold was simply the branch at the top of the list alphabetically. After the patch, the default pickup branch is the library set by the staff interface. after the patch, this branch also has "selected=selected" in the html code. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #119603|0 |1 is obsolete| | --- Comment #10 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 119605 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119605&action=edit Bug 28118: Default to current branch when placing hold During bug 27071 development, this line got inadvertedly changed. This patch restores the original behaviour. To test: 1. Search for a title 2. Go try place a hold => FAIL: Look at the HTML, there's no pickup location with selected="selected" 3. Switch branch and repeat 2 => FAIL: Still the same 4. Apply this patch 5. Repeat 2 and 3 => SUCCESS: Branch is selected, chosen current branch is picked 6. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Henry Bolshaw <bolshawh@parliament.uk> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA CC| |martin.renvoize@ptfs-europe | |.com --- Comment #11 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Works as described and is a solid improvement. Passing QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Failed QA --- Comment #12 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- We need to keep $pickup for $reserves_control_branch, in case it's passed. request.pl can be called with a specific branchcode from this code in request.tt: 1079 [% IF Koha.Preference('UseBranchTransferLimits') %] 1080 $("#pickup").on('change', function(){ 1081 var pickup = $("#pickup").val(); 1082 var url = "?pickup=" + pickup; 1083 url += "&borrowernumber=" + borrowernumber; 1084 url += "&biblionumber=" + biblionumber; 1085 window.location.replace(url); 1086 }); 1087 [% END %] We need to use Branches.GetLoggedInBranchcode to preselect the option, if pickup is not passed. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |ASSIGNED -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #119605|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 --- Comment #13 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 119629 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119629&action=edit Bug 28118: Default to current branch when placing hold During bug 27071 development, this line got inadvertedly changed. This patch restores the original behaviour. To test: 1. Search for a title 2. Go try place a hold => FAIL: Look at the HTML, there's no pickup location with selected="selected" 3. Switch branch and repeat 2 => FAIL: Still the same 4. Apply this patch 5. Repeat 2 and 3 => SUCCESS: Branch is selected, chosen current branch is picked 6. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #119629|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 --- Comment #14 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 119630 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119630&action=edit Bug 28118: Default to current branch when placing hold During bug 27071 development, this line got inadvertedly changed. This patch restores the original behaviour. To test: 1. Search for a title 2. Go try place a hold => FAIL: Look at the HTML, there's no pickup location with selected="selected" 3. Switch branch and repeat 2 => FAIL: Still the same 4. Apply this patch 5. Repeat 2 and 3 => SUCCESS: Branch is selected, chosen current branch is picked 6. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #119630|0 |1 is obsolete| | --- Comment #15 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 119673 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119673&action=edit Bug 28118: Default to current branch when placing hold During bug 27071 development, this line got inadvertedly changed. This patch restores the original behaviour. To test: 1. Search for a title 2. Go try place a hold => FAIL: Look at the HTML, there's no pickup location with selected="selected" 3. Switch branch and repeat 2 => FAIL: Still the same 4. Apply this patch 5. Repeat 2 and 3 => SUCCESS: Branch is selected, chosen current branch is picked 6. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #119673|0 |1 is obsolete| | --- Comment #16 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 119674 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=119674&action=edit Bug 28118: Default to current branch when placing hold During bug 27071 development, this line got inadvertedly changed. This patch restores the original behaviour. To test: 1. Search for a title 2. Go try place a hold => FAIL: Look at the HTML, there's no pickup location with selected="selected" 3. Switch branch and repeat 2 => FAIL: Still the same 4. Apply this patch 5. Repeat 2 and 3 => SUCCESS: Branch is selected, chosen current branch is picked 6. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |21.05.00 released in| | Status|Passed QA |Pushed to master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 --- Comment #17 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Pushed to master for 21.05, thanks to everybody involved! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|rel_21_05_candidate | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to master |Pushed to stable Version(s)|21.05.00 |21.05.00,20.11.05 released in| | CC| |fridolin.somers@biblibre.co | |m --- Comment #18 from Fridolin Somers <fridolin.somers@biblibre.com> --- Pushed to 20.11.x for 20.11.05 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Andrew Fuerste-Henry <andrew@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |Pushed to oldstable Version(s)|21.05.00,20.11.05 |21.05.00,20.11.05,20.05.11 released in| | CC| |andrew@bywatersolutions.com --- Comment #19 from Andrew Fuerste-Henry <andrew@bywatersolutions.com> --- Pushed to 20.05.x for 20.05.11 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28118 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|Pushed to oldstable |RESOLVED CC| |victor@tuxayo.net --- Comment #20 from Victor Grousset/tuxayo <victor@tuxayo.net> --- Not backported to oldoldstable (19.11.x). Feel free to ask if it's needed. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org