Class: HammerCLIKatello::ContentViewComponentBase::ComponentUpdateCommand
- Inherits:
-
ComponentCommand
- Object
- HammerCLIForeman::SingleResourceCommand
- SingleResourceCommand
- ComponentCommand
- HammerCLIKatello::ContentViewComponentBase::ComponentUpdateCommand
- Defined in:
- lib/hammer_cli_katello/content_view_component.rb
Direct Known Subclasses
HammerCLIKatello::ContentViewComponent::AddComponents, HammerCLIKatello::ContentViewComponent::UpdateCommand
Instance Method Summary collapse
Methods inherited from ComponentCommand
#get_component_by_name_or_id, #get_components
Methods included from HammerCLIKatello::CompositeContentViewNameResolvable
#composite_content_view_resolve_options, included, #options
Methods included from OrganizationOptions
Methods included from ResolverCommons
Instance Method Details
#fetch_cv ⇒ Object
42 43 44 45 46 47 48 49 50 51 |
# File 'lib/hammer_cli_katello/content_view_component.rb', line 42 def fetch_cv cv = option_content_view_id if cv.nil? && option_content_view_name = .merge( HammerCLI.option_accessor_name('name') => option_content_view_name) cv = resolver.content_view_id() end cv end |
#fetch_cvv(cv) ⇒ Object
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 |
# File 'lib/hammer_cli_katello/content_view_component.rb', line 53 def fetch_cvv(cv) cvv = option_component_content_view_version_id if cvv.nil? if option_component_content_view_version_version && cv.nil? raise _("Please provide --component-content-view-id") end if option_component_content_view_version_version.nil? raise _("Please provide --component-content-view-version-id or" \ " --component-content-view-version or" \ " --latest for the latest version") end = .merge( HammerCLI.option_accessor_name("content_view_id") => cv, HammerCLI.option_accessor_name("version") => option_component_content_view_version_version ) cvv = resolver.content_view_version_id() end cvv end |