comparison app/views/repositories/_dir_list_content.html.erb @ 1115:433d4f72a19b redmine-2.2

Update to Redmine SVN revision 11137 on 2.2-stable branch
author Chris Cannam
date Mon, 07 Jan 2013 12:01:42 +0000
parents cbb26bc654de
children bb32da3bea34 dffacf8a6908
comparison
equal deleted inserted replaced
929:5f33065ddc4b 1115:433d4f72a19b
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="<%= remote_function( 10 <span class="expander" onclick="scmEntryClick('<%= tr_id %>', '<%= escape_javascript(url_for(
11 :url => {
12 :action => 'show', 11 :action => 'show',
13 :id => @project, 12 :id => @project,
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 17 :parent_id => tr_id)) %>');">&nbsp;</span>
18 },
19 :method => :get,
20 :update => { :success => tr_id },
21 :position => :after,
22 :success => "scmEntryLoaded('#{tr_id}')",
23 :condition => "scmEntryClick('#{tr_id}')"
24 ) %>">&nbsp</span>
25 <% end %> 18 <% end %>
26 <%= link_to h(ent_name), 19 <%= link_to h(ent_name),
27 {:action => (entry.is_dir? ? 'show' : 'changes'), :id => @project, :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},
28 :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)}")%>
29 </td> 22 </td>
30 <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>
31 <% changeset = @project.repository.find_changeset_by_name(entry.lastrev.identifier) if entry.lastrev && entry.lastrev.identifier %>
32 <% if @repository.report_last_commit %> 24 <% if @repository.report_last_commit %>
33 <td class="revision"><%= link_to_revision(changeset, @project) if changeset %></td> 25 <td class="revision"><%= link_to_revision(entry.changeset, @repository) if entry.changeset %></td>
34 <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>
35 <td class="author"><%= changeset.nil? ? h(Redmine::CodesetUtil.replace_invalid_utf8(entry.lastrev.author.to_s.split('<').first)) : h(changeset.author) if entry.lastrev %></td> 27 <td class="author"><%= entry.author %></td>
36 <td class="comments"><%=h truncate(changeset.comments, :length => 50) unless changeset.nil? %></td> 28 <td class="comments"><%=h truncate(entry.changeset.comments, :length => 50) if entry.changeset %></td>
37 <% end %> 29 <% end %>
38 </tr> 30 </tr>
39 <% end %> 31 <% end %>