@@ -1,31 +1,31 | |||||
1 | <% @entries.each do |entry| %> |
|
1 | <% @entries.each do |entry| %> | |
2 | <% tr_id = Digest::MD5.hexdigest(entry.path) |
|
2 | <% tr_id = Digest::MD5.hexdigest(entry.path) | |
3 | depth = params[:depth].to_i %> |
|
3 | depth = params[:depth].to_i %> | |
4 | <% ent_path = Redmine::CodesetUtil.replace_invalid_utf8(entry.path) %> |
|
4 | <% ent_path = Redmine::CodesetUtil.replace_invalid_utf8(entry.path) %> | |
5 | <% ent_name = Redmine::CodesetUtil.replace_invalid_utf8(entry.name) %> |
|
5 | <% ent_name = Redmine::CodesetUtil.replace_invalid_utf8(entry.name) %> | |
6 | <tr id="<%= tr_id %>" class="<%= h params[:parent_id] %> entry <%= entry.kind %>"> |
|
6 | <tr id="<%= tr_id %>" class="<%= h params[:parent_id] %> entry <%= entry.kind %>"> | |
7 | <td style="padding-left: <%=18 * depth%>px;" class="<%= |
|
7 | <td style="padding-left: <%=18 * depth%>px;" class="<%= | |
8 | @repository.report_last_commit ? "filename" : "filename_no_report" %>"> |
|
8 | @repository.report_last_commit ? "filename" : "filename_no_report" %>"> | |
9 | <% if entry.is_dir? %> |
|
9 | <% if entry.is_dir? %> | |
10 | <span class="expander" onclick="scmEntryClick('<%= tr_id %>', '<%= escape_javascript(url_for( |
|
10 | <span class="expander" onclick="scmEntryClick('<%= tr_id %>', '<%= escape_javascript(url_for( | |
11 | :action => 'show', |
|
11 | :action => 'show', | |
12 | :id => @project, |
|
12 | :id => @project, | |
13 | :repository_id => @repository.identifier_param, |
|
13 | :repository_id => @repository.identifier_param, | |
14 | :path => to_path_param(ent_path), |
|
14 | :path => to_path_param(ent_path), | |
15 | :rev => @rev, |
|
15 | :rev => @rev, | |
16 | :depth => (depth + 1), |
|
16 | :depth => (depth + 1), | |
17 | :parent_id => tr_id)) %>');"> </span> |
|
17 | :parent_id => tr_id)) %>');"> </span> | |
18 | <% end %> |
|
18 | <% end %> | |
19 | <%= link_to h(ent_name), |
|
19 | <%= link_to h(ent_name), | |
20 | {:action => (entry.is_dir? ? 'show' : 'changes'), :id => @project, :repository_id => @repository.identifier_param, :path => to_path_param(ent_path), :rev => @rev}, |
|
20 | {:action => (entry.is_dir? ? 'show' : 'changes'), :id => @project, :repository_id => @repository.identifier_param, :path => to_path_param(ent_path), :rev => @rev}, | |
21 | :class => (entry.is_dir? ? 'icon icon-folder' : "icon icon-file #{Redmine::MimeType.css_class_of(ent_name)}")%> |
|
21 | :class => (entry.is_dir? ? 'icon icon-folder' : "icon icon-file #{Redmine::MimeType.css_class_of(ent_name)}")%> | |
22 | </td> |
|
22 | </td> | |
23 | <td class="size"><%= (entry.size ? number_to_human_size(entry.size) : "?") unless entry.is_dir? %></td> |
|
23 | <td class="size"><%= (entry.size ? number_to_human_size(entry.size) : "?") unless entry.is_dir? %></td> | |
24 | <% if @repository.report_last_commit %> |
|
24 | <% if @repository.report_last_commit %> | |
25 | <td class="revision"><%= link_to_revision(entry.changeset, @repository) if entry.changeset %></td> |
|
25 | <td class="revision"><%= link_to_revision(entry.changeset, @repository) if entry.changeset %></td> | |
26 | <td class="age"><%= distance_of_time_in_words(entry.lastrev.time, Time.now) if entry.lastrev && entry.lastrev.time %></td> |
|
26 | <td class="age"><%= distance_of_time_in_words(entry.lastrev.time, Time.now) if entry.lastrev && entry.lastrev.time %></td> | |
27 | <td class="author"><%= entry.author %></td> |
|
27 | <td class="author"><%= entry.author %></td> | |
28 | <td class="comments"><%=h truncate(entry.changeset.comments, :length => 50) if entry.changeset %></td> |
|
28 | <td class="comments"><%=h truncate(entry.changeset.comments, :length => 50) if entry.changeset %></td> | |
29 | <% end %> |
|
29 | <% end %> | |
30 | </tr> |
|
30 | </tr> | |
31 | <% end %> |
|
31 | <% end %> |
General Comments 0
You need to be logged in to leave comments.
Login now