method

type_condition

Importance_0
v3.0.9 - Show latest stable - 0 notes - Class: ActiveRecord::Base
type_condition() private

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activerecord/lib/active_record/base.rb, line 945
        def type_condition
          sti_column = arel_table[inheritance_column]
          condition = sti_column.eq(sti_name)
          descendants.each { |subclass| condition = condition.or(sti_column.eq(subclass.sti_name)) }

          condition
        end
Register or log in to add new notes.