Do not paginate CSV and PDF export

#721
This commit is contained in:
Artur Beljajev 2018-02-16 23:00:01 +02:00
parent e3abdc2394
commit af78fcbc8f

View file

@ -50,11 +50,9 @@ class Registrar
normalize_search_parameters do
@q = contacts.search(params[:q])
@contacts = @q.result.page(params[:page])
@contacts = @q.result
end
@contacts = @contacts.per(params[:results_per_page]) if params[:results_per_page].to_i > 0
respond_to do |format|
format.csv { render text: @contacts.to_csv }
format.pdf do