From 7e7534041ee0faaa6089f0dc6e232a231bd87074 Mon Sep 17 00:00:00 2001 From: huangjingquan Date: Mon, 4 Nov 2013 09:57:36 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AF=BE=E7=A8=8B=E5=88=97=E8=A1=A8=E6=96=B0?= =?UTF-8?q?=E7=9A=84=E6=9D=83=E9=99=90=E8=AE=BE=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/users/_course_form.html.erb | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/app/views/users/_course_form.html.erb b/app/views/users/_course_form.html.erb index 072ca67b3..b521dfdba 100644 --- a/app/views/users/_course_form.html.erb +++ b/app/views/users/_course_form.html.erb @@ -9,17 +9,17 @@
<%= link_to_project(membership.project) %> - - - + <% if User.current == @user %> - <% unless membership.roles.first.to_s == 'Manager' %> + <% (membership.roles).each do |role| %> + <% unless (role == Role.find(9) || role == Role.find(3)) %> <%= join_in_course(membership.project, User.current)%>     <% end %> - <% else %> - <% end %> + <% else %> + <% end %> + <%= l(:label_x_base_courses_member, :count => membership.project.members.count) %>(<%= link_to "#{membership.project.members.count}", project_member_path(membership.project), :course =>'1' %>)   <%= l(:label_homework) %> (<%= link_to (membership.project.homeworks.count), {:controller => 'projects', :action => 'homework', :id => membership.project.identifier} %>)