2007-03-12 20:59:02 +03:00
|
|
|
<h2><%= @page.pretty_title %></h2>
|
|
|
|
|
|
|
|
<h3><%= l(:label_history) %></h3>
|
|
|
|
|
2007-07-14 15:25:03 +04:00
|
|
|
<% form_tag({:action => "diff"}, :method => :get) do %>
|
2010-10-21 01:26:30 +04:00
|
|
|
<%= hidden_field_tag('project_id', h(@project.to_param)) %>
|
2007-03-12 20:59:02 +03:00
|
|
|
<table class="list">
|
|
|
|
<thead><tr>
|
|
|
|
<th>#</th>
|
2007-07-14 15:25:03 +04:00
|
|
|
<th></th>
|
|
|
|
<th></th>
|
2007-03-12 20:59:02 +03:00
|
|
|
<th><%= l(:field_updated_on) %></th>
|
|
|
|
<th><%= l(:field_author) %></th>
|
2007-04-25 19:06:20 +04:00
|
|
|
<th><%= l(:field_comments) %></th>
|
2007-12-20 22:10:24 +03:00
|
|
|
<th></th>
|
2007-03-12 20:59:02 +03:00
|
|
|
</tr></thead>
|
|
|
|
<tbody>
|
2007-07-14 15:25:03 +04:00
|
|
|
<% show_diff = @versions.size > 1 %>
|
|
|
|
<% line_num = 1 %>
|
2007-03-12 20:59:02 +03:00
|
|
|
<% @versions.each do |ver| %>
|
|
|
|
<tr class="<%= cycle("odd", "even") %>">
|
2010-10-21 20:07:28 +04:00
|
|
|
<td class="id"><%= link_to ver.version, :action => 'show', :page => @page.title, :version => ver.version %></td>
|
2007-10-06 00:34:21 +04:00
|
|
|
<td class="checkbox"><%= radio_button_tag('version', ver.version, (line_num==1), :id => "cb-#{line_num}", :onclick => "$('cbto-#{line_num+1}').checked=true;") if show_diff && (line_num < @versions.size) %></td>
|
2010-03-10 22:16:03 +03:00
|
|
|
<td class="checkbox"><%= radio_button_tag('version_from', ver.version, (line_num==2), :id => "cbto-#{line_num}") if show_diff && (line_num > 1) %></td>
|
2007-03-12 20:59:02 +03:00
|
|
|
<td align="center"><%= format_time(ver.updated_on) %></td>
|
2010-02-26 19:03:05 +03:00
|
|
|
<td><%= link_to_user ver.author %></td>
|
2007-04-25 19:06:20 +04:00
|
|
|
<td><%=h ver.comments %></td>
|
2007-12-20 22:10:24 +03:00
|
|
|
<td align="center"><%= link_to l(:button_annotate), :action => 'annotate', :page => @page.title, :version => ver.version %></td>
|
2007-03-12 20:59:02 +03:00
|
|
|
</tr>
|
2007-07-14 15:25:03 +04:00
|
|
|
<% line_num += 1 %>
|
2007-03-12 20:59:02 +03:00
|
|
|
<% end %>
|
|
|
|
</tbody>
|
|
|
|
</table>
|
2008-08-20 09:09:13 +04:00
|
|
|
<%= submit_tag l(:label_view_diff), :class => 'small' if show_diff %>
|
2007-12-29 14:36:30 +03:00
|
|
|
<span class="pagination"><%= pagination_links_full @version_pages, @version_count, :page_param => :p %></span>
|
2007-07-14 15:25:03 +04:00
|
|
|
<% end %>
|