Class: InnerPerformance::EventsController
- Inherits:
-
ApplicationController
- Object
- ActionController::Base
- ApplicationController
- InnerPerformance::EventsController
- Includes:
- Pagy::Backend
- Defined in:
- app/controllers/inner_performance/events_controller.rb
Instance Method Summary collapse
Instance Method Details
#index ⇒ Object
5 6 7 8 9 |
# File 'app/controllers/inner_performance/events_controller.rb', line 5 def index @q = InnerPerformance::Event.all.ransack(params[:q]) @q.sorts = "created_at desc" if @q.sorts.empty? @pagy, @events = pagy(@q.result) end |