https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22801
Kyle M Hall <k...@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #122069|0 |1 is obsolete| | Attachment #122070|0 |1 is obsolete| | --- Comment #16 from Kyle M Hall <k...@bywatersolutions.com> --- Created attachment 123138 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=123138&action=edit Bug 22801: Advance search yr must use date-of-publication and not copydate In advanced search with Elasticsearch the limit on years range is actually using copydate : Koha/SearchEngine/Elasticsearch/QueryBuilder.pm in _fix_limit_special_cases() : if ( $l =~ /^yr,st-numeric,ge=/ ) { my ( $start, $end ) = ( $l =~ /^yr,st-numeric,ge=(.*) and yr,st-numeric,le=(.*)$/ ); next unless defined($start) && defined($end); push @new_lim, "copydate:[$start TO $end]"; } With Zebra it uses date-of-publication and also in Koha/SearchEngine/Elasticsearch/QueryBuilder.pm : our %index_field_convert = ( (...) 'yr' => 'date-of-publication', This patch uses %index_field_convert to perform 'yr' limit. Test plan: 1) Apply patch 2) Use Elasticsearch searchengine 3) Go to advanced search with 'More options' 4) Perform a search with a year limit (value or range) 5) Check results are correct Signed-off-by: David Nind <da...@davidnind.com> Signed-off-by: David Nind <da...@davidnind.com> Signed-off-by: Kyle M Hall <k...@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list Koha-bugs@lists.koha-community.org https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/