2017-04-10 22:27:03 +03:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
module Admin
|
|
|
|
class BaseController < ApplicationController
|
2017-11-11 21:23:33 +02:00
|
|
|
include Authorization
|
2017-11-24 03:05:53 +02:00
|
|
|
include AccountableConcern
|
2017-11-11 21:23:33 +02:00
|
|
|
|
2017-11-21 08:13:37 +02:00
|
|
|
layout 'admin'
|
|
|
|
|
2017-11-11 21:23:33 +02:00
|
|
|
before_action :require_staff!
|
2017-11-21 08:13:37 +02:00
|
|
|
before_action :set_pack
|
2017-04-10 22:27:03 +03:00
|
|
|
|
2017-11-21 08:13:37 +02:00
|
|
|
def set_pack
|
|
|
|
use_pack 'admin'
|
2018-03-30 19:15:18 +03:00
|
|
|
use_pack 'public'
|
2017-11-21 08:13:37 +02:00
|
|
|
end
|
2017-04-10 22:27:03 +03:00
|
|
|
end
|
|
|
|
end
|