diff --git a/app/controllers/posts_controller.rb b/app/controllers/posts_controller.rb index 63a67944b..e47e16fab 100644 --- a/app/controllers/posts_controller.rb +++ b/app/controllers/posts_controller.rb @@ -26,7 +26,9 @@ class PostsController < ApplicationController @post = Post.find(params[:id]) @version = PostVersion.find(params[:version_id]) @post.revert_to!(@version) - respond_with(@post) + respond_with(@post) do |format| + format.js + end end private diff --git a/app/views/post_versions/_listing.html.erb b/app/views/post_versions/_listing.html.erb index 0949a2001..12f1b7343 100644 --- a/app/views/post_versions/_listing.html.erb +++ b/app/views/post_versions/_listing.html.erb @@ -1,5 +1,5 @@
- +
@@ -8,7 +8,8 @@ - + + @@ -33,6 +34,9 @@ <%= tag %> <% end %> + <% end %> diff --git a/app/views/uploads/show.html.erb b/app/views/uploads/show.html.erb index e761d92e2..eb7273914 100644 --- a/app/views/uploads/show.html.erb +++ b/app/views/uploads/show.html.erb @@ -17,7 +17,7 @@ <% end %>

- You can <%= link_to "upload another file", new_upload_path %> or <%= link_to "view your current uploads", uploads_path %>. + You can <%= link_to "upload another file", new_upload_path %> or <%= link_to "view your current uploads", uploads_path(:search => {:uploader_id_eq => CurrentUser.id}) %>. <% if CurrentUser.user.is_moderator? && @upload.is_pending? %> <%= link_to "Force update", upload_path(@upload, :format => "js"), :remote => true, :method => :put %>. <% end %>

PostRating Parent IP AddressTagsTags
+ <%= link_to "Revert", revert_post_path(post_version.post_id, :version_id => post_version.id), :method => :put, :remote => true %> +