socialforge/app/views/layouts/_join_exit_project.html.erb

17 lines
701 B
Plaintext
Raw Normal View History

<div class="pr_info_join fl">
<!--关注项目-->
<% if ( !(User.current.member_of? @project) && User.current.login?) %> <!--added by linchun-->
<span><%= watcher_link_for_project(@project, User.current) %></span>
<% end %>
<!--加入项目 -->
<% if ( !(User.current.member_of? @project) && User.current.login?) %>
<%= join_in_project_link(@project, User.current) %>
<% end %>
<!--退出项目-->
<% if ((User.current.member_of? @project) &&
User.current.login? &&
Member.where(:user_id => User.current.id, :project_id=>@project.id).first.roles.first.to_s != "Manager") %>
<%= exit_project_link(@project) %>
<% end %>
</div>