first_comment

first_comment() Instance Public methods

controller_class=

controller_class=(new_class) Instance Public methods

app_middleware

app_middleware() Instance Public methods This allows you to modify the application's middlewares from Engines. All operations you run on the #app_middleware will be replayed on the application once it is defined and the default_middlewares are created

to_key

to_key() Instance Public methods

validates_length_of

validates_length_of(*attr_names) Instance Public methods Validates that the specified attribute matches the length restrictions supplied. Only one option can be used at a time: class Person < ActiveRecord::Base validates_length_of :first_name, maximum: 30 validates_length_of :last_name, maximum: 30, message: "less than 30 if you don't mind" validates_length_of :fax, in: 7..32, allow_nil: true validates_length_of :phone, in: 7..32, allow_blank: true validates_length_of

model_name_from_record_or_class

model_name_from_record_or_class(record_or_class) Instance Public methods

test_model_naming

test_model_naming() Instance Public methods Naming Model.model_name must return a string with some convenience methods: :human, :singular and :plural. Check ActiveModel::Naming for more information.

test_quote_integer_string_column

test_quote_integer_string_column() Instance Public methods

compare_without_coercion

compare_without_coercion(other) Instance Public methods Alias for: <=>

remove_reference

remove_reference(table_name, ref_name, options = {}) Instance Public methods Removes the reference(s). Also removes a type column if one exists. remove_reference, remove_references and remove_belongs_to are acceptable. Remove the reference remove_reference(:products, :user, index: true) Remove polymorphic reference remove_reference(:products, :supplier, polymorphic: true) remove_belongs_to