私有项目可以引用其他资源
This commit is contained in:
parent
84efdb16c9
commit
97780b7eef
|
@ -22,14 +22,14 @@
|
|||
<% if User.current.logged? %>
|
||||
<!--私有项目资源部能引用,不能设置公开私有-->
|
||||
<!--公开项目资源可以应用,管理员和资源上传者拥有设置公开私有权限-->
|
||||
<% if project.is_public? %>
|
||||
<%# if project.is_public? %>
|
||||
<%= link_to(l(:label_slected_to_other_project),quote_resource_show_project_project_file_path(project,file),:class => "f_l re_select",:remote => true) if has_project?(User.current,file) %>
|
||||
<% if (Member.where(:user_id => User.current.id, :project_id => @project.id).first.roles.to_s.include?("Manager") || file.author_id == User.current.id) && project_contains_attachment?(project,file) && file.container_id == project.id && file.container_type == "Project" %>
|
||||
<span id="is_public_<%= file.id %>">
|
||||
<%= link_to (file.is_public? ? "公开":"私有"), update_file_dense_attachments_path(:attachmentid=>file.id,:newtype=>(file.is_public? ? 0:1)),:remote=>true,:class=>"f_l re_open",:method => :post %>
|
||||
</span>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<%# end %>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
|
|
Loading…
Reference in New Issue