aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
Commit message (Collapse)AuthorAgeFilesLines
* Define collection singular ids method for has_many :through associations. ↵Jeremy Kemper2007-06-273-7/+18
| | | | | | Closes #8763. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7137 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Array attribute conditions work with proxied association collections. Closes ↵Jeremy Kemper2007-06-273-2/+8
| | | | | | #8318. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7133 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Allow sweepers to be created solely for expiring after controller actions, ↵David Heinemeier Hansson2007-06-261-3/+7
| | | | | | not model changes [DHH] Added assigns method to ActionController::Caching::Sweeper to easily access instance variables on the controller [DHH] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7128 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix polymorphic has_one associations declared in an abstract class. Closes ↵Jeremy Kemper2007-06-257-12/+37
| | | | | | #8638. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7119 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Docfix (closes #8096)David Heinemeier Hansson2007-06-231-3/+15
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7107 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Docfix (closes #8674)David Heinemeier Hansson2007-06-231-2/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7101 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed validates_associated should not stop on the first error (closes #4276) ↵David Heinemeier Hansson2007-06-233-5/+9
| | | | | | [mrj/manfred/josh] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7094 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Mock the beginning of the transaction also. References #8642.Jeremy Kemper2007-06-232-1/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7089 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Rollback if commit raises an exception. Closes #8642.Jeremy Kemper2007-06-233-12/+33
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7088 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Update tests' use of fixtures for the new collections api. Closes #8726.Jeremy Kemper2007-06-226-122/+57
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7081 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Save associated records only if the association is already loaded. Closes #8713.Jeremy Kemper2007-06-213-4/+14
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7075 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* MySQL: fix show_variable. Closes #8448.Jeremy Kemper2007-06-203-3/+14
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7071 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* remove extra debug line. Closes #8681 [Giles Bowkett]Rick Olson2007-06-181-1/+0
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7059 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Remove deprecated quote methods, replaced by quote_value so quote can be ↵Jeremy Kemper2007-06-111-12/+0
| | | | | | used as an attribute name. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7000 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Remove deprecated find_first and find_all.Jeremy Kemper2007-06-119-248/+36
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6998 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Remove deprecated push_with_attributes.Jeremy Kemper2007-06-113-204/+134
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6997 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix Base#inspect when not every attribute is present. Closes #8623.Jeremy Kemper2007-06-113-4/+10
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6995 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Rollback [6961] which breaks SQLite tests. Reference #7345.Jeremy Kemper2007-06-083-20/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6965 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Quote db path so SQLite AR tests work on Windows. Closes #5278 ↵Jeremy Kemper2007-06-082-2/+2
| | | | | | [mislav@nippur.irb.hr] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6964 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Migrations: raise if a column is duplicated. Closes #7345.Jeremy Kemper2007-06-073-1/+20
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6961 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Migrations: report the number of rows affected when calling insert, update, ↵Jeremy Kemper2007-06-051-0/+1
| | | | | | delete, etc. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6945 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixtures: correctly delete and insert fixtures in a single transaction. ↵Jeremy Kemper2007-06-052-1/+3
| | | | | | Closes #8553. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6944 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix typo. Closes #7504 [aurelianito]Jeremy Kemper2007-06-051-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6943 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixtures: people(:technomancy, :josh) returns both fixtures. Closes #7880.Jeremy Kemper2007-06-054-11/+32
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6940 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Calculations support non-numeric foreign keys. Closes #8154.Jeremy Kemper2007-06-013-1/+24
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6919 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Base.inspect handles Base itself and abstract_class? Don't use #<Foo ...> ↵Jeremy Kemper2007-05-312-5/+18
| | | | | | since that notation's typically used for instances of a class, not the class itself. Closes #8490 [deepblue] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6913 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix an edge case with find with a list of ids, limit, and offset. Closes #8437.Jeremy Kemper2007-05-312-4/+13
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6912 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* with_scope is protected. Closes #8524.Jeremy Kemper2007-05-306-92/+111
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6909 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Quickref for association methods. Closes #7723.Jeremy Kemper2007-05-302-3/+42
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6905 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Calculations: return nil average instead of 0 when there are no rows to ↵Jeremy Kemper2007-05-303-1/+11
| | | | | | average. Closes #8298. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6904 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* acts_as_nested_set: direct_children is sorted correctly. Closes #4761.Jeremy Kemper2007-05-304-10/+13
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6903 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Raise an exception if both attr_protected and attr_accessible are declared. ↵Jeremy Kemper2007-05-293-0/+16
| | | | | | Closes #8507, #6004. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6896 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Workaround test isolation failure with Task.attr_protected :starting.Jeremy Kemper2007-05-291-1/+5
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6892 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Typo in PostgreSQL change_column quoting. References #8466.Jeremy Kemper2007-05-291-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6891 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Missed Oracle rename_column quoting. References #8466.Jeremy Kemper2007-05-291-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6890 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* SQLite, MySQL, PostgreSQL, Oracle: quote column names in column migration ↵Jeremy Kemper2007-05-296-15/+33
| | | | | | SQL statements. Closes #8466. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6889 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Generate rdoc with utf-8 charset. Closes #7188 [manfred, jferris]Jeremy Kemper2007-05-281-0/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6881 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Allow nil serialized attributes with a set class constraint. #7293 [sandofsky]Rick Olson2007-05-283-6/+21
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6879 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Test that DateTime are quoted as DateTime not Date. Closes #8364 [chas]Jeremy Kemper2007-05-281-1/+7
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6878 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Oracle binary fixtures; pull fixture insertion into the adapters. Closes #7987.Jeremy Kemper2007-05-265-12/+40
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6859 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Announce migration versions as they're performed.Jeremy Kemper2007-05-262-35/+43
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6855 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* find gracefully copes with blank :conditions. Closes #7599.Jeremy Kemper2007-05-263-3/+18
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6852 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* validates_numericality_of takes :greater_than, :greater_than_or_equal_to, ↵Jeremy Kemper2007-05-263-15/+118
| | | | | | :equal_to, :less_than, :less_than_or_equal_to, :odd, and :even options. Closes #3952. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6850 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* MySQL: create_database takes :charset and :collation options. Charset ↵Jeremy Kemper2007-05-264-20/+66
| | | | | | defaults to utf8. References #8448. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6848 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Test that #to_xml takes a block. Closes #8471. [seth]Jeremy Kemper2007-05-251-0/+9
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6847 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Typo in [6845]. References #8437.Jeremy Kemper2007-05-251-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6846 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Find with a list of ids supports limit/offset. Closes #8437.Jeremy Kemper2007-05-253-48/+64
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6845 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Optimistic locking: revert the lock version when an update fails. Closes ↵Jeremy Kemper2007-05-253-16/+39
| | | | | | #7840. Also return the number of affected rows instead of true. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6843 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Migrations: add_column supports custom column types. Closes #7742. ↵Jeremy Kemper2007-05-253-14/+33
| | | | | | First-patch cheers to jsgarvin\! git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6842 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Test reconnection after MySQL client timeout. References #428.Jeremy Kemper2007-05-252-2/+32
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6838 5ecf4fe2-1ee6-0310-87b1-e25e094e27de