added post#annihilate, removed stale post_moderation views

This commit is contained in:
albert
2011-10-15 23:07:50 -04:00
parent 81dc20c58f
commit 57c922ec30
18 changed files with 50 additions and 66 deletions

View File

@@ -1,6 +1,9 @@
module Moderator
module Post
class PostsController < ApplicationController
before_filter :janitor_only, :only => [:delete, :undelete]
before_filter :admin_only, :only => [:annihilate]
def delete
@post = ::Post.find(params[:id])
@post.delete!
@@ -10,6 +13,11 @@ module Moderator
@post = ::Post.find(params[:id])
@post.undelete!
end
def annihilate
@post = ::Post.find(params[:id])
@post.annihilate!
end
end
end
end