Sha256: 81a5307d2cfb09aebd598f50c0ff98d23a32fe5d8338a1bbd3ca7d26b47defe6

Contents?: true

Size: 393 Bytes

Versions: 24

Compression:

Stored size: 393 Bytes

Contents

module PgEngine
  class BaseAdminController < ApplicationController
    include PgEngine::RequireSignIn

    before_action do
      raise Pundit::NotAuthorizedError unless Current.user&.developer?

      Current.namespace = :admin

      add_breadcrumb 'Admin'
    end

    around_action :set_without_tenant
    def set_without_tenant(&)
      ActsAsTenant.without_tenant(&)
    end
  end
end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
pg_rails-7.6.21.pre.4 pg_engine/app/controllers/pg_engine/base_admin_controller.rb
pg_rails-7.6.21.pre.3 pg_engine/app/controllers/pg_engine/base_admin_controller.rb
pg_rails-7.6.21.pre.2 pg_engine/app/controllers/pg_engine/base_admin_controller.rb
pg_rails-7.6.21.pre.1 pg_engine/app/controllers/pg_engine/base_admin_controller.rb