Files
rails/activerecord/test/models/essay.rb
Szymon Nowak b3ec7b2d03 Add primary_key option to belongs_to association
[#765 state:committed]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-07-15 18:14:00 -07:00

4 lines
103 B
Ruby

class Essay < ActiveRecord::Base
belongs_to :writer, :primary_key => :name, :polymorphic => true
end