mirror of
https://github.com/internetee/registry.git
synced 2025-06-10 14:44:47 +02:00
refactored
This commit is contained in:
parent
8f17712232
commit
d2d31c049c
19 changed files with 32 additions and 112 deletions
|
@ -14,17 +14,7 @@ module Admin
|
|||
@count = @q.result.count
|
||||
@epp_logs = @epp_logs.per(params[:results_per_page]) if paginate?
|
||||
|
||||
respond_to do |format|
|
||||
format.html do
|
||||
render 'admin/epp_logs/index'
|
||||
end
|
||||
format.csv do
|
||||
raw_csv = @q.result.to_csv
|
||||
send_data raw_csv,
|
||||
filename: "epp_logs_#{Time.zone.now.to_formatted_s(:number)}.csv",
|
||||
type: "#{Mime[:csv]}; charset=utf-8"
|
||||
end
|
||||
end
|
||||
render_by_format('admin/epp_logs/index', 'epp_logs')
|
||||
end
|
||||
|
||||
def show
|
||||
|
@ -43,7 +33,6 @@ module Admin
|
|||
|
||||
params[:q][:created_at_gteq] = Date.send(default_date).strftime("%Y-%m-%d")
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue