Sha256: bd1d991eecd0d225215bd7ce8edf435b0fcf82cac521460207b1a30029875eb7

Contents?: true

Size: 760 Bytes

Versions: 11

Compression:

Stored size: 760 Bytes

Contents

child :subscription_facet => :subscription_facet_attributes do |facet|
  extends 'katello/api/v2/subscription_facet/base'
  consumer = Katello::Candlepin::Consumer.new(facet.uuid)

  node :compliance_reasons do
    consumer.compliance_reasons
  end

  node :virtual_host do |_subscription_facet|
    if host = consumer.virtual_host
      {:name => host.name, :id => host.id}
    end
  end

  node :virtual_guests do |_subscription_facet|
    consumer.virtual_guests.map do |guest|
      {:name => guest.name, :id => guest.id}
    end
  end

  node :installed_products do
    consumer.installed_products
  end

  child :activation_keys => :activation_keys do
    attributes :id, :name
  end
end

node :content_host_id do |host|
  host.content_host.try(:id)
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
katello-3.1.0.1 app/views/katello/api/v2/subscription_facet/show.json.rabl
katello-3.1.0 app/views/katello/api/v2/subscription_facet/show.json.rabl
katello-3.1.0.rc2.1 app/views/katello/api/v2/subscription_facet/show.json.rabl
katello-3.0.2 app/views/katello/api/v2/subscription_facet/show.json.rabl
katello-3.1.0.rc1 app/views/katello/api/v2/subscription_facet/show.json.rabl
katello-3.0.1 app/views/katello/api/v2/subscription_facet/show.json.rabl
katello-3.0.0 app/views/katello/api/v2/subscription_facet/show.json.rabl
katello-3.0.0.rc7 app/views/katello/api/v2/subscription_facet/show.json.rabl
katello-3.0.0.rc5 app/views/katello/api/v2/subscription_facet/show.json.rabl
katello-3.0.0.rc4 app/views/katello/api/v2/subscription_facet/show.json.rabl
katello-3.0.0.rc3 app/views/katello/api/v2/subscription_facet/show.json.rabl