Sha256: 3770e99589962d2cac0fe9aaf0a40f5da9fe05d21291423e17d86b197a32ce75

Contents?: true

Size: 236 Bytes

Versions: 29

Compression:

Stored size: 236 Bytes

Contents

class ProductTariff < ActiveRecord::Base
	self.primary_keys = :product_id, :tariff_id, :tariff_start_date
	belongs_to :product, :foreign_key => :product_id
	belongs_to :tariff,  :foreign_key => [:tariff_id, :tariff_start_date]
end

Version data entries

29 entries across 29 versions & 1 rubygems

Version Path
composite_primary_keys-13.0.1 test/fixtures/product_tariff.rb
composite_primary_keys-13.0.0 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.10 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.9 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.8 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.6 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.5 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.4 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.3 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.2 test/fixtures/product_tariff.rb
composite_primary_keys-11.3.1 test/fixtures/product_tariff.rb
composite_primary_keys-8.1.8 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.1 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.0 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.0.rc5 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.0.rc4 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.0.rc3 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.0.rc2 test/fixtures/product_tariff.rb
composite_primary_keys-12.0.0.rc1 test/fixtures/product_tariff.rb
composite_primary_keys-8.1.7 test/fixtures/product_tariff.rb