From: Jean-Philippe Lang Date: Sat, 11 Jan 2014 12:45:19 +0000 (+0000) Subject: Removes duplicate ids (#15485). X-Git-Tag: 2.5.0~245 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=f4f3756fcc5e8aebeaa3bb1f8e1c747a0886d52d;p=redmine.git Removes duplicate ids (#15485). git-svn-id: http://svn.redmine.org/redmine/trunk@12654 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/views/users/_memberships.html.erb b/app/views/users/_memberships.html.erb index 5f61d2ce2..c0d8051ae 100644 --- a/app/views/users/_memberships.html.erb +++ b/app/views/users/_memberships.html.erb @@ -25,7 +25,8 @@ :style => 'display:none;'}) do %>

<% roles.each do |role| %>
+ :disabled => membership.member_roles.detect {|mr| mr.role_id == role.id && !mr.inherited_from.nil?}, + :id => nil %> <%=h role %>
<% end %>

<%= hidden_field_tag 'membership[role_ids][]', '' %>

<%= submit_tag l(:button_change) %> @@ -58,7 +59,7 @@ <%= select_tag 'membership[project_id]', options_for_membership_project_select(@user, projects) %>

<%= l(:label_role_plural) %>: <% roles.each do |role| %> - + <% end %>

<%= submit_tag l(:button_add) %>

<% end %>