Bug 39630

Summary: Problems with search for dateaccessioned (ElasticSearch)
Product: Koha Reporter: trevor.diamond
Component: Searching - ElasticsearchAssignee: Bugs List <koha-bugs>
Status: NEW --- QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low    
Version: 24.05   
Hardware: All   
OS: All   
GIT URL: Change sponsored?: ---
Patch complexity: --- Documentation contact:
Documentation submission: Text to go in the release notes:
Version(s) released in:
Circulation function:

Description trevor.diamond 2025-04-14 16:36:09 UTC
Starting in advanced search, if you select Acquisition date as your search qualifer and enter a date (ex: 2025-03-25) you get more results than expected.  If you "search with results" by limiting to Acquisition date, the results refresh with much more reasonable results.  The advanced search code is as follows:

523 result(s) found for '2025-03-25' with limit(s): 'date-of-acquisition:("2025-03-25")'.

Which indicates that your initial selection of Acq date didn't actually "stick".  If you click "edit this search" you are returned to the advanced search screen which shows a keyword search of 2025-03-25, again showing taht your initial selection of acq date isn't being remembered.

If you try this series of steps with a different filter (ex. Publication year), you do not see this kind of behavior (the results are correctly limited in the first pass and going back to edit the search shows the selection of Publication Year for your search qualifier).

This seems very similar to the activity in Bug 17815 ( https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17815 ) but I saw Zebra mentioned several times there and it was suggested that I open a new bug for elasticsearch. 

The solution would be for Advanced search to actual utilize and remember the search qualifer when acquisition date is selected.