Module: ActiveRecord::JSONB::Associations::Preloader::Association
- Defined in:
- lib/activerecord/jsonb/associations/preloader/association.rb
Overview
:nodoc:
Instance Method Summary collapse
Instance Method Details
#records_for(ids) ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 |
# File 'lib/activerecord/jsonb/associations/preloader/association.rb', line 6 def records_for(ids) return super unless reflection..key?(:foreign_store) scope.where( Arel::Nodes::JSONBHashArrow.new( table, table[reflection.[:foreign_store]], association_key_name ).intersects_with(ids) ) end |