Bug 41341 - Some filters do not use the exact match in detail.pl
Summary: Some filters do not use the exact match in detail.pl
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: Staff interface (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on: 39011
Blocks:
  Show dependency treegraph
 
Reported: 2025-12-01 15:51 UTC by Baptiste Wojtkowski (bwoj)
Modified: 2025-12-02 10:50 UTC (History)
2 users (show)

See Also:
GIT URL:
Initiative type: ---
Sponsorship status: ---
Comma delimited list of Sponsors:
Crowdfunding goal: 0
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 41341: [WIP] Reestablish exact matching on library/items (1.99 KB, patch)
2025-12-01 15:59 UTC, Baptiste Wojtkowski (bwoj)
Details | Diff | Splinter Review
Bug 41341: Do not search the description if filter is selected in the header (1.38 KB, patch)
2025-12-02 10:50 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Baptiste Wojtkowski (bwoj) 2025-12-01 15:51:44 UTC
Bug 40876 added an exact match constraint on column filtering.

However, it looks like historically, there were such filters on itemtypes and library (option values are in the form of "^XXX$") but are not applied anymore.

Steps to reproduce:
1 - Create a library with code "M" and an itemtype with code "B".
2 - Go on /cgi-bin/koha/catalogue/detail.pl?biblionumber=233 (a biblio with items from midway (MPL) and books (BK) 
3 - Filter using library and itemtype created in 1 -> you will get some new filters
Comment 1 Baptiste Wojtkowski (bwoj) 2025-12-01 15:59:20 UTC
Created attachment 190057 [details] [review]
Bug 41341: [WIP] Reestablish exact matching on library/items

Test plan
1 - Create a library with code "M" and an itemtype with code "B".
2 - Go on /cgi-bin/koha/catalogue/detail.pl?biblionumber=233 (a biblio with items from midway (MPL) and books (BK)
3 - Filter using library and itemtype created in 1 -> you will get some new filters
4 - Apply patch
5 - Test 3 again -> you should have no result anymore.
6 - Check that filters still work on libraries/items
Comment 2 Jonathan Druart 2025-12-02 10:50:18 UTC
Created attachment 190072 [details] [review]
Bug 41341: Do not search the description if filter is selected in the header

For coded values we have a dropdown list with the list of the possible
options, we should not search on the description

Test plan:
If you have
CPL => Centerville
C   => CCC

No items should be listed on catalogue/detail.pl?biblionumber=4 if you select Current library => 'CCC'