2015-03-06 14:55:21 +08:00
|
|
|
<div class="pr_info_join fl">
|
2015-04-27 16:54:46 +08:00
|
|
|
<!--关注:非项目成员-->
|
|
|
|
<% if !User.current.member_of?(@project) && User.current.login? && !User.current.admin %>
|
2015-03-20 15:02:20 +08:00
|
|
|
<span><%= watcher_link_for_project(@project, User.current) %></span>
|
2015-03-06 14:55:21 +08:00
|
|
|
<!--加入项目 -->
|
2016-07-28 16:22:33 +08:00
|
|
|
<span id="join_in_project">
|
|
|
|
<%= join_in_project_link(@project, User.current) %>
|
|
|
|
</span>
|
2014-09-28 17:14:09 +08:00
|
|
|
<% end %>
|
2015-04-27 15:39:36 +08:00
|
|
|
<!--配置项目-->
|
2015-04-21 16:35:51 +08:00
|
|
|
<% if User.current.admin? || User.current.allowed_to?({:controller => 'projects', :action => 'settings'}, @project) %>
|
2015-04-09 19:18:04 +08:00
|
|
|
<%= link_to "<span class='pr_setting'></span>#{l(:button_configure)}".html_safe, settings_project_path(@project), :class => "pr_join_a" %>
|
2015-04-27 11:42:01 +08:00
|
|
|
<% end %>
|
2015-04-27 15:39:36 +08:00
|
|
|
<!--项目类型-->
|
2015-04-30 07:46:07 +08:00
|
|
|
<% if (User.current.login? && User.current.member_of?(@project) && Member.where(:user_id => User.current.id, :project_id => @project.id).first.roles.to_s.include?("Manager")) || User.current.admin? %>
|
2015-04-22 13:34:57 +08:00
|
|
|
<%= link_to "<span class='#{typeclass}'></span>#{text}".html_safe,"javascript:void(0)" ,:onClick => "show_window();", :class => "pr_join_a",:id => "setting_project_type"%>
|
2015-04-27 15:39:36 +08:00
|
|
|
<% end %>
|
|
|
|
<!--退出项目-->
|
2015-04-29 14:57:12 +08:00
|
|
|
<% if (User.current.member_of? @project) && User.current.login? && !User.current.admin &&
|
2015-04-30 07:46:07 +08:00
|
|
|
!Member.where(:user_id => User.current.id, :project_id => @project.id).first.roles.to_s.include?("Manager") %>
|
2015-04-27 11:42:01 +08:00
|
|
|
<%= exit_project_link(@project) %>
|
2014-09-28 17:14:09 +08:00
|
|
|
<% end %>
|
2015-03-06 14:55:21 +08:00
|
|
|
</div>
|