diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2013-06-16 09:35:18 -0700 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2013-06-16 09:35:18 -0700 |
commit | 0f89689b2357f39da52515b83391db58689a1361 (patch) | |
tree | c9b954ec5da7c225e65992f83f5e33af4ac59419 /actionpack/lib/action_view/helpers | |
parent | 76462a8543b7feac6b2957cf2c0724b30775c3c7 (diff) | |
parent | 782cee5377dda1f8f0f84988c3959a06aa884d95 (diff) | |
download | rails-0f89689b2357f39da52515b83391db58689a1361.tar.gz rails-0f89689b2357f39da52515b83391db58689a1361.tar.bz2 rails-0f89689b2357f39da52515b83391db58689a1361.zip |
Merge pull request #10964 from nashby/collection-html-options
collection tags accept html attributes as the last element of collection
Diffstat (limited to 'actionpack/lib/action_view/helpers')
-rw-r--r-- | actionpack/lib/action_view/helpers/tags/collection_helpers.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/actionpack/lib/action_view/helpers/tags/collection_helpers.rb b/actionpack/lib/action_view/helpers/tags/collection_helpers.rb index cd12ddaf65..388dcf1f13 100644 --- a/actionpack/lib/action_view/helpers/tags/collection_helpers.rb +++ b/actionpack/lib/action_view/helpers/tags/collection_helpers.rb @@ -73,8 +73,9 @@ module ActionView value = value_for_collection(item, @value_method) text = value_for_collection(item, @text_method) default_html_options = default_html_options_for_collection(item, value) + additional_html_options = option_html_attributes(item) - yield item, value, text, default_html_options + yield item, value, text, default_html_options.merge(additional_html_options) end.join.html_safe end end |