Mercurial > hg > soundsoftware-site
comparison .svn/pristine/65/65e02704959a4eede1859ab38db94f171c07d983.svn-base @ 1295:622f24f53b42 redmine-2.3
Update to Redmine SVN revision 11972 on 2.3-stable branch
author | Chris Cannam |
---|---|
date | Fri, 14 Jun 2013 09:02:21 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
1294:3e4c3460b6ca | 1295:622f24f53b42 |
---|---|
1 <div class="contextual"> | |
2 <%= link_to(l(:label_attachment_new), new_project_file_path(@project), :class => 'icon icon-add') if User.current.allowed_to?(:manage_files, @project) %> | |
3 </div> | |
4 | |
5 <h2><%=l(:label_attachment_plural)%></h2> | |
6 | |
7 <% delete_allowed = User.current.allowed_to?(:manage_files, @project) %> | |
8 | |
9 <table class="list files"> | |
10 <thead><tr> | |
11 <%= sort_header_tag('filename', :caption => l(:field_filename)) %> | |
12 <%= sort_header_tag('created_on', :caption => l(:label_date), :default_order => 'desc') %> | |
13 <%= sort_header_tag('size', :caption => l(:field_filesize), :default_order => 'desc') %> | |
14 <%= sort_header_tag('downloads', :caption => l(:label_downloads_abbr), :default_order => 'desc') %> | |
15 <th>MD5</th> | |
16 <th></th> | |
17 </tr></thead> | |
18 <tbody> | |
19 <% @containers.each do |container| %> | |
20 <% next if container.attachments.empty? -%> | |
21 <% if container.is_a?(Version) -%> | |
22 <tr> | |
23 <th colspan="6" align="left"> | |
24 <%= link_to(h(container), {:controller => 'versions', :action => 'show', :id => container}, :class => "icon icon-package") %> | |
25 </th> | |
26 </tr> | |
27 <% end -%> | |
28 <% container.attachments.each do |file| %> | |
29 <tr class="file <%= cycle("odd", "even") %>"> | |
30 <td class="filename"><%= link_to_attachment file, :download => true, :title => file.description %></td> | |
31 <td class="created_on"><%= format_time(file.created_on) %></td> | |
32 <td class="filesize"><%= number_to_human_size(file.filesize) %></td> | |
33 <td class="downloads"><%= file.downloads %></td> | |
34 <td class="digest"><%= file.digest %></td> | |
35 <td align="center"> | |
36 <%= link_to(image_tag('delete.png'), attachment_path(file), | |
37 :data => {:confirm => l(:text_are_you_sure)}, :method => :delete) if delete_allowed %> | |
38 </td> | |
39 </tr> | |
40 <% end | |
41 reset_cycle %> | |
42 <% end %> | |
43 </tbody> | |
44 </table> | |
45 | |
46 <% html_title(l(:label_attachment_plural)) -%> |