Class: Actions::Katello::Organization::SimpleContentAccess::PrepareContentOverrides
- Inherits:
-
Base
- Object
- Base
- Actions::Katello::Organization::SimpleContentAccess::PrepareContentOverrides
- Defined in:
- app/lib/actions/katello/organization/simple_content_access/prepare_content_overrides.rb
Instance Method Summary collapse
- #humanized_input ⇒ Object
- #humanized_name ⇒ Object
- #plan(organization_id) ⇒ Object
- #rescue_strategy ⇒ Object
- #run ⇒ Object
Instance Method Details
#humanized_input ⇒ Object
29 30 31 |
# File 'app/lib/actions/katello/organization/simple_content_access/prepare_content_overrides.rb', line 29 def humanized_input _("for organization %s") % input[:organization_name] end |
#humanized_name ⇒ Object
25 26 27 |
# File 'app/lib/actions/katello/organization/simple_content_access/prepare_content_overrides.rb', line 25 def humanized_name N_("Prepare content overrides for Simple Content Access") end |
#plan(organization_id) ⇒ Object
6 7 8 9 10 11 12 |
# File 'app/lib/actions/katello/organization/simple_content_access/prepare_content_overrides.rb', line 6 def plan(organization_id) Rails.logger.info "PrepareContentOverrides plan: #{organization_id.inspect}" organization = ::Organization.find(organization_id.to_i) org_name = organization.name plan_self(organization_id: organization_id, organization_name: org_name) end |
#rescue_strategy ⇒ Object
21 22 23 |
# File 'app/lib/actions/katello/organization/simple_content_access/prepare_content_overrides.rb', line 21 def rescue_strategy Dynflow::Action::Rescue::Skip end |
#run ⇒ Object
14 15 16 17 18 19 |
# File 'app/lib/actions/katello/organization/simple_content_access/prepare_content_overrides.rb', line 14 def run organization = ::Organization.find(input[:organization_id].to_i) migrator = ::Katello::Util::ContentOverridesMigrator.new(organization: organization) output[:migrator_result] = migrator.execute_non_sca_overrides! end |