<script>
$(function () {
$('#RelatedProduct-product_area').appendTo($('.ec-layoutRole__main, .ec-layoutRole__mainWithColumn, .ec-layoutRole__mainBetweenColumn'));
});
</script>
{% if Product.RelatedProducts is not empty %}
<div id="RelatedProduct-product_area">
<div id="whobought_area">
<h2 class="title"><img src="{{ asset('assets/img/icon/wstar.png', 'user_data') }}" alt="その他のオススメ商品">その他のオススメ商品</h2>
<div class="other_recommend_container">
<div class="other_recommend_area flex">
{% for RelatedProduct in Product.RelatedProducts %}
{% set ChildProduct = RelatedProduct.ChildProduct %}
{% if ChildProduct.Status.id == constant("Eccube\\Entity\\Master\\ProductStatus::DISPLAY_SHOW") %}
<div class="product_item">
<div class="productImage">
<a href="{{ url('product_detail', {id : ChildProduct.id}) }}">
<img src="{{ asset(RelatedProduct.ChildProduct.main_list_image|no_image_product, 'save_image') }}">
</a>
</div>
<div class="productContents">
<h3><a href="{{ url('product_detail', {id : ChildProduct.id}) }}">{{ RelatedProduct.ChildProduct.name }}</a></h3>
<p class="sale_price">定価:本体価格
<span class="price">
{% if RelatedProduct.ChildProduct.hasProductClass %}
{% if RelatedProduct.ChildProduct.getPrice02Min == RelatedProduct.ChildProduct.getPrice02Max %}
{{ RelatedProduct.ChildProduct.getPrice02IncTaxMin|price }}
{% else %}
{{ RelatedProduct.ChildProduct.getPrice02IncTaxMin|price }} ~ {{ RelatedProduct.ChildProduct.getPrice02IncTaxMax|price }}
{% endif %}
{% else %}
{{ RelatedProduct.ChildProduct.getPrice02IncTaxMin|price }}
{% endif %}
</span>
</p>
<p class="mini">{{ RelatedProduct.content|raw|purify }}</p>
</div>
</div>
{% endif %}
{% endfor %}
</div>
</div>
</div>
</div>
{% endif %}