method
make_constraints
v6.0.0 -
Show latest stable
- Class:
ActiveRecord::Associations::JoinDependency
make_constraints(parent, child, join_type)private
No documentation available.
# File activerecord/lib/active_record/associations/join_dependency.rb, line 155
def make_constraints(parent, child, join_type)
foreign_table = parent.table
foreign_klass = parent.base_klass
joins = child.join_constraints(foreign_table, foreign_klass, join_type, alias_tracker)
joins.concat child.children.flat_map { |c| make_constraints(child, c, join_type) }
end