Islandora / advanced_search

This module creates several blocks to support searching. It also enables the use of Ajax with search blocks, facets, and search results.
https://www.drupal.org/project/advanced_search
GNU General Public License v2.0
3 stars 9 forks source link

Default sort direction is Relevance DESC, but Relevance ASC is what's displayed. #24

Closed rosiel closed 1 year ago

rosiel commented 1 year ago

When searching with the keyword block the results come back sorted relevance desc. This is good and eexpected. The largest relevance (best results) comes first.

But the Pager block widget displays "Relevance up arrow". This is incorrect because it does not reflect what is actually happening.

If you open the dropdown and select another sort, then change it back to "Relevance up arrow" then you will get the worst results first.

I think the default on this line needs to change from ASC to DESC.

https://github.com/digitalutsc/advanced_search/blob/contrib/src/Plugin/Block/SearchResultsPagerBlock.php#L277-L278