Commit Graph

6 Commits

Author SHA1 Message Date
Graeme Porteous c01be9de32 Fix has_one with foreign_key and primary_key association bug which caused the associated object being lost when saving the owner. [#1756 state:resolved]
Mixed in a bit from patch by ransom-briggs. [#2813 state:resolved]

Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com>
2009-09-12 16:03:32 +02:00
Jeremy Kemper 3704088ebd has_one supports the :dependent => :delete option which skips the typical callback chain and deletes the associated object directly from the database. Closes #5927.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4848 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2006-08-29 17:06:27 +00:00
David Heinemeier Hansson 99307b959b Added calculations: Base.count, Base.average, Base.sum, Base.minimum, Base.maxmium, and the generic Base.calculate. All can be used with :group and :having. Calculations and statitics need no longer require custom SQL. #3958 [Rick Olson]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3646 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2006-02-25 23:06:04 +00:00
Marcel Molina 297618bddc Make dynamic finders honor additional passed in :conditions. Closes #3569.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3463 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2006-01-22 09:34:41 +00:00
Tobias Lütke 7086993161 Adds :nullify option to :depends. Closes #2015 (Robby Russell)
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2595 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-10-15 00:46:55 +00:00
David Heinemeier Hansson db045dbbf6 Initial
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2004-11-24 01:04:44 +00:00