aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/associations/has_one_through_association.rb
Commit message (Collapse)AuthorAgeFilesLines
* use persisted? instead of new_record? wherever possibleDavid Chelimsky2010-11-091-1/+1
| | | | | | | | | | | - persisted? is the API defined in ActiveModel - makes it easier for extension libraries to conform to ActiveModel APIs without concern for whether the extended object is specifically ActiveRecord [#5927 state:committed] Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
* Refactoring: replace the mix of variables like @finder_sql, @counter_sql, ↵Jon Leighton2010-10-301-1/+1
| | | | etc with just a single scope hash (created on initialization of the proxy). This is now used consistently across all associations. Therefore, all you have to do to ensure finding/counting etc is done correctly is implement the scope correctly.
* Adds title to activerecord/lib/active_record/associations/*Rizwan Reza2010-06-161-0/+1
|
* Allow ho:through#build when the owner is a new record [#1749 state:resolved]Tristan Dunn2009-08-101-3/+9
| | | | Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* HasOneThroughAssociation still shouldn't derive from HasManyThroughAssociation.Adam Milligan2009-06-121-10/+12
| | | | | | [#1642 state:committed] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
* has_one :through should not create a new association when assigned nil [#698 ↵Daniel Guettler2009-05-171-8/+8
| | | | | | state:resolved] Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* fix assignment to has_one :through associations.Matt Jones2008-11-151-4/+3
| | | | Signed-off-by: Michael Koziarski <michael@koziarski.com>
* Fix two has_one :through errorspivotal2008-08-271-0/+4
| | | | | | | | * Set the association target on assignment; * Reset target to nil on reset, rather than empty array. Signed-off-by: Michael Koziarski <michael@koziarski.com> [#895 state:committed]
* Remove duplicate code from associations. [Pratik]Pratik Naik2008-04-061-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@9231 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Add has_one :through support, finally. Closes #4756 [thechrisoshow]Rick Olson2008-03-211-0/+28
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@9067 5ecf4fe2-1ee6-0310-87b1-e25e094e27de