diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2019-10-19 12:14:21 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2019-10-19 12:14:21 +0000 |
commit | 49b96a935b3fb34a8cea07b723d9af55a415e13b (patch) | |
tree | a42962b4d3efbbe51f4a347d0d720f5b529b359f /app/helpers/queries_helper.rb | |
parent | 95188f26c3f47f110c6d928e5df0b108802032b3 (diff) | |
download | redmine-49b96a935b3fb34a8cea07b723d9af55a415e13b.tar.gz redmine-49b96a935b3fb34a8cea07b723d9af55a415e13b.zip |
Use radio buttons to choose display type (#29482).
git-svn-id: http://svn.redmine.org/redmine/trunk@18767 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/helpers/queries_helper.rb')
-rw-r--r-- | app/helpers/queries_helper.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/app/helpers/queries_helper.rb b/app/helpers/queries_helper.rb index 9ed2dd21d..88fe08b50 100644 --- a/app/helpers/queries_helper.rb +++ b/app/helpers/queries_helper.rb @@ -121,11 +121,12 @@ module QueriesHelper end def available_display_types_tags(query) - available_display_types = [] + tags = ''.html_safe query.available_display_types.each do |t| - available_display_types << [l(:"label_display_type_#{t}"), t] + tags << radio_button_tag('display_type', t, @query.display_type == t, :id => "display_type_#{t}") + + content_tag('label', l(:"label_display_type_#{t}"), :for => "display_type_#{t}") end - select_tag('display_type', options_for_select(available_display_types, @query.display_type), :id => 'display_type') + tags end def grouped_query_results(items, query, &block) |