From bc9051422844c706b18fddc1449ea5e311c83490 Mon Sep 17 00:00:00 2001 From: "yuuji.yaginuma" Date: Sun, 11 Jun 2017 16:21:32 +0900 Subject: Generate field ids in `collection_check_boxes` and `collection_radio_buttons` This makes sure that the labels are linked up with the fields. Fixes #29014 --- actionview/lib/action_view/helpers/tags/collection_check_boxes.rb | 1 + 1 file changed, 1 insertion(+) (limited to 'actionview/lib/action_view/helpers/tags/collection_check_boxes.rb') diff --git a/actionview/lib/action_view/helpers/tags/collection_check_boxes.rb b/actionview/lib/action_view/helpers/tags/collection_check_boxes.rb index 7252d4f2d9..e02b7bdb2e 100644 --- a/actionview/lib/action_view/helpers/tags/collection_check_boxes.rb +++ b/actionview/lib/action_view/helpers/tags/collection_check_boxes.rb @@ -10,6 +10,7 @@ module ActionView def check_box(extra_html_options = {}) html_options = extra_html_options.merge(@input_html_options) html_options[:multiple] = true + html_options[:skip_default_ids] = false @template_object.check_box(@object_name, @method_name, html_options, @value, nil) end end -- cgit v1.2.3