To check out this repository please hg clone the following URL, or open the URL using EasyMercurial or your preferred Mercurial client.
root / app / views / wiki / annotate.html.erb @ 1531:ae8145b28b2b
History | View | Annotate | Download (1.43 KB)
| 1 |
<div class="contextual"> |
|---|---|
| 2 |
<%= link_to(l(:button_edit), {:action => 'edit', :id => @page.title}, :class => 'icon icon-edit') %>
|
| 3 |
<%= link_to(l(:label_history),
|
| 4 |
{:action => 'history', :id => @page.title}, :class => 'icon icon-history') %>
|
| 5 |
</div>
|
| 6 |
|
| 7 |
<%= wiki_page_breadcrumb(@page) %>
|
| 8 |
|
| 9 |
<%= title [@page.pretty_title, project_wiki_page_path(@page.project, @page.title, :version => nil)],
|
| 10 |
[l(:label_history), history_project_wiki_page_path(@page.project, @page.title)],
|
| 11 |
"#{l(:label_version)} #{@annotate.content.version}" %>
|
| 12 |
|
| 13 |
<p>
|
| 14 |
<em><%= @annotate.content.author ? link_to_user(@annotate.content.author) : l(:label_user_anonymous) |
| 15 |
%>, <%= format_time(@annotate.content.updated_on) %> </em><br /> |
| 16 |
<%=h @annotate.content.comments %>
|
| 17 |
</p>
|
| 18 |
|
| 19 |
<% colors = Hash.new {|k,v| k[v] = (k.size % 12) } %>
|
| 20 |
|
| 21 |
<table class="filecontent annotate"> |
| 22 |
<tbody>
|
| 23 |
<% line_num = 1 %>
|
| 24 |
<% @annotate.lines.each do |line| -%>
|
| 25 |
<tr class="bloc-<%= colors[line[0]] %>"> |
| 26 |
<th class="line-num"><%= line_num %></th> |
| 27 |
<td class="revision"><%= link_to line[0], :controller => 'wiki', |
| 28 |
:action => 'show', :project_id => @project,
|
| 29 |
:id => @page.title, :version => line[0] %></td> |
| 30 |
<td class="author"><%= h(line[1]) %></td> |
| 31 |
<td class="line-code"><pre><%=h line[2] %></pre></td> |
| 32 |
</tr>
|
| 33 |
<% line_num += 1 %>
|
| 34 |
<% end -%>
|
| 35 |
</tbody>
|
| 36 |
</table>
|
| 37 |
|
| 38 |
<% content_for :header_tags do %>
|
| 39 |
<%= stylesheet_link_tag 'scm' %>
|
| 40 |
<% end %>
|