From 886124e688de7b48f32925eca42e4185e487ec84 Mon Sep 17 00:00:00 2001 From: Pratik Naik Date: Sun, 1 Feb 2009 18:25:03 +0000 Subject: Merge docrails --- activerecord/lib/active_record/associations.rb | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'activerecord/lib/active_record') diff --git a/activerecord/lib/active_record/associations.rb b/activerecord/lib/active_record/associations.rb index 7a88465f8c..3f2b5d726e 100755 --- a/activerecord/lib/active_record/associations.rb +++ b/activerecord/lib/active_record/associations.rb @@ -1166,11 +1166,12 @@ module ActiveRecord # [:foreign_key] # Specify the foreign key used for the association. By default this is guessed to be the name # of this class in lower-case and "_id" suffixed. So a Person class that makes a +has_and_belongs_to_many+ association - # will use "person_id" as the default :foreign_key. + # to Project will use "person_id" as the default :foreign_key. # [:association_foreign_key] - # Specify the association foreign key used for the association. By default this is - # guessed to be the name of the associated class in lower-case and "_id" suffixed. So if the associated class is Project, - # the +has_and_belongs_to_many+ association will use "project_id" as the default :association_foreign_key. + # Specify the foreign key used for the association on the receiving side of the association. + # By default this is guessed to be the name of the associated class in lower-case and "_id" suffixed. + # So if a Person class makes a +has_and_belongs_to_many+ association to Project, + # the association will use "project_id" as the default :association_foreign_key. # [:conditions] # Specify the conditions that the associated object must meet in order to be included as a +WHERE+ # SQL fragment, such as authorized = 1. Record creations from the association are scoped if a hash is used. -- cgit v1.2.3