Class: Actions::Katello::ContentView::Destroy
- Inherits:
-
EntryAction
- Object
- EntryAction
- Actions::Katello::ContentView::Destroy
- Defined in:
- app/lib/actions/katello/content_view/destroy.rb
Instance Method Summary collapse
Instance Method Details
#finalize ⇒ Object
24 25 26 27 28 |
# File 'app/lib/actions/katello/content_view/destroy.rb', line 24 def finalize content_view = ::Katello::ContentView.find(input[:content_view][:id]) content_view.content_view_repositories.each(&:destroy) content_view.destroy! end |
#humanized_name ⇒ Object
30 31 32 |
# File 'app/lib/actions/katello/content_view/destroy.rb', line 30 def humanized_name _("Delete") end |
#plan(content_view, options = {}) ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'app/lib/actions/katello/content_view/destroy.rb', line 7 def plan(content_view, = {}) action_subject(content_view) if .fetch(:check_ready_to_destroy, true) content_view.check_ready_to_destroy! end sequence do concurrence do content_view.content_view_versions.each do |version| plan_action(ContentViewVersion::Destroy, version, ) end end plan_self end end |