class OregonCupController

Public Instance Methods

index() click to toggle source
# File app/controllers/oregon_cup_controller.rb, line 2
def index
  @year = params['year'] || Time.zone.today.year.to_s
  date = Date.new(@year.to_i, 1, 1)
  @oregon_cup = OregonCup.first(:conditions => ['date = ?', date]) || OregonCup.new(:date => date)
end