Class: Competition::LeaderboardController
- Inherits:
-
ApplicationController
- Object
- ActionController::Base
- ApplicationController
- Competition::LeaderboardController
- Defined in:
- app/controllers/competition/leaderboard_controller.rb
Instance Method Summary collapse
Instance Method Details
#index ⇒ Object
5 6 7 8 |
# File 'app/controllers/competition/leaderboard_controller.rb', line 5 def index #TODO: Make this not suck @scores = Competition::Score.all.sort {|a, b| b.score_entries.sum(:amount) <=> a.score_entries.sum(:amount)} end |