Class: Actions::Pulp::Consumer::ContentUpdate

Inherits:
AbstractContentAction show all
Includes:
Helpers::Presenter, ExpectOneTask
Defined in:
app/lib/actions/pulp/consumer/content_update.rb

Constant Summary

Constants inherited from AbstractAsyncTask

AbstractAsyncTask::FINISHED_STATES

Instance Method Summary collapse

Methods included from ExpectOneTask

#external_task=

Methods inherited from AbstractContentAction

#external_task=, #find_errors, #process_timeout, #rescue_strategy

Methods inherited from AbstractAsyncTask

#cancel, #cancel!, #done?, #external_task, #humanized_state, #rescue_external_task, #run

Methods inherited from Abstract

#pulp_extensions, #pulp_resources

Instance Method Details

#invoke_external_taskObject



14
15
16
17
18
19
20
21
22
# File 'app/lib/actions/pulp/consumer/content_update.rb', line 14

def invoke_external_task
  options = { "importkeys" => true }
  options[:all] = true if input[:args].blank?

  pulp_extensions.consumer.update_content(input[:consumer_uuid],
                                          input[:type],
                                          input[:args],
                                          options)
end

#presenterObject



24
25
26
# File 'app/lib/actions/pulp/consumer/content_update.rb', line 24

def presenter
  Consumer::ContentPresenter.new(self)
end