Module: Pluckers::Features::BelongsToReflections
- Included in:
- Base
- Defined in:
- lib/pluckers/features/active_record_3_2/belongs_to_reflections.rb,
lib/pluckers/features/active_record_4_0/belongs_to_reflections.rb,
lib/pluckers/features/active_record_4_1/belongs_to_reflections.rb,
lib/pluckers/features/active_record_4_2/belongs_to_reflections.rb,
lib/pluckers/features/active_record_5_0/belongs_to_reflections.rb,
lib/pluckers/features/active_record_5_1/belongs_to_reflections.rb
Instance Method Summary collapse
Methods included from Pluckers::Features::Base::BelongsToReflections
#build_results, #configure_query
Instance Method Details
#active_record_belongs_to_reflection?(reflection) ⇒ Boolean
7 8 9 10 11 |
# File 'lib/pluckers/features/active_record_3_2/belongs_to_reflections.rb', line 7 def active_record_belongs_to_reflection? reflection reflection.is_a?(ActiveRecord::Reflection::AssociationReflection) && reflection.macro == :belongs_to && !reflection.[:polymorphic] end |