1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/activerecord/test/models/owner.rb
Jim Remsik and Tim Pope 1e6c50e21b Ensure has_many :through works with changed primary keys [#736 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-03-09 13:43:28 +00:00

5 lines
118 B
Ruby

class Owner < ActiveRecord::Base
set_primary_key :owner_id
has_many :pets
has_many :toys, :through => :pets
end