init moderation controller

This commit is contained in:
pixeldesu 2014-12-25 23:00:33 +01:00
parent b927b3bc87
commit 2107ec6270
4 changed files with 10 additions and 0 deletions

View File

@ -0,0 +1,4 @@
class ModerationController < ApplicationController
def index
end
end

View File

@ -0,0 +1,2 @@
module ModerationHelper
end

View File

@ -0,0 +1,2 @@
<h1>Moderation#index</h1>
<p>Find me in app/views/moderation/index.html.erb</p>

View File

@ -1,6 +1,8 @@
require 'sidekiq/web' require 'sidekiq/web'
Rails.application.routes.draw do Rails.application.routes.draw do
get 'moderation/index'
mount RailsAdmin::Engine => '/justask_admin', as: 'rails_admin' mount RailsAdmin::Engine => '/justask_admin', as: 'rails_admin'
constraints ->(req) { req.env["warden"].authenticate?(scope: :user) && constraints ->(req) { req.env["warden"].authenticate?(scope: :user) &&
req.env['warden'].user.admin? } do req.env['warden'].user.admin? } do