Bug 35127 - Patron search ignores searchtype from the context menu
Summary: Patron search ignores searchtype from the context menu
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Jonathan Druart
QA Contact: Marcel de Rooy
URL:
Keywords:
Depends on: 33117
Blocks:
  Show dependency treegraph
 
Reported: 2023-10-23 09:52 UTC by Marcel de Rooy
Modified: 2024-07-04 20:40 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
23.11.00,23.05.05,22.11.12
Circulation function:


Attachments
Bug 35127: Fix 'Search type' for patron search (4.94 KB, patch)
2023-10-24 13:35 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 35127: Fix 'Search type' for patron search (5.00 KB, patch)
2023-10-24 17:24 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review
Bug 35127: Fix 'Search type' for patron search (5.08 KB, patch)
2023-10-25 11:40 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Marcel de Rooy 2023-10-23 09:52:08 UTC
Go to Patrons.
Click the right context menu.
Select the other option than the one selected. (Depends on a pref.)
Search for some user.
Verify that the searchtype has not been used correctly.
Comment 1 Marcel de Rooy 2023-10-23 09:54:26 UTC
This is on master, but I saw it on 22.11 too
Comment 2 Jonathan Druart 2023-10-24 13:32:14 UTC
Seems that bug 33117 broken this.
Comment 3 Jonathan Druart 2023-10-24 13:35:49 UTC
Created attachment 157745 [details] [review]
Bug 35127: Fix 'Search type' for patron search

We need to fallback on the syspref DefaultPatronSearchMethod but keep
the value when one is passed!

Test plan:
Search for patrons, and use the "search type". Set it to different
values than DefaultPatronSearchMethod and confirm that the value is
kept.
Fix is expected when searching for patrons in the header (use the
options to select a different value and run the search)
Comment 4 Lucas Gass (lukeg) 2023-10-24 17:24:04 UTC
Created attachment 157752 [details] [review]
Bug 35127: Fix 'Search type' for patron search

We need to fallback on the syspref DefaultPatronSearchMethod but keep
the value when one is passed!

Test plan:
Search for patrons, and use the "search type". Set it to different
values than DefaultPatronSearchMethod and confirm that the value is
kept.
Fix is expected when searching for patrons in the header (use the
options to select a different value and run the search)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Comment 5 Marcel de Rooy 2023-10-25 11:40:21 UTC
Created attachment 157784 [details] [review]
Bug 35127: Fix 'Search type' for patron search

We need to fallback on the syspref DefaultPatronSearchMethod but keep
the value when one is passed!

Test plan:
Search for patrons, and use the "search type". Set it to different
values than DefaultPatronSearchMethod and confirm that the value is
kept.
Fix is expected when searching for patrons in the header (use the
options to select a different value and run the search)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 6 Marcel de Rooy 2023-10-25 11:40:49 UTC
Thx for a quick fix, Jonathan.
Comment 7 Tomás Cohen Arazi (tcohen) 2023-10-25 13:36:30 UTC
Pushed to master for 23.11.

Nice work everyone, thanks!
Comment 8 Fridolin Somers 2023-10-26 07:52:21 UTC
Pushed to 23.05.x for 23.05.05
Comment 9 Matt Blenkinsop 2023-11-13 15:11:39 UTC
Nice work everyone!

Pushed to oldstable for 22.11.x