Sha256: efcc8335d48818515b55cb1c7f79ee2a9d24ea925a2f9fb28ae5027988aab94c

Contents?: true

Size: 781 Bytes

Versions: 39

Compression:

Stored size: 781 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Api
    # Base controller for `decidim-api`. All other controllers inherit from this.
    class ApplicationController < ::DecidimController
      skip_before_action :verify_authenticity_token
      include NeedsOrganization
      include UseOrganizationTimeZone
      include NeedsPermission
      include ImpersonateUsers
      include ForceAuthentication
      include DisableRedirectionToExternalHost

      register_permissions(::Decidim::Api::ApplicationController,
                           ::Decidim::Permissions)

      def permission_class_chain
        ::Decidim.permissions_registry.chain_for(::Decidim::Api::ApplicationController)
      end

      def permission_scope
        :public
      end
    end
  end
end

Version data entries

39 entries across 39 versions & 1 rubygems

Version Path
decidim-api-0.29.1 app/controllers/decidim/api/application_controller.rb
decidim-api-0.28.4 app/controllers/decidim/api/application_controller.rb
decidim-api-0.27.9 app/controllers/decidim/api/application_controller.rb
decidim-api-0.29.0 app/controllers/decidim/api/application_controller.rb
decidim-api-0.28.3 app/controllers/decidim/api/application_controller.rb
decidim-api-0.27.8 app/controllers/decidim/api/application_controller.rb
decidim-api-0.29.0.rc4 app/controllers/decidim/api/application_controller.rb
decidim-api-0.29.0.rc3 app/controllers/decidim/api/application_controller.rb
decidim-api-0.29.0.rc2 app/controllers/decidim/api/application_controller.rb
decidim-api-0.29.0.rc1 app/controllers/decidim/api/application_controller.rb
decidim-api-0.28.2 app/controllers/decidim/api/application_controller.rb
decidim-api-0.27.7 app/controllers/decidim/api/application_controller.rb
decidim-api-0.28.1 app/controllers/decidim/api/application_controller.rb
decidim-api-0.27.6 app/controllers/decidim/api/application_controller.rb
decidim-api-0.26.10 app/controllers/decidim/api/application_controller.rb
decidim-api-0.26.9 app/controllers/decidim/api/application_controller.rb
decidim-api-0.28.0 app/controllers/decidim/api/application_controller.rb
decidim-api-0.27.5 app/controllers/decidim/api/application_controller.rb
decidim-api-0.28.0.rc5 app/controllers/decidim/api/application_controller.rb
decidim-api-0.28.0.rc4 app/controllers/decidim/api/application_controller.rb