Added test for RootRouteConstraint and conferences#current
This commit is contained in:
parent
529b8eb710
commit
ee7684d845
5 changed files with 60 additions and 5 deletions
|
|
@ -12,7 +12,7 @@ class ConferencesController < ApplicationController
|
|||
def show; end
|
||||
|
||||
def current
|
||||
current = Conference.first
|
||||
current = Conference.where('start_date <= ? AND end_date >= ?', Date.current, Date.current).first
|
||||
redirect_to conference_path(current.short_title)
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue