Skip to content

Commit

Permalink
πŸ› Sort by: Published Date
Browse files Browse the repository at this point in the history
This commit pulls in an update to Hyku that fixes a bug when sorting by
title, author, and created date (published date). The Hyku indexing
moves from `CollectionResource` to `CollectionResourceIndexer`.

Ref:
- #185
  • Loading branch information
sjproctor committed Sep 17, 2024
1 parent 9582644 commit 83b30bd
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/controllers/catalog_controller_decorator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -115,12 +115,12 @@ def self.uploaded_field

config.add_sort_field "score desc, #{uploaded_field} desc", label: "Relevance"
# TODO: replace CatalogController.title_field to return 'title_ssi'
config.add_sort_field "title_ssi asc", label: "Title"
config.add_sort_field "title_ssim asc", label: "Title"
# TODO: replace CatalogController.creator_field to return 'creator_ssi'
config.add_sort_field "creator_ssi asc", label: "Author"
config.add_sort_field "creator_ssim asc", label: "Author"
# TODO: replace CatalogController.created_field to return 'created_ssi'
config.add_sort_field "created_ssi asc", label: "Published Date (Ascending)"
config.add_sort_field "created_ssi desc", label: "Published Date (Descending)"
config.add_sort_field "#{CatalogController.created_field} asc", label: "Published Date (Ascending)"
config.add_sort_field "#{CatalogController.created_field} desc", label: "Published Date (Descending)"
config.add_sort_field "#{CatalogController.modified_field} asc", label: "Upload Date (Ascending)"
config.add_sort_field "#{CatalogController.modified_field} desc", label: "Upload Date (Descending)"
end

0 comments on commit 83b30bd

Please sign in to comment.