Merge pull request #632 from okriuchykhin/ok_SCI_1284

Fix bug in counting search results for assets [SCI-1284]
This commit is contained in:
okriuchykhin 2017-05-17 09:54:09 +02:00 committed by GitHub
commit 7ec53d493b

View file

@ -96,7 +96,14 @@ class SearchController < ApplicationController
end
def count_by_name(model)
search_by_name(model).limit(nil).offset(nil).size
model.search(current_user,
true,
@search_query,
Constants::SEARCH_NO_LIMIT,
nil,
match_case: @search_case,
whole_word: @search_whole_word,
whole_phrase: @search_whole_phrase).size
end
def count_search_results