chris@22:
chris@37: <%= link_to(l(:label_attachment_new), new_project_file_path(@project), :class => 'icon icon-add') if User.current.allowed_to?(:manage_files, @project) %> chris@22:
chris@22: chris@22:

<%=l(:label_attachment_plural)%>

chris@22: chris@22: <% delete_allowed = User.current.allowed_to?(:manage_files, @project) %> chris@22: chris@22: chris@22: chris@22: <%= sort_header_tag('filename', :caption => l(:field_filename)) %> chris@22: <%= sort_header_tag('created_on', :caption => l(:label_date), :default_order => 'desc') %> chris@22: <%= sort_header_tag('size', :caption => l(:field_filesize), :default_order => 'desc') %> chris@22: <%= sort_header_tag('downloads', :caption => l(:label_downloads_abbr), :default_order => 'desc') %> chris@22: chris@22: chris@22: chris@22: chris@22: <% @containers.each do |container| %> chris@22: <% next if container.attachments.empty? -%> chris@22: <% if container.is_a?(Version) -%> chris@22: chris@22: chris@22: chris@22: <% end -%> chris@22: <% container.attachments.each do |file| %> chris@22: "> chris@22: chris@22: chris@22: chris@22: chris@22: chris@22: chris@22: chris@22: <% end chris@22: reset_cycle %> chris@22: <% end %> chris@22: chris@22:
MD5
chris@22: <%= link_to(h(container), {:controller => 'versions', :action => 'show', :id => container}, :class => "icon icon-package") %> chris@22:
<%= link_to_attachment file, :download => true, :title => file.description %><%= format_time(file.created_on) %><%= number_to_human_size(file.filesize) %><%= file.downloads %><%= file.digest %> chris@22: <%= link_to(image_tag('delete.png'), {:controller => 'attachments', :action => 'destroy', :id => file}, chris@22: :confirm => l(:text_are_you_sure), :method => :post) if delete_allowed %> chris@22:
chris@22: chris@22: <% html_title(l(:label_attachment_plural)) -%>