Commit Graph

8 Commits

Author SHA1 Message Date
Jeremy Kemper 390e6d246c r2915@asus: jeremy | 2005-11-06 05:02:53 -0800
Rename Base.constrain to Base.with_scope so it doesn't conflict with existing concept of database constraints.  Make scoping more robust: uniform method => parameters, validated method names and supported finder parameters, raise exception on nested scopes.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2888 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-11-06 10:18:51 +00:00
David Heinemeier Hansson a5a82d978b Added extension capabilities to has_many and has_and_belongs_to_many proxies [DHH] Added find_or_create_by_X as a second type of dynamic finder that'll create the record if it doesn't already exist [DHH] Added constrain scoping for creates using a hash of attributes bound to the :creation key [DHH]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2872 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-11-04 19:39:50 +00:00
Jeremy Kemper e7cd7e9d95 r3800@sedna: jeremy | 2005-10-28 00:39:05 -0700
Readonly constraints, association collection method_missing, dup constraint options


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2774 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-10-28 04:53:22 +00:00
Jeremy Kemper 17d3fd3165 r2736@asus: jeremy | 2005-10-24 17:08:12 -0700
Test for eager associations with limits should not assume that records are ordered by id.
 r2737@asus:  jeremy | 2005-10-24 19:06:09 -0700
 Fail fast if invalid primary key column.
 r2746@asus:  jeremy | 2005-10-25 15:37:28 -0700
 Begin rollback of fixture delete order.  Its solves a problem for 1% of users who already have a workaround while severely slowing down the other 99%.
 r2747@asus:  jeremy | 2005-10-25 16:03:01 -0700
 Rollback the rest.
 r2748@asus:  jeremy | 2005-10-25 16:06:26 -0700
 Re-add fixtures declaration to conditions scoping test
 r2749@asus:  jeremy | 2005-10-25 16:09:03 -0700
 Re-add fixtures declaration to finder test
 r2750@asus:  jeremy | 2005-10-25 16:13:50 -0700
 Don't assume keyboards table is empty


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2730 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-10-25 18:14:09 +00:00
Jeremy Kemper a2f0ae76d1 r2718@asus: jeremy | 2005-10-23 14:45:30 -0700
Ticket 2404 - fixture delete order
 r2719@asus:  jeremy | 2005-10-23 15:01:13 -0700
 Keep closer tabs on dirty, loaded, and declared fixtures.  Closes #2404.
 r2720@asus:  jeremy | 2005-10-23 16:09:19 -0700
 ensure table names are strings.  set dirty = dirty union loaded rather than dirty = loaded.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2714 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-10-23 19:02:38 +00:00
Marcel Molina f4d1af3085 Fix typo of 'constrains' to 'contraints'. Closes #2069.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2510 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-10-09 22:08:16 +00:00
Marcel Molina e8b427cdef Raise an exception when invalid options are passed to ActiveRecord::Base.find. Closes #2363.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2481 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-10-06 22:21:10 +00:00
David Heinemeier Hansson 34f9d30e39 Added support for calling constrained class methods on has_many and has_and_belongs_to_many collections #1764 [Tobias Luetke]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1894 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-07-22 20:05:42 +00:00