Files
danbooru/app/views/wiki_page_versions/index.html.erb
2013-03-02 22:16:23 -05:00

55 lines
1.8 KiB
Plaintext

<div id="c-wiki-pages">
<div id="a-index">
<%= render "wiki_pages/sidebar" %>
<section id="content">
<h1>Wiki Pages</h1>
<%= form_tag(diff_wiki_page_versions_path, :method => :get) do %>
<table width="100%" class="striped">
<thead>
<tr>
<th width="2%"></th>
<th width="2%"></th>
<th width="60%">Title</th>
<th width="10%">IP Address</th>
<th width="26%">Last edited</th>
</tr>
</thead>
<tbody>
<% @wiki_page_versions.each do |wiki_page_version| %>
<tr>
<td><%= radio_button_tag "thispage", wiki_page_version.id %></td>
<td><%= radio_button_tag "otherpage", wiki_page_version.id %></td>
<td><%= link_to wiki_page_version.title, wiki_page_path(wiki_page_version.wiki_page_id) %></td>
<td>
<% if CurrentUser.is_admin? %>
<%= wiki_page_version.updater_ip_addr %>
<% end %>
</td>
<td>
<%= link_to wiki_page_version.updated_at.strftime("%Y-%m-%d %I:%M"), wiki_page_version_path(wiki_page_version) %>
<% if wiki_page_version.updater %>
by
<%= link_to wiki_page_version.updater_name, user_path(wiki_page_version.updater) %>
<% end %>
</td>
</tr>
<% end %>
</tbody>
</table>
<%= submit_tag "Diff" %>
<% end %>
<%= numbered_paginator(@wiki_page_versions) %>
</section>
</div>
</div>
<%= render "wiki_pages/secondary_links" %>
<% content_for(:page_title) do %>
Wiki Page Versions - <%= Danbooru.config.app_name %>
<% end %>