From 896058b485653bc8a1b5ccbc1248267880a8c911 Mon Sep 17 00:00:00 2001 From: Pratik Naik Date: Wed, 22 Oct 2008 23:09:48 +0530 Subject: Merge with docrails --- railties/doc/guides/html/association_basics.html | 32 ++++++++++++------------ 1 file changed, 16 insertions(+), 16 deletions(-) (limited to 'railties/doc/guides/html/association_basics.html') diff --git a/railties/doc/guides/html/association_basics.html b/railties/doc/guides/html/association_basics.html index de84551aef..012a1a0156 100644 --- a/railties/doc/guides/html/association_basics.html +++ b/railties/doc/guides/html/association_basics.html @@ -433,7 +433,7 @@ http://www.gnu.org/software/src-highlite -->
-Note +Note The name of the other model is pluralized when declaring a has_many association.
@@ -573,7 +573,7 @@ http://www.gnu.org/software/src-highlite -->
-Note +Note Using t.integer :supplier_id makes the foreign key naming obvious and implicit. In current versions of Rails, you can abstract away this implementation detail by using t.references :supplier instead.
@@ -777,7 +777,7 @@ http://www.gnu.org/software/src-highlite -->
-Warning +Warning The precedence between model names is calculated using the < operator for String. This means that if the strings are of different lengths, and the strings are equal when compared up to the shortest length, then the longer string is considered of higher lexical precedence than the shorter one. For example, one would expect the tables "paper_boxes" and "papers" to generate a join table name of "papers_paper_boxes" because of the length of the name "paper_boxes", but it in fact generates a join table name of "paper_boxes_papers".
@@ -1112,7 +1112,7 @@ http://www.gnu.org/software/src-highlite -->
-Warning +Warning You should not specify this option on a belongs_to association that is connected with a has_many association on the other class. Doing so can lead to orphaned records in your database.
@@ -1131,7 +1131,7 @@ http://www.gnu.org/software/src-highlite -->
-Tip +Tip In any case, Rails will not create foreign key columns for you. You need to explicitly define them as part of your migrations.
@@ -1174,7 +1174,7 @@ http://www.gnu.org/software/src-highlite -->
-Note +Note There's no need to use :include for immediate associations - that is, if you have Order belongs_to :customer, then the customer is eager-loaded automatically when it's needed.
@@ -1414,7 +1414,7 @@ http://www.gnu.org/software/src-highlite -->
-Tip +Tip In any case, Rails will not create foreign key columns for you. You need to explicitly define them as part of your migrations.
@@ -1606,7 +1606,7 @@ http://www.gnu.org/software/src-highlite -->
-Warning +Warning Objects will be in addition destroyed if they're associated with :dependent ⇒ :destroy, and deleted if they're associated with :dependent ⇒ :delete_all.
@@ -1834,7 +1834,7 @@ http://www.gnu.org/software/src-highlite -->
-Note +Note If you specify :finder_sql but not :counter_sql, then the counter SQL will be generated by substituting SELECT COUNT(*) FROM for the SELECT … FROM clause of your :finder_sql statement.
@@ -1844,7 +1844,7 @@ http://www.gnu.org/software/src-highlite -->
-Note +Note This option is ignored when you use the :through option on the association.
@@ -1867,7 +1867,7 @@ http://www.gnu.org/software/src-highlite -->
-Tip +Tip In any case, Rails will not create foreign key columns for you. You need to explicitly define them as part of your migrations.
@@ -1951,7 +1951,7 @@ http://www.gnu.org/software/src-highlite -->
-Warning +Warning If you specify your own :select, be sure to include the primary key and foreign key columns of the associated model. If you do not, Rails will throw an error.
@@ -2077,7 +2077,7 @@ assemblies.create
-Warning +Warning The use of extra attributes on the join table in a has_and_belongs_to_many association is deprecated. If you require this sort of complex behavior on the table that joins two models in a many-to-many relationship, you should use a has_many :through association instead of has_and_belongs_to_many.
@@ -2103,7 +2103,7 @@ http://www.gnu.org/software/src-highlite -->
-Note +Note This method is aliased as collection.concat and collection.push.
@@ -2296,7 +2296,7 @@ http://www.gnu.org/software/src-highlite -->
-Tip +Tip The :foreign_key and :association_foreign_key options are useful when setting up a many-to-many self-join. For example:
@@ -2349,7 +2349,7 @@ http://www.gnu.org/software/src-highlite -->
-Note +Note If you specify :finder_sql but not :counter_sql, then the counter SQL will be generated by substituting SELECT COUNT(*) FROM for the SELECT … FROM clause of your :finder_sql statement.
-- cgit v1.2.3