Allow to show a specific status in the admin interface

This commit is contained in:
Thibaut Girka authored and ThibG committed 2018-09-03 18:19:11 +02:00
1 parent 6ad7dac791
commit 7ea4c793d6
3 files changed
+37 -1

No files matched your search

@@ -22,6 +22,15 @@ module Admin
@form = Form::StatusBatch.new
end
def show
authorize :status, :index?
@statuses = @account.statuses.where(id: params[:id])
authorize @statuses[0], :show?
@form = Form::StatusBatch.new
end
def create
authorize :status, :update?