Module: Decidim::RegistersPermissions

Extended by:
ActiveSupport::Concern
Included in:
NeedsPermission
Defined in:
app/controllers/concerns/decidim/registers_permissions.rb

Overview

Including this concern will enable a ‘register_permissions` class method to be used for configuring the permissions for the includer artifact.

Class Method Summary collapse

Class Method Details

.register_permissions(artifact, *permission_classes) ⇒ Object



13
14
15
# File 'app/controllers/concerns/decidim/registers_permissions.rb', line 13

def self.register_permissions(artifact, *permission_classes)
  ::Decidim.permissions_registry.register_permissions(artifact, *permission_classes)
end