Sha256: 4121b0b6c9913874b07e930d739b797427257b85c506215608ccf8c4497e61cf
Contents?: true
Size: 1.02 KB
Versions: 25
Compression:
Stored size: 1.02 KB
Contents
module Katello module Authorization::Organization extend ActiveSupport::Concern include Authorizable def editable? authorized?(:edit_organizations) end def manifest_importable? authorized?(:import_manifest) end def can_import_library_content? authorized?(:import_library_content) end def can_export_library_content? authorized?(:export_library_content) end def readable_promotion_paths permissible_promotion_paths(KTEnvironment.readable) end def promotable_promotion_paths permissible_promotion_paths(KTEnvironment.promotable) end def permissible_promotion_paths(permissible_environments) promotion_paths.select do |promotion_path| # if at least one environment in the path is permissible # the path is deemed permissible. (promotion_path - permissible_environments).size != promotion_path.size end end def subscriptions_readable? User.current.can?(:view_subscriptions) end end end
Version data entries
25 entries across 25 versions & 1 rubygems