2011-07-04 23:56:38 +04:00
|
|
|
<%= wiki_page_breadcrumb(@page) %>
|
|
|
|
|
2013-10-14 20:58:39 +04:00
|
|
|
<%= title [@page.pretty_title, project_wiki_page_path(@page.project, @page.title, :version => nil)], l(:label_history) %>
|
2007-03-12 20:59:02 +03:00
|
|
|
|
2012-04-25 21:17:49 +04:00
|
|
|
<%= form_tag({:controller => 'wiki', :action => 'diff',
|
|
|
|
:project_id => @page.project, :id => @page.title},
|
|
|
|
:method => :get) do %>
|
2011-01-07 00:24:32 +03:00
|
|
|
<table class="list wiki-page-versions">
|
2007-03-12 20:59:02 +03:00
|
|
|
<thead><tr>
|
|
|
|
<th>#</th>
|
2007-07-14 15:25:03 +04:00
|
|
|
<th></th>
|
2011-08-02 16:34:06 +04:00
|
|
|
<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| %>
|
2011-01-07 00:24:32 +03:00
|
|
|
<tr class="wiki-page-version <%= cycle("odd", "even") %>">
|
2011-08-02 17:19:45 +04:00
|
|
|
<td class="id"><%= link_to h(ver.version), :action => 'show', :id => @page.title, :project_id => @page.project, :version => ver.version %></td>
|
2012-07-22 17:29:26 +04:00
|
|
|
<td class="checkbox"><%= radio_button_tag('version', ver.version, (line_num==1), :id => "cb-#{line_num}", :onclick => "$('#cbto-#{line_num+1}').attr('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>
|
2011-01-07 00:24:32 +03:00
|
|
|
<td class="updated_on"><%= format_time(ver.updated_on) %></td>
|
|
|
|
<td class="author"><%= link_to_user ver.author %></td>
|
|
|
|
<td class="comments"><%=h ver.comments %></td>
|
2012-10-23 22:45:14 +04:00
|
|
|
<td class="buttons">
|
|
|
|
<%= link_to l(:button_annotate), :action => 'annotate', :id => @page.title, :version => ver.version %>
|
|
|
|
<%= delete_link wiki_page_path(@page, :version => ver.version) if User.current.allowed_to?(:delete_wiki_pages, @page.project) && @version_count > 1 %>
|
|
|
|
</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 %>
|
2012-10-29 00:27:50 +04:00
|
|
|
<span class="pagination"><%= pagination_links_full @version_pages, @version_count %></span>
|
2007-07-14 15:25:03 +04:00
|
|
|
<% end %>
|