Sha256: babeab3eccfbe668d1d632464e588ddbb8e23ba04298f267941c7fd8981d9c42

Contents?: true

Size: 684 Bytes

Versions: 13

Compression:

Stored size: 684 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, content_view_puppet_environment_id: puppet_env.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

13 entries across 13 versions & 1 rubygems

Version Path
katello-3.13.2 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.14.0.rc1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.13.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.13.0 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.13.0.rc2.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.13.0.rc2 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.12.3 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.12.2 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.13.0.rc1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.12.1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.12.0 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.12.0.rc2 app/lib/actions/katello/content_view_puppet_environment/destroy.rb
katello-3.12.0.rc1 app/lib/actions/katello/content_view_puppet_environment/destroy.rb