From adebdc835f0f329cd337c2a69e6d7cdcce8921b9 Mon Sep 17 00:00:00 2001 From: Toshi MARUYAMA Date: Fri, 9 Aug 2013 00:42:24 +0000 Subject: [PATCH] code format cleanup app/views/projects/settings/_members.html.erb git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@12099 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/views/projects/settings/_members.html.erb | 68 +++++++++++-------- 1 file changed, 41 insertions(+), 27 deletions(-) diff --git a/app/views/projects/settings/_members.html.erb b/app/views/projects/settings/_members.html.erb index dc8d1e483..6cb21002d 100644 --- a/app/views/projects/settings/_members.html.erb +++ b/app/views/projects/settings/_members.html.erb @@ -18,19 +18,29 @@ <%= link_to_user member.principal %> <%= member.roles.sort.collect(&:to_s).join(', ') %> - <%= form_for(member, {:as => :membership, :remote => true, :url => membership_path(member), - :method => :put, - :html => { :id => "member-#{member.id}-roles-form", :class => 'hol' }} + <%= form_for(member, + {:as => :membership, :remote => true, + :url => membership_path(member), + :method => :put, + :html => { :id => "member-#{member.id}-roles-form", :class => 'hol' }} ) do |f| %> -

<% roles.each do |role| %> -
- <% end %>

+

+ <% roles.each do |role| %> +
+ <% end %> +

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

<%= submit_tag l(:button_save), :class => "small" %> - <%= link_to_function l(:button_cancel), - "$('#member-#{member.id}-roles').show(); $('#member-#{member.id}-roles-form').hide(); return false;" - %>

+

+ <%= submit_tag l(:button_save), :class => "small" %> + <%= link_to_function(l(:button_cancel), + "$('#member-#{member.id}-roles').show(); $('#member-#{member.id}-roles-form').hide(); return false;") %> +

<% end %> @@ -53,22 +63,26 @@
<% if roles.any? %> - <%= form_for(@member, {:as => :membership, :url => project_memberships_path(@project), :remote => true, :method => :post}) do |f| %> -
<%=l(:label_member_new)%> - -

<%= label_tag "principal_search", l(:label_principal_search) %><%= text_field_tag 'principal_search', nil %>

- <%= javascript_tag "observeSearchfield('principal_search', null, '#{ escape_javascript autocomplete_project_memberships_path(@project, :format => 'js') }')" %> - -
- <%= render_principals_for_new_members(@project) %> -
- -

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

- -

<%= submit_tag l(:button_add), :id => 'member-add-submit' %>

+ <%= form_for(@member, + {:as => :membership, :url => project_memberships_path(@project), + :remote => true, :method => :post}) do |f| %> +
+ <%=l(:label_member_new)%> +

+ <%= label_tag("principal_search", l(:label_principal_search)) %> + <%= text_field_tag('principal_search', nil) %> +

+ <%= javascript_tag "observeSearchfield('principal_search', null, '#{ escape_javascript autocomplete_project_memberships_path(@project, :format => 'js') }')" %> +
+ <%= render_principals_for_new_members(@project) %> +
+

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

+

<%= submit_tag l(:button_add), :id => 'member-add-submit' %>

<% end %> <% end %>