Sha256: c1dcde5fbdf024ca3edc34bceb5af26b4a98eb8ae1eba2a491f36c04bfce476d

Contents?: true

Size: 662 Bytes

Versions: 82

Compression:

Stored size: 662 Bytes

Contents

module Actions
  module Katello
    module ContentViewPuppetEnvironment
      class Destroy < Actions::EntryAction
        def plan(puppet_env)
          action_subject(puppet_env)
          plan_action(Pulp::Repository::Destroy, pulp_id: puppet_env.pulp_id)
          plan_self
        end

        def finalize
          puppet_env = ::Katello::ContentViewPuppetEnvironment.
            find(input[:content_view_puppet_environment][:id])

          puppet_env.destroy!
        rescue ActiveRecord::RecordNotFound => e
          output[:response] = e.message
        end

        def humanized_name
          _("Delete")
        end
      end
    end
  end
end

Version data entries

82 entries across 82 versions & 1 rubygems

Version Path
katello-3.11.2 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.10.2 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.10.1.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.10.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.11.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.11.0 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.11.0.rc2 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.11.0.rc1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.10.0 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.10.0.rc1.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.9.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.10.0.rc1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.9.0 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.8.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.9.0.rc2 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.9.0.rc1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.7.1.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.7.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.8.0 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.8.0.rc3 app/lib/actions/katello/content_view_puppet_environment/destroy.rb