{#
UaGaEEc: Google Analytics eコマース/拡張eコマース対応プラグイン
Copyright (C) 2016-2021 Freischtide Inc. All Rights Reserved.
http://freischtide.tumblr.com/
License: see LICENSE.txt
#}
{% for product in products %}
{
"item_id": "{{ product.id }}",
"item_name": "{{ product.name }}",
"currency": "JPY",
"price": "{{ product.price }}",
{% if product.category|length > 0 %}
"item_category": "{{ product.category }}",
{% endif %}
{% if product.quantity is defined and product.quantity > 0 %}
"quantity": {{ product.quantity }},
{% endif %}
{% if list_name is defined %}
"list_name": "{{ list_name }}",
{% endif %}
"list_position": {{ loop.index }}
}{% if not loop.last %},{% endif %}
{% endfor %}