Sha256: 636bef4a597f52a71115de1d34444952f1bb22d4e812928865e0b6a5f520a88c

Contents?: true

Size: 246 Bytes

Versions: 2

Compression:

Stored size: 246 Bytes

Contents

# frozen_string_literal: true

class Customer < ActiveRecord::Base
  unless ENV["SKIP_COMPOSITE_PK"]
    has_many :orders,
      inverse_of: :customer,
      primary_key: %i(account_id id),
      foreign_key: %i(account_id customer_id)
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
activerecord-import-1.6.0 test/models/customer.rb
activerecord-import-1.5.1 test/models/customer.rb