Sha256: 6df666398cbc39eec25943c082a2d3134960fefd58c597f218f1e05cc57a71f0

Contents?: true

Size: 227 Bytes

Versions: 17

Compression:

Stored size: 227 Bytes

Contents

class Restaurant < ActiveRecord::Base
  set_primary_keys :franchise_id, :store_id
  has_and_belongs_to_many :suburbs, 
    :foreign_key => [:franchise_id, :store_id],  
    :association_foreign_key => [:city_id, :suburb_id]
end

Version data entries

17 entries across 17 versions & 3 rubygems

Version Path
tyler-composite_primary_keys-1.1.0 test/fixtures/restaurant.rb
composite_primary_keys-3.1.8 test/fixtures/restaurant.rb
composite_primary_keys-3.1.7 test/fixtures/restaurant.rb
composite_primary_keys-3.1.6 test/fixtures/restaurant.rb
composite_primary_keys-3.1.5 test/fixtures/restaurant.rb
composite_primary_keys-3.1.4 test/fixtures/restaurant.rb
composite_primary_keys-3.1.2 test/fixtures/restaurant.rb
composite_primary_keys-3.1.1 test/fixtures/restaurant.rb
composite_primary_keys-3.1.0 test/fixtures/restaurant.rb
composite_primary_keys-3.0.9 test/fixtures/restaurant.rb
composite_primary_keys-3.0.8 test/fixtures/restaurant.rb
composite_primary_keys-3.0.7 test/fixtures/restaurant.rb
composite_primary_keys-3.0.4 test/fixtures/restaurant.rb
composite_primary_keys-3.0.3 test/fixtures/restaurant.rb
composite_primary_keys-3.0.0.b3 test/fixtures/restaurant.rb
composite_primary_keys-3.0.0.b2 test/fixtures/restaurant.rb
globe-composite_primary_keys-3.0.1 test/fixtures/restaurant.rb