diff options
author | José Valim <jose.valim@gmail.com> | 2011-09-04 00:28:15 -0700 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2011-09-04 00:28:15 -0700 |
commit | 036a25019d79565a6016cb60c520816916bb7de6 (patch) | |
tree | 89be5ca60d3a33eb795f22ddc03647750c61ca5c /actionpack/CHANGELOG | |
parent | 0eefd8dc4884217e70ed99fb7d8ae272c7ce2d12 (diff) | |
parent | b84cee08c6129717d7c3291918f06f95cc9eb916 (diff) | |
download | rails-036a25019d79565a6016cb60c520816916bb7de6.tar.gz rails-036a25019d79565a6016cb60c520816916bb7de6.tar.bz2 rails-036a25019d79565a6016cb60c520816916bb7de6.zip |
Merge pull request #2816 from sikachu/content_tag_for
Make `content_tag_for` and `div_for` accepts the array of records
Diffstat (limited to 'actionpack/CHANGELOG')
-rw-r--r-- | actionpack/CHANGELOG | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/actionpack/CHANGELOG b/actionpack/CHANGELOG index 31a03ea5d8..285ab05103 100644 --- a/actionpack/CHANGELOG +++ b/actionpack/CHANGELOG @@ -1,5 +1,21 @@ *Rails 3.2.0 (unreleased)* +* content_tag_for and div_for can now take the collection of records. It will also yield the record as the first argument if you set a receiving argument in your block [Prem Sichanugrist] + + So instead of having to do this: + + @items.each do |item| + content_tag_for(:li, item) do + Title: <%= item.title %> + end + end + + You can now do this: + + content_tag_for(:li, @items) do |item| + Title: <%= item.title %> + end + * send_file now guess the mime type [Esad Hajdarevic] * Mime type entries for PDF, ZIP and other formats were added [Esad Hajdarevic] |