sort by date by default in web form

This commit is contained in:
Joerg Reichert 2016-03-26 16:51:00 +01:00
parent eef07c25b9
commit cdc5fcedf5

View file

@ -8,7 +8,7 @@ end
class SearchController < ApplicationController class SearchController < ApplicationController
def index def index
@search_definition = PaperSearch.new(search_params) @search_definition = PaperSearch.new(search_params)
@search_definition.sort_by ||= "score" @search_definition.sort_by ||= "date"
execute_search execute_search
end end