Mercurial > hg > soundsoftware-site
comparison app/views/wiki/annotate.rhtml @ 37:94944d00e43c
* Update to SVN trunk rev 4411
author | Chris Cannam <chris.cannam@soundsoftware.ac.uk> |
---|---|
date | Fri, 19 Nov 2010 13:24:41 +0000 |
parents | 513646585e45 |
children |
comparison
equal
deleted
inserted
replaced
22:40f7cfd4df19 | 37:94944d00e43c |
---|---|
1 <div class="contextual"> | 1 <div class="contextual"> |
2 <%= link_to(l(:button_edit), {:action => 'edit', :page => @page.title}, :class => 'icon icon-edit') %> | 2 <%= link_to(l(:button_edit), {:action => 'edit', :id => @page.title}, :class => 'icon icon-edit') %> |
3 <%= link_to(l(:label_history), {:action => 'history', :page => @page.title}, :class => 'icon icon-history') %> | 3 <%= link_to(l(:label_history), {:action => 'history', :id => @page.title}, :class => 'icon icon-history') %> |
4 </div> | 4 </div> |
5 | 5 |
6 <h2><%= @page.pretty_title %></h2> | 6 <h2><%= @page.pretty_title %></h2> |
7 | 7 |
8 <p> | 8 <p> |
9 <%= l(:label_version) %> <%= link_to @annotate.content.version, :action => 'index', :page => @page.title, :version => @annotate.content.version %> | 9 <%= l(:label_version) %> <%= link_to @annotate.content.version, :action => 'show', :id => @page.title, :version => @annotate.content.version %> |
10 <em>(<%= @annotate.content.author ? @annotate.content.author.name : "anonyme" %>, <%= format_time(@annotate.content.updated_on) %>)</em> | 10 <em>(<%= @annotate.content.author ? @annotate.content.author.name : "anonyme" %>, <%= format_time(@annotate.content.updated_on) %>)</em> |
11 </p> | 11 </p> |
12 | 12 |
13 <% colors = Hash.new {|k,v| k[v] = (k.size % 12) } %> | 13 <% colors = Hash.new {|k,v| k[v] = (k.size % 12) } %> |
14 | 14 |
16 <tbody> | 16 <tbody> |
17 <% line_num = 1 %> | 17 <% line_num = 1 %> |
18 <% @annotate.lines.each do |line| -%> | 18 <% @annotate.lines.each do |line| -%> |
19 <tr class="bloc-<%= colors[line[0]] %>"> | 19 <tr class="bloc-<%= colors[line[0]] %>"> |
20 <th class="line-num"><%= line_num %></th> | 20 <th class="line-num"><%= line_num %></th> |
21 <td class="revision"><%= link_to line[0], :controller => 'wiki', :action => 'index', :id => @project, :page => @page.title, :version => line[0] %></td> | 21 <td class="revision"><%= link_to line[0], :controller => 'wiki', :action => 'show', :project_id => @project, :id => @page.title, :version => line[0] %></td> |
22 <td class="author"><%= h(line[1]) %></td> | 22 <td class="author"><%= h(line[1]) %></td> |
23 <td class="line-code"><pre><%=h line[2] %></pre></td> | 23 <td class="line-code"><pre><%=h line[2] %></pre></td> |
24 </tr> | 24 </tr> |
25 <% line_num += 1 %> | 25 <% line_num += 1 %> |
26 <% end -%> | 26 <% end -%> |