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/views | |
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/views')
-rw-r--r-- | app/views/queries/_query_form.html.erb | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/app/views/queries/_query_form.html.erb b/app/views/queries/_query_form.html.erb index 62d156684..bb29827f8 100644 --- a/app/views/queries/_query_form.html.erb +++ b/app/views/queries/_query_form.html.erb @@ -21,7 +21,7 @@ <%= available_display_types_tags(@query) %> </div> <% end %> - <table id="list" class="<%= 'hidden' if (@query.display_type == 'board') %>"> + <table id="list-definition" class="<%= 'hidden' if (@query.display_type != 'list') %>"> <% if @query.available_columns.any? %> <tr> <td class="field"><%= l(:field_column_names) %></td> @@ -74,12 +74,11 @@ <%= javascript_tag do %> $(function ($) { - $('#display_type').change(function (e) { - var option = $(e.target).val() - if (option == 'board') { - $('table#list').hide(); + $('input[name=display_type]').change(function (e) { + if ($("#display_type_list").is(':checked')) { + $('table#list-definition').show(); } else { - $('table#list').show(); + $('table#list-definition').hide(); } }) |