From 8d084cf690a78eae0df5c9e13b34ed3c08f6e161 Mon Sep 17 00:00:00 2001 From: hukl Date: Fri, 1 May 2009 18:14:59 +0200 Subject: introducing the restore revision functionality --- app/views/revisions/show.html.erb | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'app/views') diff --git a/app/views/revisions/show.html.erb b/app/views/revisions/show.html.erb index 2a4a9a1..ebda18d 100644 --- a/app/views/revisions/show.html.erb +++ b/app/views/revisions/show.html.erb @@ -23,11 +23,21 @@ <%= page.title %> <%= page.user.try(:login) %> <%= page.updated_at %> - <%= link_to 'show', node_path(page.node) %> + + <%= link_to 'show', node_path(page.node) %> + + + <%= link_to( + 'restore', + restore_revision_path(page), + :method => :put, + :confirm => "Restore this revision?" + ) %> + <% end %> - <%= submit_tag 'Diff revisions' %> + <%= submit_tag 'Diff revisions' %> -- cgit v1.3