Good notes posted by ronald
RSS feed
ronald -
March 27, 2009
4 thanks
multiple filter example
actually you can have it even shorter with:
before_filter :authorize, :set_locale, :except => :login
ronald -
January 26, 2009
5 thanks
two ways to disable single table inheritance
-
Don’t use the column name ‘type’
-
Or if the first is no option for you: Tell Rails to look for a not existing column like:
class MyModel < ActiveRecord::Base
# disable STI inheritance_column = :_type_disabled end
ronald -
January 26, 2009 - (>= v2.2.1)
3 thanks
alternative (working with 2.2.X)
ActionController::Base.relative_url_root