Class: Actions::Katello::ContentViewVersion::VerifyChecksum

Inherits:
EntryAction
  • Object
show all
Includes:
Helpers::ContentViewAutoPublisher
Defined in:
app/lib/actions/katello/content_view_version/verify_checksum.rb

Instance Method Summary collapse

Methods included from Helpers::ContentViewAutoPublisher

#auto_publish_view, #auto_publish_views, included, #trigger_auto_publish

Instance Method Details

#humanized_nameObject



17
18
19
20
21
22
23
24
25
26
27
# File 'app/lib/actions/katello/content_view_version/verify_checksum.rb', line 17

def humanized_name
  if input && input[:version_id]
    version = ::Katello::ContentViewVersion.find_by(:id => input[:version_id])
  end

  if version
    _("Verify checksum of repositories in %{name} %{version}") % {:name => version.content_view.name, :version => version.version}
  else
    _("Verify checksum of version repositories")
  end
end

#plan(content_view_version) ⇒ Object



7
8
9
10
11
# File 'app/lib/actions/katello/content_view_version/verify_checksum.rb', line 7

def plan(content_view_version)
  action_subject(content_view_version.content_view)
  plan_self(:version_id => content_view_version.id)
  plan_action(::Actions::BulkAction, ::Actions::Katello::Repository::VerifyChecksum, content_view_version.repositories) if content_view_version.repositories.any?
end

#runObject



13
14
15
# File 'app/lib/actions/katello/content_view_version/verify_checksum.rb', line 13

def run
  #dummy run phase to save input and support humanized_name
end