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 @ 1298:4f746d8966dd
History | View | Annotate | Download (1.42 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 |
<h2><%=h @page.pretty_title %></h2> |
| 10 |
|
| 11 |
<p>
|
| 12 |
<%= l(:label_version) %> <%= link_to h(@annotate.content.version), |
| 13 |
:action => 'show', :project_id => @project,
|
| 14 |
:id => @page.title, :version => @annotate.content.version %>
|
| 15 |
<em>(<%= h(@annotate.content.author ? |
| 16 |
@annotate.content.author.name : l(:label_user_anonymous))
|
| 17 |
%>, <%= format_time(@annotate.content.updated_on) %>)</em> |
| 18 |
</p>
|
| 19 |
|
| 20 |
<% colors = Hash.new {|k,v| k[v] = (k.size % 12) } %>
|
| 21 |
|
| 22 |
<table class="filecontent annotate"> |
| 23 |
<tbody>
|
| 24 |
<% line_num = 1 %>
|
| 25 |
<% @annotate.lines.each do |line| -%>
|
| 26 |
<tr class="bloc-<%= colors[line[0]] %>"> |
| 27 |
<th class="line-num"><%= line_num %></th> |
| 28 |
<td class="revision"><%= link_to line[0], :controller => 'wiki', |
| 29 |
:action => 'show', :project_id => @project,
|
| 30 |
:id => @page.title, :version => line[0] %></td> |
| 31 |
<td class="author"><%= h(line[1]) %></td> |
| 32 |
<td class="line-code"><pre><%=h line[2] %></pre></td> |
| 33 |
</tr>
|
| 34 |
<% line_num += 1 %>
|
| 35 |
<% end -%>
|
| 36 |
</tbody>
|
| 37 |
</table>
|
| 38 |
|
| 39 |
<% content_for :header_tags do %>
|
| 40 |
<%= stylesheet_link_tag 'scm' %>
|
| 41 |
<% end %>
|