Moderators can edit posts that are queued before they approve/reject

This commit is contained in:
Robin Ward
2015-04-15 17:20:34 -04:00
parent 2303b1dcd0
commit 08b4b7b7ff
8 changed files with 134 additions and 47 deletions

View File

@ -15,6 +15,10 @@ class QueuedPostsController < ApplicationController
def update
qp = QueuedPost.where(id: params[:id]).first
if params[:queued_post][:raw].present?
qp.update_column(:raw, params[:queued_post][:raw])
end
state = params[:queued_post][:state]
if state == 'approved'
qp.approve!(current_user)