From 2ce07955c1191f92f2e1f7874de59afbfaad15de Mon Sep 17 00:00:00 2001
From: sw <939547590@qq.com>
Date: Mon, 29 Sep 2014 16:59:36 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=AF=BE=E7=A8=8B=E8=A7=92?=
=?UTF-8?q?=E8=89=B2=E4=B8=8D=E8=83=BD=E4=BF=AE=E6=94=B9=E7=9A=84BUG?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app/views/courses/settings/_members.html.erb | 43 +++++++-------------
1 file changed, 15 insertions(+), 28 deletions(-)
diff --git a/app/views/courses/settings/_members.html.erb b/app/views/courses/settings/_members.html.erb
index 1d8b059c7..f685e4543 100644
--- a/app/views/courses/settings/_members.html.erb
+++ b/app/views/courses/settings/_members.html.erb
@@ -20,34 +20,25 @@
<% members.each do |member| %>
<% next if member.new_record? %>
-
- <%= link_to_user member.principal %>
- |
+ <%= link_to_user member.principal %> |
<%= h member.roles.sort.collect(&:to_s).join(', ') %>
- <%= form_for(member, {:as => :membership, :remote => true,
- :url => course_memberships_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 %>
-
+
+ <% end %>
<%= hidden_field_tag 'membership[role_ids][]', '' %>
-
- <%= submit_tag l(:button_change), :class => "small" %>
+ <%= submit_tag l(:button_change), :class => "small" %>
<%= link_to_function l(:button_cancel),
"$('#member-#{member.id}-roles').show(); $('#member-#{member.id}-roles-form').hide(); return false;"
- %>
-
+ %>
<% end %>
|
@@ -79,10 +70,8 @@
<%= form_for(@member, {:as => :membership, :url => course_memberships_path(@course), :remote => true, :method => :post}) do |f| %>