aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/CHANGELOG.md
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2012-09-28 14:10:38 -0300
committerRafael Mendonça França <rafaelmfranca@gmail.com>2012-09-28 14:12:17 -0300
commit77fbe1c0199567486c422fdf5cce49f2c11fc953 (patch)
treea5cf954f43573ae0f6954f33deb0d8c6510200ee /activerecord/CHANGELOG.md
parentd14da793340ca49c0049257af892a204cba43092 (diff)
downloadrails-77fbe1c0199567486c422fdf5cce49f2c11fc953.tar.gz
rails-77fbe1c0199567486c422fdf5cce49f2c11fc953.tar.bz2
rails-77fbe1c0199567486c422fdf5cce49f2c11fc953.zip
Add missing CHANGELOG entry removed by mistake at 7f3b475 [ci skip]
Diffstat (limited to 'activerecord/CHANGELOG.md')
-rw-r--r--activerecord/CHANGELOG.md31
1 files changed, 20 insertions, 11 deletions
diff --git a/activerecord/CHANGELOG.md b/activerecord/CHANGELOG.md
index b6ad6f82d8..67bec5f38e 100644
--- a/activerecord/CHANGELOG.md
+++ b/activerecord/CHANGELOG.md
@@ -13,17 +13,6 @@
*Jon Leighton*
-* Added `#update_columns` method which updates the attributes from
- the passed-in hash without calling save, hence skipping validations and
- callbacks. `ActiveRecordError` will be raised when called on new objects
- or when at least one of the attributes is marked as read only.
-
- post.attributes # => {"id"=>2, "title"=>"My title", "body"=>"My content", "author"=>"Peter"}
- post.update_columns({title: 'New title', author: 'Sebastian'}) # => true
- post.attributes # => {"id"=>2, "title"=>"New title", "body"=>"My content", "author"=>"Sebastian"}
-
- *Sebastian Martinez*
-
* Allow before and after validations to take an array of lifecycle events
*John Foley*
@@ -312,6 +301,15 @@
*Jon Leighton*
+* `Relation#order`: make new order prepend old one.
+
+ User.order("name asc").order("created_at desc")
+ # SELECT * FROM users ORDER BY created_at desc, name asc
+
+ This also affects order defined in `default_scope` or any kind of associations.
+
+ *Bogdan Gusiev*
+
* `Model.all` now returns an `ActiveRecord::Relation`, rather than an
array of records. Use `Relation#to_a` if you really want an array.
@@ -341,6 +339,17 @@
*Jon Leighton*
+* Added `#update_columns` method which updates the attributes from
+ the passed-in hash without calling save, hence skipping validations and
+ callbacks. `ActiveRecordError` will be raised when called on new objects
+ or when at least one of the attributes is marked as read only.
+
+ post.attributes # => {"id"=>2, "title"=>"My title", "body"=>"My content", "author"=>"Peter"}
+ post.update_columns(title: 'New title', author: 'Sebastian') # => true
+ post.attributes # => {"id"=>2, "title"=>"New title", "body"=>"My content", "author"=>"Sebastian"}
+
+ *Sebastian Martinez + Rafael Mendonça França*
+
* The migration generator now creates a join table with (commented) indexes every time
the migration name contains the word `join_table`: