{#
*
* カスタムテンプレ /app/template/myufull1/Block/sales_ranking_block.twig が正常に読まれて以内ので強制修正
*
#}
<!-- ▼ranking_list▼ -->
{% block stylesheet %}
<style>
.slide-wrap {
margin-bottom: 20px;
overflow-y: hidden;
overflow-x: scroll;
display: flex;
-webkit-overflow-scrolling: touch;
overflow-scrolling: touch;
}
@media only screen and (max-width: 767px) {
.side-box {
flex: 0 0 40%;
padding: 0 8px;
}
}
@media only screen and (min-width: 768px) {
.side-box {
flex: 0 0 18%;
padding: 0 8px;
}
}
.inner, .inner img {
max-width: 100%;
}
</style>
{% endblock %}
{% if ranking_products|length > 0 %}
<div class="ec-shelfRole product-list">
<h3 class="title-bottom-line mt-3">人気商品ランキング</h3>
<div class="slide-wrap">
{% for RankingProduct in ranking_products %}
<div class="side-box">
<div class="inner">
<a href="{{ url('product_detail', {'id': RankingProduct.id}) }}">
<img src="{{ asset(RankingProduct.mainFileName|no_image_product, "save_image") }}">
<p>{{ RankingProduct.name }}</p>
<p class="price02_default">
{% if RankingProduct.hasProductClass %}
{% if RankingProduct.getPrice02Min == RankingProduct.getPrice02Max %}
{{ RankingProduct.getPrice02IncTaxMin|price }}
{% else %}
{{ RankingProduct.getPrice02IncTaxMin|price }} ~ {{ RankingProduct.getPrice02IncTaxMax|price }}
{% endif %}
{% else %}
{{ RankingProduct.getPrice02IncTaxMin|price }}
{% endif %}
</p>
</a>
</div>
</div>
{% endfor %}
</div>
</div>
{% endif %}
<!-- ▲ranking_list▲ -->
{#
<!-- ▼ranking_list▼ -->
{% block stylesheet %}
<style>
.sales_style {
padding-top: 60px;
}
</style>
{% endblock %}
{% if ranking_products|length > 0 %}
<div class="ec-shelfRole sales_style">
<div class="ec-secHeading">
<span class="ec-secHeading__en">{{ 'SALES RANKING'|trans }}</span>
<span class="ec-secHeading__line"></span>
<span class="ec-secHeading__ja">{{ '売上ランキング'|trans }}</span>
</div>
<ul class="ec-shelfGrid">
{% for RankingProduct in ranking_products %}
<li class="ec-shelfGrid__item">
<a href="{{ url('product_detail', {'id': RankingProduct.id}) }}">
<img src="{{ asset(RankingProduct.mainFileName|no_image_product, "save_image") }}">
<dl>
{% if display_name_flg == 1 %}
<dt class="item_name">{{ RankingProduct.name }}</dt>
{% endif %}
{% if display_code_flg == 1 %}
<dd class="item_code">{{ RankingProduct.code_min }}{% if RankingProduct.code_min != RankingProduct.code_max %} ~ {{ RankingProduct.code_max }}{% endif %}</dd>
{% endif %}
{% if display_price_flg == 1 %}
<dd class="item_price">
{% if RankingProduct.hasProductClass %}
{% if RankingProduct.getPrice02Min == RankingProduct.getPrice02Max %}
{{ RankingProduct.getPrice02IncTaxMin|price }}
{% else %}
{{ RankingProduct.getPrice02IncTaxMin|price }} ~ {{ RankingProduct.getPrice02IncTaxMax|price }}
{% endif %}
{% else %}
{{ RankingProduct.getPrice02IncTaxMin|price }}
{% endif %}
</dd>
{% endif %}
{% if display_description_list_flg == 1 %}
<dd class="item_description">{{ RankingProduct.description_list|raw|nl2br }}</dd>
{% endif %}
</dl>
</a>
</li>
{% endfor %}
</ul>
</div>
{% endif %}
<!-- ▲ranking_list▲ -->
#}