diff --git a/app/controllers/admin_controller.rb b/app/controllers/admin_controller.rb index 2c1c46a..1ad25aa 100644 --- a/app/controllers/admin_controller.rb +++ b/app/controllers/admin_controller.rb @@ -3,27 +3,7 @@ module DiscoursePatrons class AdminController < ::Admin::AdminController def index - payments = Payment.all.order(payments_order) - - render_serialized(payments, PaymentSerializer) - end - - private - - def payments_order - if %w(created_at amount).include?(params[:order]) - { params[:order] => ascending } - else - { created_at: :desc } - end - end - - def ascending - if params[:descending] == 'false' - :desc - else - :asc - end + head 200 end end end