Sha256: be5d1ba197efec0ee6ca8202f9b6f7c47a50a60167eff90fb57ad1485f6e14c8

Contents?: true

Size: 1.21 KB

Versions: 16

Compression:

Stored size: 1.21 KB

Contents

json.cache! product.cache_key, expires_in: 1.hour do
  json.id product.id

  json.name product.name
  json.description product.description
  json.slug product.slug

  json.browser_title product.browser_title
  json.meta_description product.meta_description

  json.template product.template
  json.customizations product.customizations
  json.details product.details
  json.digital product.digital?
  json.filters product.filters
  json.purchasable product.purchasable?
  json.inventory_status product.inventory_status

  json.variants product.variants do |variant|
    json.id variant.id
    json.name variant.name
    json.sku variant.sku
    json.details variant.details
  end

  json.sell_min_price json.sell_min_price
  json.sell_max_price product.sell_max_price
  json.on_sale product.on_sale?
  json.original_min_price product.original_min_price
  json.original_max_price product.original_max_price

  json.images product.images do |image|
    json.id image.id
    json.option image.option
    json.position image.position
    json.primary image == product.primary_image
    json.partial! 'workarea/api/storefront/products/image_urls', image: image
  end

  json.append_partials('api.storefront.product_details', product: product)
end

Version data entries

16 entries across 16 versions & 2 rubygems

Version Path
workarea-api-4.5.6 storefront/app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-storefront-4.5.6 app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-4.5.5 storefront/app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-storefront-4.5.5 app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-4.5.4 storefront/app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-storefront-4.5.4 app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-4.5.3 storefront/app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-storefront-4.5.3 app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-4.5.2 storefront/app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-storefront-4.5.2 app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-4.5.0 storefront/app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-storefront-4.5.0 app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-4.4.7 storefront/app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-storefront-4.4.7 app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-4.4.6 storefront/app/views/workarea/api/storefront/products/_product.json.jbuilder
workarea-api-storefront-4.4.6 app/views/workarea/api/storefront/products/_product.json.jbuilder