Class: ImpeachmentController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- ImpeachmentController
- Defined in:
- app/controllers/impeachment_controller.rb
Overview
Impeachment and candidates
Instance Method Summary collapse
-
#candidate ⇒ Object
get /impeachment/candidates/:id.
-
#candidates ⇒ Object
get /impeachment/candidates.
Instance Method Details
#candidate ⇒ Object
get /impeachment/candidates/:id
12 13 14 |
# File 'app/controllers/impeachment_controller.rb', line 12 def candidate @entity = Candidate.find(params[:id]) end |
#candidates ⇒ Object
get /impeachment/candidates
6 7 8 9 |
# File 'app/controllers/impeachment_controller.rb', line 6 def candidates @filter = params[:filter] || {} @collection = Candidate.filtered(@filter).list_for_visitors.distinct.page(current_page) end |