<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Source;
use Twig\Template;
/* Product/list.twig */
class __TwigTemplate_1c7a15322c7d068b9607a502fe342d0c extends \Eccube\Twig\Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'stylesheet' => [$this, 'block_stylesheet'],
'javascript' => [$this, 'block_javascript'],
'main' => [$this, 'block_main'],
];
$this->sandbox = $this->env->getExtension('\Twig\Extension\SandboxExtension');
$this->checkSecurity();
}
protected function doGetParent(array $context)
{
// line 11
return "default_frame.twig";
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Product/list.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Product/list.twig"));
// line 13
$context["body_class"] = "product_page";
// line 11
$this->parent = $this->loadTemplate("default_frame.twig", "Product/list.twig", 11);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 14
public function block_stylesheet($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "stylesheet"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "stylesheet"));
// line 15
echo "<style>
.c_sale {
position: absolute;
top: 0;
background-color: red;
padding: 4px 8px;
color: #fff;
font-size: 12px;
}
</style>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 26
public function block_javascript($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "javascript"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "javascript"));
// line 27
echo " \t<script>
\t eccube.productsClassCategories = {
\t ";
// line 29
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 29, $this->source); })()));
$context['loop'] = [
'parent' => $context['_parent'],
'index0' => 0,
'index' => 1,
'first' => true,
];
if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
$length = count($context['_seq']);
$context['loop']['revindex0'] = $length - 1;
$context['loop']['revindex'] = $length;
$context['loop']['length'] = $length;
$context['loop']['last'] = 1 === $length;
}
foreach ($context['_seq'] as $context["_key"] => $context["Product"]) {
// line 30
echo "\t \"";
echo twig_escape_filter($this->env, twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Product"], "id", [], "any", false, false, true, 30), 30, $this->source), "js"), "html", null, true);
echo "\": ";
echo $this->extensions['Eccube\Twig\Extension\EccubeExtension']->getClassCategoriesAsJson($this->sandbox->ensureToStringAllowed($context["Product"], 30, $this->source));
if ((twig_get_attribute($this->env, $this->source, $context["loop"], "last", [], "any", false, false, true, 30) == false)) {
echo ", ";
}
// line 31
echo "\t ";
++$context['loop']['index0'];
++$context['loop']['index'];
$context['loop']['first'] = false;
if (isset($context['loop']['length'])) {
--$context['loop']['revindex0'];
--$context['loop']['revindex'];
$context['loop']['last'] = 0 === $context['loop']['revindex0'];
}
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['Product'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 32
echo "\t };
\t\t\t\t\t\t\t\t\t
\$(function() {
// 表示件数を変更
\$('.disp-number').change(function() {
var dispNumber = \$(this).val();
\$('#disp_number').val(dispNumber);
\$('#pageno').val(1);
\$(\"#form1\").submit();
});
// 並び順を変更
\$('.order-by').change(function() {
var orderBy = \$(this).val();
\$('#pageno').val(1);
\$('#orderby').val(orderBy);
\$(\"#form1\").submit();
});
\$('.add-cart').on('click', function(e) {
var \$form = \$(this).parents('li').find('form');
// 個数フォームのチェック
var \$quantity = \$form.parent().find('.quantity');
if (\$quantity.val() < 1) {
\$quantity[0].setCustomValidity('";
// line 58
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("1以上で入力してください。"), "html", null, true);
echo "');
setTimeout(function() {
loadingOverlay('hide');
}, 100);
return true;
} else {
\$quantity[0].setCustomValidity('');
}
e.preventDefault();
\$.ajax({
url: \$form.attr('action'),
type: \$form.attr('method'),
data: \$form.serialize(),
dataType: 'json',
beforeSend: function(xhr, settings) {
// Buttonを無効にする
\$('.add-cart').prop('disabled', true);
}
}).done(function(data) {
// レスポンス内のメッセージをalertで表示
\$.each(data.messages, function() {
\$('#ec-modal-header').text(this);
});
\$('.ec-modal').show()
// カートブロックを更新する
\$.ajax({
url: '";
// line 86
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("block_cart");
echo "',
type: 'GET',
dataType: 'html'
}).done(function(html) {
\$('.ec-headerRole__cart').html(html);
});
}).fail(function(data) {
alert('";
// line 93
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートへの追加に失敗しました。"), "html", null, true);
echo "');
}).always(function(data) {
// Buttonを有効にする
\$('.add-cart').prop('disabled', false);
});
});
});
\t\t\t\t\t\t\t\t\t
\t\t\$('.ec-modal-wrap').on('click', function(e) {
\t\t // モーダル内の処理は外側にバブリングさせない
\t\t e.stopPropagation();
\t\t});
\t\t\$('.ec-modal-overlay, .ec-modal, .ec-modal-close, .ec-inlineBtn--cancel').on('click', function() {
\t\t \$('.ec-modal').hide()
\t\t});
\t\t\t\t\t\t\t\t\t
\t\t\t\t\t\t\t\t\t
\t</script>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 113
public function block_main($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "main"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "main"));
// line 114
echo "\t<div class=\"ec-productRole\">
\t\t<ol class=\"breadcrumb\" itemscope itemtype=\"https://schema.org/BreadcrumbList\">
\t\t\t<li itemprop=\"itemListElement\" itemscope itemtype=\"https://schema.org/ListItem\">
\t\t\t\t<a itemprop=\"item\" href=\"/\">
\t\t\t\t\t<span itemprop=\"name\">TOP</span>
\t\t\t\t</a>
\t\t\t\t<meta itemprop=\"position\" content=\"1\"/>
\t\t\t</li>
\t\t\t";
// line 122
if ( !(null === (isset($context["Category"]) || array_key_exists("Category", $context) ? $context["Category"] : (function () { throw new RuntimeError('Variable "Category" does not exist.', 122, $this->source); })()))) {
// line 123
echo "\t\t\t\t";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, (isset($context["Category"]) || array_key_exists("Category", $context) ? $context["Category"] : (function () { throw new RuntimeError('Variable "Category" does not exist.', 123, $this->source); })()), "path", [], "any", false, false, true, 123));
foreach ($context['_seq'] as $context["_key"] => $context["Path"]) {
// line 124
echo "\t\t\t\t\t<li itemprop=\"itemListElement\" itemscope itemtype=\"https://schema.org/ListItem\">
\t\t\t\t\t\t<a itemprop=\"item\" href=\"";
// line 125
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("product_list");
echo "?category_id=";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Path"], "id", [], "any", false, false, true, 125), 125, $this->source), "html", null, true);
echo "\">
\t\t\t\t\t\t\t<span itemprop=\"name\">";
// line 126
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Path"], "name", [], "any", false, false, true, 126), 126, $this->source), "html", null, true);
echo "</span>
\t\t\t\t\t\t</a>
\t\t\t\t\t\t<meta itemprop=\"position\" content=\"2\"/>
\t\t\t\t\t</li>
\t\t\t\t";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['Path'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 131
echo "\t\t\t";
}
// line 132
echo "\t\t</ol>
\t</div>
\t";
// line 134
if ((twig_length_filter($this->env, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["search_form"]) || array_key_exists("search_form", $context) ? $context["search_form"] : (function () { throw new RuntimeError('Variable "search_form" does not exist.', 134, $this->source); })()), "category_id", [], "any", false, false, true, 134), "vars", [], "any", false, false, true, 134), "errors", [], "any", false, false, true, 134)) > 0)) {
// line 135
echo "\t\t<div class=\"ec-searchnavRole\">
\t\t\t<p class=\"errormsg text-danger\">";
// line 136
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("ご指定のカテゴリは存在しません"), "html", null, true);
echo "</p>
\t\t</div>
\t";
} else {
// line 139
echo "\t\t<div class=\"ec-searchnavRole\">
\t\t\t<form name=\"form1\" id=\"form1\" method=\"get\" action=\"?\">
\t\t\t\t";
// line 141
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["search_form"]) || array_key_exists("search_form", $context) ? $context["search_form"] : (function () { throw new RuntimeError('Variable "search_form" does not exist.', 141, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
// line 142
echo "\t\t\t\t\t<input type=\"hidden\" id=\"";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["item"], "vars", [], "any", false, false, true, 142), "id", [], "any", false, false, true, 142), 142, $this->source), "html", null, true);
echo "\" name=\"";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["item"], "vars", [], "any", false, false, true, 142), "full_name", [], "any", false, false, true, 142), 142, $this->source), "html", null, true);
echo "\" ";
if ( !twig_test_empty(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["item"], "vars", [], "any", false, false, true, 142), "value", [], "any", false, false, true, 142))) {
echo " value=\"";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["item"], "vars", [], "any", false, false, true, 142), "value", [], "any", false, false, true, 142), 142, $this->source), "html", null, true);
echo "\" ";
}
echo "/>
\t\t\t\t";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 144
echo "\t\t\t</form>
\t\t\t<div
\t\t\t\tclass=\"ec-searchnavRole__topicpath gnavi__list_sp\">
\t\t\t\t";
// line 148
echo "\t\t\t\t";
$context["all_categories"] = [];
// line 149
echo "
\t\t\t\t";
// line 151
echo "\t\t\t\t";
if (( !(null === (isset($context["Category"]) || array_key_exists("Category", $context) ? $context["Category"] : (function () { throw new RuntimeError('Variable "Category" does not exist.', 151, $this->source); })())) && !(null === twig_get_attribute($this->env, $this->source, (isset($context["Category"]) || array_key_exists("Category", $context) ? $context["Category"] : (function () { throw new RuntimeError('Variable "Category" does not exist.', 151, $this->source); })()), "path", [], "any", false, false, true, 151)))) {
// line 152
echo "\t\t\t\t\t";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, (isset($context["Category"]) || array_key_exists("Category", $context) ? $context["Category"] : (function () { throw new RuntimeError('Variable "Category" does not exist.', 152, $this->source); })()), "path", [], "any", false, false, true, 152));
foreach ($context['_seq'] as $context["_key"] => $context["Path"]) {
// line 153
echo "\t\t\t\t\t\t";
$context["category_item"] = ["id" => twig_get_attribute($this->env, $this->source, $context["Path"], "id", [], "any", false, false, true, 153), "name" => twig_get_attribute($this->env, $this->source, $context["Path"], "name", [], "any", false, false, true, 153)];
// line 154
echo "\t\t\t\t\t\t";
if (!twig_in_filter((isset($context["category_item"]) || array_key_exists("category_item", $context) ? $context["category_item"] : (function () { throw new RuntimeError('Variable "category_item" does not exist.', 154, $this->source); })()), (isset($context["all_categories"]) || array_key_exists("all_categories", $context) ? $context["all_categories"] : (function () { throw new RuntimeError('Variable "all_categories" does not exist.', 154, $this->source); })()))) {
// line 155
echo "\t\t\t\t\t\t\t";
$context["all_categories"] = twig_array_merge($this->sandbox->ensureToStringAllowed((isset($context["all_categories"]) || array_key_exists("all_categories", $context) ? $context["all_categories"] : (function () { throw new RuntimeError('Variable "all_categories" does not exist.', 155, $this->source); })()), 155, $this->source), [0 => (isset($context["category_item"]) || array_key_exists("category_item", $context) ? $context["category_item"] : (function () { throw new RuntimeError('Variable "category_item" does not exist.', 155, $this->source); })())]);
// line 156
echo "\t\t\t\t\t\t";
}
// line 157
echo "\t\t\t\t\t";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['Path'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 158
echo "\t\t\t\t";
}
// line 159
echo "
\t\t\t\t";
// line 161
echo "\t\t\t\t";
if ( !(null === (isset($context["Category"]) || array_key_exists("Category", $context) ? $context["Category"] : (function () { throw new RuntimeError('Variable "Category" does not exist.', 161, $this->source); })()))) {
// line 162
echo "\t\t\t\t\t";
$context["cate_childs"] = twig_get_attribute($this->env, $this->source, (isset($context["Category"]) || array_key_exists("Category", $context) ? $context["Category"] : (function () { throw new RuntimeError('Variable "Category" does not exist.', 162, $this->source); })()), "getDescendants", [], "any", false, false, true, 162);
// line 163
echo "\t\t\t\t\t";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["cate_childs"]) || array_key_exists("cate_childs", $context) ? $context["cate_childs"] : (function () { throw new RuntimeError('Variable "cate_childs" does not exist.', 163, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["cate"]) {
// line 164
echo "\t\t\t\t\t\t";
$context["category_item"] = ["id" => twig_get_attribute($this->env, $this->source, $context["cate"], "id", [], "any", false, false, true, 164), "name" => twig_get_attribute($this->env, $this->source, $context["cate"], "name", [], "any", false, false, true, 164)];
// line 165
echo "\t\t\t\t\t\t";
if (!twig_in_filter((isset($context["category_item"]) || array_key_exists("category_item", $context) ? $context["category_item"] : (function () { throw new RuntimeError('Variable "category_item" does not exist.', 165, $this->source); })()), (isset($context["all_categories"]) || array_key_exists("all_categories", $context) ? $context["all_categories"] : (function () { throw new RuntimeError('Variable "all_categories" does not exist.', 165, $this->source); })()))) {
// line 166
echo "\t\t\t\t\t\t\t";
$context["all_categories"] = twig_array_merge($this->sandbox->ensureToStringAllowed((isset($context["all_categories"]) || array_key_exists("all_categories", $context) ? $context["all_categories"] : (function () { throw new RuntimeError('Variable "all_categories" does not exist.', 166, $this->source); })()), 166, $this->source), [0 => (isset($context["category_item"]) || array_key_exists("category_item", $context) ? $context["category_item"] : (function () { throw new RuntimeError('Variable "category_item" does not exist.', 166, $this->source); })())]);
// line 167
echo "\t\t\t\t\t\t";
}
// line 168
echo "\t\t\t\t\t";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['cate'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 169
echo "\t\t\t\t";
}
// line 170
echo "\t\t\t\t";
// line 171
echo "\t\t\t\t<div class=\"ec-itemNav__listSp\">
<div class=\"ec-itemNav gnavi__list_sp\">
\t\t\t\t\t\t<span class=\"ec-itemNav-dropdown js-dropdown\">
\t\t\t\t\t\t\t選択してください<span class=\"dli-chevron-down\"></span>
\t\t\t\t\t\t</span>
\t\t\t\t\t\t";
// line 177
echo "\t\t\t\t\t\t";
// line 194
echo " </div>
\t\t\t\t</div>
\t\t\t\t";
// line 198
echo "\t\t\t\t<ul class=\"ec-topicpath ec-topicpath__listPc\">
\t\t\t\t\t";
// line 199
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["all_categories"]) || array_key_exists("all_categories", $context) ? $context["all_categories"] : (function () { throw new RuntimeError('Variable "all_categories" does not exist.', 199, $this->source); })()));
foreach ($context['_seq'] as $context["loop_index"] => $context["category"]) {
// line 200
echo "\t\t\t\t\t\t";
if (($context["loop_index"] == 0)) {
// line 201
echo "\t\t\t\t\t\t\t<li class=\"ec-topicpath__item dropdown__list_sp";
if ((twig_get_attribute($this->env, $this->source, $context["category"], "id", [], "any", false, false, true, 201) == twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 201, $this->source); })()), "request", [], "any", false, false, true, 201), "query", [], "any", false, false, true, 201), "get", [0 => "category_id"], "method", false, false, true, 201))) {
echo " ec-topicpath__item--active";
}
echo "\">
\t\t\t\t\t\t\t\t<a href=\"/products/list?category_id=";
// line 202
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["category"], "id", [], "any", false, false, true, 202), 202, $this->source), "html", null, true);
echo "\">全て</a>
\t\t\t\t\t\t\t</li>
\t\t\t\t\t\t";
} else {
// line 205
echo "\t\t\t\t\t\t\t<li class=\"ec-topicpath__item dropdown__list_sp";
if ((twig_get_attribute($this->env, $this->source, $context["category"], "id", [], "any", false, false, true, 205) == twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 205, $this->source); })()), "request", [], "any", false, false, true, 205), "query", [], "any", false, false, true, 205), "get", [0 => "category_id"], "method", false, false, true, 205))) {
echo " ec-topicpath__item--active";
}
echo "\">
\t\t\t\t\t\t\t\t<a href=\"/products/list?category_id=";
// line 206
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["category"], "id", [], "any", false, false, true, 206), 206, $this->source), "html", null, true);
echo "\">";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["category"], "name", [], "any", false, false, true, 206), 206, $this->source), "html", null, true);
echo "</a>
\t\t\t\t\t\t\t</li>
\t\t\t\t\t\t";
}
// line 209
echo "\t\t\t\t\t";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['loop_index'], $context['category'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 210
echo "\t\t\t\t</ul>
\t\t\t</div>
\t\t\t<div class=\"ec-searchnavRole__infos\">
\t\t\t\t<div class=\"ec-searchnavRole__counter\">
\t\t\t\t\t";
// line 214
if ((twig_get_attribute($this->env, $this->source, (isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 214, $this->source); })()), "totalItemCount", [], "any", false, false, true, 214) > 0)) {
// line 215
echo "\t\t\t\t\t\t";
echo $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("<span class=\"ec-font-bold\">%count%件</span><span>の商品が見つかりました</span>", ["%count%" => twig_get_attribute($this->env, $this->source, (isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 215, $this->source); })()), "totalItemCount", [], "any", false, false, true, 215)]);
echo "
\t\t\t\t\t";
} else {
// line 217
echo "\t\t\t\t\t\t<span>";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("お探しの商品は見つかりませんでした"), "html", null, true);
echo "</span>
\t\t\t\t\t";
}
// line 219
echo "\t\t\t\t</div>
\t\t\t\t";
// line 220
if ((twig_get_attribute($this->env, $this->source, (isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 220, $this->source); })()), "totalItemCount", [], "any", false, false, true, 220) > 0)) {
// line 221
echo "\t\t\t\t\t<div class=\"ec-searchnavRole__actions\">
\t\t\t\t\t\t<div
\t\t\t\t\t\t\tclass=\"ec-select\">
\t\t\t\t\t\t\t";
// line 225
echo "\t\t\t\t\t\t\t";
echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["search_form"]) || array_key_exists("search_form", $context) ? $context["search_form"] : (function () { throw new RuntimeError('Variable "search_form" does not exist.', 225, $this->source); })()), "orderby", [], "any", false, false, true, 225), 225, $this->source), 'widget', ["id" => "", "attr" => ["class" => "order-by"]]);
echo "
\t\t\t\t\t\t</div>
\t\t\t\t\t</div>
\t\t\t\t";
}
// line 229
echo "\t\t\t</div>
\t\t</div>
\t\t";
// line 231
if ((twig_get_attribute($this->env, $this->source, (isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 231, $this->source); })()), "totalItemCount", [], "any", false, false, true, 231) > 0)) {
// line 232
echo "\t\t <div class=\"ec-pagerRole\">
\t\t\t\t";
// line 233
$this->loadTemplate("pager.twig", "Product/list.twig", 233)->display(twig_array_merge($context, ["pages" => twig_get_attribute($this->env, $this->source, (isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 233, $this->source); })()), "paginationData", [], "any", false, false, true, 233)]));
// line 234
echo "\t\t\t</div>
\t\t\t<div class=\"ec-shelfRole\">
\t\t\t\t<ul class=\"ec-shelfGrid\">
\t\t\t\t\t";
// line 237
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 237, $this->source); })()));
$context['loop'] = [
'parent' => $context['_parent'],
'index0' => 0,
'index' => 1,
'first' => true,
];
if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
$length = count($context['_seq']);
$context['loop']['revindex0'] = $length - 1;
$context['loop']['revindex'] = $length;
$context['loop']['length'] = $length;
$context['loop']['last'] = 1 === $length;
}
foreach ($context['_seq'] as $context["_key"] => $context["Product"]) {
// line 238
echo "\t\t\t\t\t\t<li class=\"ec-shelfGrid__item\">
\t\t\t\t\t\t\t<a href=\"";
// line 239
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("product_detail", ["id" => twig_get_attribute($this->env, $this->source, $context["Product"], "id", [], "any", false, false, true, 239)]), "html", null, true);
echo "\">
\t\t\t\t\t\t\t\t<p class=\"ec-shelfGrid__item-image\">
\t\t\t\t\t\t\t\t\t<img src=\"";
// line 241
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl($this->extensions['Eccube\Twig\Extension\EccubeExtension']->getNoImageProduct($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Product"], "main_list_image", [], "any", false, false, true, 241), 241, $this->source)), "save_image"), "html", null, true);
echo "\" alt=\"";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Product"], "name", [], "any", false, false, true, 241), 241, $this->source), "html", null, true);
echo "\" ";
if ((twig_get_attribute($this->env, $this->source, $context["loop"], "index", [], "any", false, false, true, 241) > 5)) {
echo " loading=\"lazy\" ";
}
echo ">
</p>
\t\t\t\t\t\t\t\t<div class=\"ec-shelfGrid__item_border\"></div>
\t\t\t\t\t\t\t\t<p class=\"ec-shelfGrid__item-title\">";
// line 244
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Product"], "name", [], "any", false, false, true, 244), 244, $this->source), "html", null, true);
echo "</p>
\t\t\t\t\t\t\t\t";
// line 245
if (twig_get_attribute($this->env, $this->source, $context["Product"], "description_list", [], "any", false, false, true, 245)) {
// line 246
echo "\t\t\t\t\t\t\t\t\t<p>";
echo twig_nl2br($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Product"], "description_list", [], "any", false, false, true, 246), 246, $this->source));
echo "</p>
\t\t\t\t\t\t\t\t";
}
// line 248
echo "\t\t\t\t\t\t\t\t<p class=\"price02-default\">
\t\t\t\t\t\t\t\t\t";
// line 249
if (twig_get_attribute($this->env, $this->source, $context["Product"], "hasProductClass", [], "any", false, false, true, 249)) {
// line 250
echo "\t\t\t\t\t\t\t\t\t\t";
if ((twig_get_attribute($this->env, $this->source, $context["Product"], "getPrice02Min", [], "any", false, false, true, 250) == twig_get_attribute($this->env, $this->source, $context["Product"], "getPrice02Max", [], "any", false, false, true, 250))) {
// line 251
echo "\t\t\t\t\t\t\t\t\t\t\t";
echo twig_escape_filter($this->env, $this->extensions['Eccube\Twig\Extension\EccubeExtension']->getPriceFilter($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Product"], "getPrice02IncTaxMin", [], "any", false, false, true, 251), 251, $this->source)), "html", null, true);
echo "
\t\t\t\t\t\t\t\t\t\t";
} else {
// line 253
echo "\t\t\t\t\t\t\t\t\t\t\t";
echo twig_escape_filter($this->env, $this->extensions['Eccube\Twig\Extension\EccubeExtension']->getPriceFilter($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Product"], "getPrice02IncTaxMin", [], "any", false, false, true, 253), 253, $this->source)), "html", null, true);
echo "
\t\t\t\t\t\t\t\t\t\t\t~
\t\t\t\t\t\t\t\t\t\t\t";
// line 255
echo twig_escape_filter($this->env, $this->extensions['Eccube\Twig\Extension\EccubeExtension']->getPriceFilter($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Product"], "getPrice02IncTaxMax", [], "any", false, false, true, 255), 255, $this->source)), "html", null, true);
echo "
\t\t\t\t\t\t\t\t\t\t";
}
// line 257
echo "\t\t\t\t\t\t\t\t\t";
} else {
// line 258
echo "\t\t\t\t\t\t\t\t\t\t";
echo twig_escape_filter($this->env, $this->extensions['Eccube\Twig\Extension\EccubeExtension']->getPriceFilter($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["Product"], "getPrice02IncTaxMin", [], "any", false, false, true, 258), 258, $this->source)), "html", null, true);
echo "
\t\t\t\t\t\t\t\t\t";
}
// line 260
echo "\t\t\t\t\t\t\t\t\t";
if ( !twig_get_attribute($this->env, $this->source, $context["Product"], "stock_find", [], "any", false, false, true, 260)) {
echo "<span>SOLD OUT</span>";
}
// line 261
echo "\t\t\t\t\t\t\t\t</p>
\t\t\t\t\t\t\t\t";
// line 262
if (( !(null === twig_get_attribute($this->env, $this->source, $context["Product"], "getPrice01Min", [], "any", false, false, true, 262)) && (twig_get_attribute($this->env, $this->source, $context["Product"], "getPrice01IncTaxMin", [], "any", false, false, true, 262) == twig_get_attribute($this->env, $this->source, $context["Product"], "getPrice01IncTaxMax", [], "any", false, false, true, 262)))) {
// line 263
echo "\t\t\t\t\t\t\t\t\t<div class=\"c_sale\"><span class=\"price01-default\">SALE</span></div>
\t\t\t\t\t\t\t\t";
}
// line 265
echo "\t\t\t\t\t\t\t</a>
";
// line 266
echo $this->extensions['Eccube\Twig\Extension\IgnoreTwigSandboxErrorExtension']->twig_include($this->env, $context, "Block/product_list_favorite_block.twig");
echo "
\t\t\t\t\t\t\t";
// line 302
echo "\t\t\t\t\t\t</li>
\t\t\t\t\t";
++$context['loop']['index0'];
++$context['loop']['index'];
$context['loop']['first'] = false;
if (isset($context['loop']['length'])) {
--$context['loop']['revindex0'];
--$context['loop']['revindex'];
$context['loop']['last'] = 0 === $context['loop']['revindex0'];
}
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['Product'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 304
echo "\t\t\t\t</ul>
\t\t\t<div class=\"ec-pagerRole\">
\t\t\t\t";
// line 306
$this->loadTemplate("pager.twig", "Product/list.twig", 306)->display(twig_array_merge($context, ["pages" => twig_get_attribute($this->env, $this->source, (isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 306, $this->source); })()), "paginationData", [], "any", false, false, true, 306)]));
// line 307
echo "\t\t\t</div>
\t\t\t</div>
\t\t\t<div class=\"ec-modal\">
\t\t\t\t<div class=\"ec-modal-overlay\">
\t\t\t\t\t<div class=\"ec-modal-wrap\">
\t\t\t\t\t\t<span class=\"ec-modal-close\">
\t\t\t\t\t\t\t<span class=\"ec-icon\"><img src=\"";
// line 313
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("assets/icon/cross-dark.svg"), "html", null, true);
echo "\" alt=\"\"/></span>
\t\t\t\t\t\t</span>
\t\t\t\t\t\t<div id=\"ec-modal-header\" class=\"text-center\">";
// line 315
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートに追加しました。"), "html", null, true);
echo "</div>
\t\t\t\t\t\t<div class=\"ec-modal-box\">
\t\t\t\t\t\t\t<div class=\"ec-role\">
\t\t\t\t\t\t\t\t<span class=\"ec-inlineBtn--cancel\">";
// line 318
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("お買い物を続ける"), "html", null, true);
echo "</span>
\t\t\t\t\t\t\t\t<a href=\"";
// line 319
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("cart");
echo "\" class=\"ec-inlineBtn--action\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートへ進む"), "html", null, true);
echo "</a>
\t\t\t\t\t\t\t</div>
\t\t\t\t\t\t</div>
\t\t\t\t\t</div>
\t\t\t\t</div>
\t\t\t</div>
\t\t";
}
// line 326
echo "\t";
}
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
public function getTemplateName()
{
return "Product/list.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 685 => 326, 673 => 319, 669 => 318, 663 => 315, 658 => 313, 650 => 307, 648 => 306, 644 => 304, 629 => 302, 625 => 266, 622 => 265, 618 => 263, 616 => 262, 613 => 261, 608 => 260, 602 => 258, 599 => 257, 594 => 255, 588 => 253, 582 => 251, 579 => 250, 577 => 249, 574 => 248, 568 => 246, 566 => 245, 562 => 244, 550 => 241, 545 => 239, 542 => 238, 525 => 237, 520 => 234, 518 => 233, 515 => 232, 513 => 231, 509 => 229, 501 => 225, 496 => 221, 494 => 220, 491 => 219, 485 => 217, 479 => 215, 477 => 214, 471 => 210, 465 => 209, 457 => 206, 450 => 205, 444 => 202, 437 => 201, 434 => 200, 430 => 199, 427 => 198, 422 => 194, 420 => 177, 413 => 171, 411 => 170, 408 => 169, 402 => 168, 399 => 167, 396 => 166, 393 => 165, 390 => 164, 385 => 163, 382 => 162, 379 => 161, 376 => 159, 373 => 158, 367 => 157, 364 => 156, 361 => 155, 358 => 154, 355 => 153, 350 => 152, 347 => 151, 344 => 149, 341 => 148, 336 => 144, 319 => 142, 315 => 141, 311 => 139, 305 => 136, 302 => 135, 300 => 134, 296 => 132, 293 => 131, 282 => 126, 276 => 125, 273 => 124, 268 => 123, 266 => 122, 256 => 114, 246 => 113, 217 => 93, 207 => 86, 176 => 58, 148 => 32, 134 => 31, 126 => 30, 109 => 29, 105 => 27, 95 => 26, 75 => 15, 65 => 14, 54 => 11, 52 => 13, 39 => 11,);
}
public function getSourceContext()
{
return new Source("{#
This file is part of EC-CUBE
Copyright(c) EC-CUBE CO.,LTD. All Rights Reserved.
http://www.ec-cube.co.jp/
For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.
#}
{% extends 'default_frame.twig' %}
{% set body_class = 'product_page' %}
{% block stylesheet %}
<style>
.c_sale {
position: absolute;
top: 0;
background-color: red;
padding: 4px 8px;
color: #fff;
font-size: 12px;
}
</style>
{% endblock %}
{% block javascript %}
\t<script>
\t eccube.productsClassCategories = {
\t {% for Product in pagination %}
\t \"{{ Product.id|escape('js') }}\": {{ class_categories_as_json(Product)|raw }}{% if loop.last == false %}, {% endif %}
\t {% endfor %}
\t };
\t\t\t\t\t\t\t\t\t
\$(function() {
// 表示件数を変更
\$('.disp-number').change(function() {
var dispNumber = \$(this).val();
\$('#disp_number').val(dispNumber);
\$('#pageno').val(1);
\$(\"#form1\").submit();
});
// 並び順を変更
\$('.order-by').change(function() {
var orderBy = \$(this).val();
\$('#pageno').val(1);
\$('#orderby').val(orderBy);
\$(\"#form1\").submit();
});
\$('.add-cart').on('click', function(e) {
var \$form = \$(this).parents('li').find('form');
// 個数フォームのチェック
var \$quantity = \$form.parent().find('.quantity');
if (\$quantity.val() < 1) {
\$quantity[0].setCustomValidity('{{ '1以上で入力してください。'|trans }}');
setTimeout(function() {
loadingOverlay('hide');
}, 100);
return true;
} else {
\$quantity[0].setCustomValidity('');
}
e.preventDefault();
\$.ajax({
url: \$form.attr('action'),
type: \$form.attr('method'),
data: \$form.serialize(),
dataType: 'json',
beforeSend: function(xhr, settings) {
// Buttonを無効にする
\$('.add-cart').prop('disabled', true);
}
}).done(function(data) {
// レスポンス内のメッセージをalertで表示
\$.each(data.messages, function() {
\$('#ec-modal-header').text(this);
});
\$('.ec-modal').show()
// カートブロックを更新する
\$.ajax({
url: '{{ url('block_cart') }}',
type: 'GET',
dataType: 'html'
}).done(function(html) {
\$('.ec-headerRole__cart').html(html);
});
}).fail(function(data) {
alert('{{ 'カートへの追加に失敗しました。'|trans }}');
}).always(function(data) {
// Buttonを有効にする
\$('.add-cart').prop('disabled', false);
});
});
});
\t\t\t\t\t\t\t\t\t
\t\t\$('.ec-modal-wrap').on('click', function(e) {
\t\t // モーダル内の処理は外側にバブリングさせない
\t\t e.stopPropagation();
\t\t});
\t\t\$('.ec-modal-overlay, .ec-modal, .ec-modal-close, .ec-inlineBtn--cancel').on('click', function() {
\t\t \$('.ec-modal').hide()
\t\t});
\t\t\t\t\t\t\t\t\t
\t\t\t\t\t\t\t\t\t
\t</script>
{% endblock %}
{% block main %}
\t<div class=\"ec-productRole\">
\t\t<ol class=\"breadcrumb\" itemscope itemtype=\"https://schema.org/BreadcrumbList\">
\t\t\t<li itemprop=\"itemListElement\" itemscope itemtype=\"https://schema.org/ListItem\">
\t\t\t\t<a itemprop=\"item\" href=\"/\">
\t\t\t\t\t<span itemprop=\"name\">TOP</span>
\t\t\t\t</a>
\t\t\t\t<meta itemprop=\"position\" content=\"1\"/>
\t\t\t</li>
\t\t\t{% if Category is not null %}
\t\t\t\t{% for Path in Category.path %}
\t\t\t\t\t<li itemprop=\"itemListElement\" itemscope itemtype=\"https://schema.org/ListItem\">
\t\t\t\t\t\t<a itemprop=\"item\" href=\"{{ url('product_list') }}?category_id={{ Path.id }}\">
\t\t\t\t\t\t\t<span itemprop=\"name\">{{ Path.name }}</span>
\t\t\t\t\t\t</a>
\t\t\t\t\t\t<meta itemprop=\"position\" content=\"2\"/>
\t\t\t\t\t</li>
\t\t\t\t{% endfor %}
\t\t\t{% endif %}
\t\t</ol>
\t</div>
\t{% if search_form.category_id.vars.errors|length > 0 %}
\t\t<div class=\"ec-searchnavRole\">
\t\t\t<p class=\"errormsg text-danger\">{{ 'ご指定のカテゴリは存在しません'|trans }}</p>
\t\t</div>
\t{% else %}
\t\t<div class=\"ec-searchnavRole\">
\t\t\t<form name=\"form1\" id=\"form1\" method=\"get\" action=\"?\">
\t\t\t\t{% for item in search_form %}
\t\t\t\t\t<input type=\"hidden\" id=\"{{ item.vars.id }}\" name=\"{{ item.vars.full_name }}\" {% if item.vars.value is not empty %} value=\"{{ item.vars.value }}\" {% endif %}/>
\t\t\t\t{% endfor %}
\t\t\t</form>
\t\t\t<div
\t\t\t\tclass=\"ec-searchnavRole__topicpath gnavi__list_sp\">
\t\t\t\t{# カテゴリー一覧 #}
\t\t\t\t{% set all_categories = [] %}
\t\t\t\t{# 親カテゴリーを追加 #}
\t\t\t\t{% if Category is not null and Category.path is not null %}
\t\t\t\t\t{% for Path in Category.path %}
\t\t\t\t\t\t{% set category_item = { 'id': Path.id, 'name': Path.name } %}
\t\t\t\t\t\t{% if category_item not in all_categories %}
\t\t\t\t\t\t\t{% set all_categories = all_categories | merge([category_item]) %}
\t\t\t\t\t\t{% endif %}
\t\t\t\t\t{% endfor %}
\t\t\t\t{% endif %}
\t\t\t\t{# 子カテゴリーを追加 #}
\t\t\t\t{% if Category is not null %}
\t\t\t\t\t{% set cate_childs = Category.getDescendants %}
\t\t\t\t\t{% for cate in cate_childs %}
\t\t\t\t\t\t{% set category_item = { 'id': cate.id, 'name': cate.name } %}
\t\t\t\t\t\t{% if category_item not in all_categories %}
\t\t\t\t\t\t\t{% set all_categories = all_categories | merge([category_item]) %}
\t\t\t\t\t\t{% endif %}
\t\t\t\t\t{% endfor %}
\t\t\t\t{% endif %}
\t\t\t\t{# カテゴリーリストSP #}
\t\t\t\t<div class=\"ec-itemNav__listSp\">
<div class=\"ec-itemNav gnavi__list_sp\">
\t\t\t\t\t\t<span class=\"ec-itemNav-dropdown js-dropdown\">
\t\t\t\t\t\t\t選択してください<span class=\"dli-chevron-down\"></span>
\t\t\t\t\t\t</span>
\t\t\t\t\t\t{# 全てのカテゴリーを表示 #}
\t\t\t\t\t\t{#
\t\t\t\t\t\t<div class=\"dropdown__lists_sp js-dropdown-contents\">
\t\t\t\t\t\t\t<ul class=\"ec-itemNav__nav\">
\t\t\t\t\t\t\t\t{% for loop_index, category in all_categories %}
\t\t\t\t\t\t\t\t\t{% if loop_index == 0 %}
\t\t\t\t\t\t\t\t\t\t<li class=\"ec-topicpath__item dropdown__list_sp{% if category.id == app.request.query.get('category_id') %} ec-topicpath__item--active{% endif %}\">
\t\t\t\t\t\t\t\t\t\t\t<a href=\"/products/list?category_id={{ category.id }}\">全て</a>
\t\t\t\t\t\t\t\t\t\t</li>
\t\t\t\t\t\t\t\t\t{% else %}
\t\t\t\t\t\t\t\t\t\t<li class=\"ec-topicpath__item dropdown__list_sp{% if category.id == app.request.query.get('category_id') %} ec-topicpath__item--active{% endif %}\">
\t\t\t\t\t\t\t\t\t\t\t<a href=\"/products/list?category_id={{ category.id }}\">{{ category.name }}</a>
\t\t\t\t\t\t\t\t\t\t</li>
\t\t\t\t\t\t\t\t\t{% endif %}
\t\t\t\t\t\t\t\t{% endfor %}
\t\t\t\t\t\t\t</ul>
\t\t\t\t\t\t</div>
\t\t\t\t\t\t#}
</div>
\t\t\t\t</div>
\t\t\t\t{# カテゴリーリストPC #}
\t\t\t\t<ul class=\"ec-topicpath ec-topicpath__listPc\">
\t\t\t\t\t{% for loop_index, category in all_categories %}
\t\t\t\t\t\t{% if loop_index == 0 %}
\t\t\t\t\t\t\t<li class=\"ec-topicpath__item dropdown__list_sp{% if category.id == app.request.query.get('category_id') %} ec-topicpath__item--active{% endif %}\">
\t\t\t\t\t\t\t\t<a href=\"/products/list?category_id={{ category.id }}\">全て</a>
\t\t\t\t\t\t\t</li>
\t\t\t\t\t\t{% else %}
\t\t\t\t\t\t\t<li class=\"ec-topicpath__item dropdown__list_sp{% if category.id == app.request.query.get('category_id') %} ec-topicpath__item--active{% endif %}\">
\t\t\t\t\t\t\t\t<a href=\"/products/list?category_id={{ category.id }}\">{{ category.name }}</a>
\t\t\t\t\t\t\t</li>
\t\t\t\t\t\t{% endif %}
\t\t\t\t\t{% endfor %}
\t\t\t\t</ul>
\t\t\t</div>
\t\t\t<div class=\"ec-searchnavRole__infos\">
\t\t\t\t<div class=\"ec-searchnavRole__counter\">
\t\t\t\t\t{% if pagination.totalItemCount > 0 %}
\t\t\t\t\t\t{{ '<span class=\"ec-font-bold\">%count%件</span><span>の商品が見つかりました</span>'|trans({ '%count%': pagination.totalItemCount })|raw }}
\t\t\t\t\t{% else %}
\t\t\t\t\t\t<span>{{ 'お探しの商品は見つかりませんでした'|trans }}</span>
\t\t\t\t\t{% endif %}
\t\t\t\t</div>
\t\t\t\t{% if pagination.totalItemCount > 0 %}
\t\t\t\t\t<div class=\"ec-searchnavRole__actions\">
\t\t\t\t\t\t<div
\t\t\t\t\t\t\tclass=\"ec-select\">
\t\t\t\t\t\t\t{# {{ form_widget(search_form.disp_number, {'id': '', 'attr': {'class': 'disp-number'}}) }}#}
\t\t\t\t\t\t\t{{ form_widget(search_form.orderby, {'id': '', 'attr': {'class': 'order-by'}}) }}
\t\t\t\t\t\t</div>
\t\t\t\t\t</div>
\t\t\t\t{% endif %}
\t\t\t</div>
\t\t</div>
\t\t{% if pagination.totalItemCount > 0 %}
\t\t <div class=\"ec-pagerRole\">
\t\t\t\t{% include \"pager.twig\" with {'pages': pagination.paginationData} %}
\t\t\t</div>
\t\t\t<div class=\"ec-shelfRole\">
\t\t\t\t<ul class=\"ec-shelfGrid\">
\t\t\t\t\t{% for Product in pagination %}
\t\t\t\t\t\t<li class=\"ec-shelfGrid__item\">
\t\t\t\t\t\t\t<a href=\"{{ url('product_detail', {'id': Product.id}) }}\">
\t\t\t\t\t\t\t\t<p class=\"ec-shelfGrid__item-image\">
\t\t\t\t\t\t\t\t\t<img src=\"{{ asset(Product.main_list_image|no_image_product, 'save_image') }}\" alt=\"{{ Product.name }}\" {% if loop.index > 5 %} loading=\"lazy\" {% endif %}>
</p>
\t\t\t\t\t\t\t\t<div class=\"ec-shelfGrid__item_border\"></div>
\t\t\t\t\t\t\t\t<p class=\"ec-shelfGrid__item-title\">{{ Product.name }}</p>
\t\t\t\t\t\t\t\t{% if Product.description_list %}
\t\t\t\t\t\t\t\t\t<p>{{ Product.description_list|raw|nl2br }}</p>
\t\t\t\t\t\t\t\t{% endif %}
\t\t\t\t\t\t\t\t<p class=\"price02-default\">
\t\t\t\t\t\t\t\t\t{% if Product.hasProductClass %}
\t\t\t\t\t\t\t\t\t\t{% if Product.getPrice02Min == Product.getPrice02Max %}
\t\t\t\t\t\t\t\t\t\t\t{{ Product.getPrice02IncTaxMin|price }}
\t\t\t\t\t\t\t\t\t\t{% else %}
\t\t\t\t\t\t\t\t\t\t\t{{ Product.getPrice02IncTaxMin|price }}
\t\t\t\t\t\t\t\t\t\t\t~
\t\t\t\t\t\t\t\t\t\t\t{{ Product.getPrice02IncTaxMax|price }}
\t\t\t\t\t\t\t\t\t\t{% endif %}
\t\t\t\t\t\t\t\t\t{% else %}
\t\t\t\t\t\t\t\t\t\t{{ Product.getPrice02IncTaxMin|price }}
\t\t\t\t\t\t\t\t\t{% endif %}
\t\t\t\t\t\t\t\t\t{% if not Product.stock_find %}<span>SOLD OUT</span>{% endif %}
\t\t\t\t\t\t\t\t</p>
\t\t\t\t\t\t\t\t{% if Product.getPrice01Min is not null and Product.getPrice01IncTaxMin == Product.getPrice01IncTaxMax %}
\t\t\t\t\t\t\t\t\t<div class=\"c_sale\"><span class=\"price01-default\">SALE</span></div>
\t\t\t\t\t\t\t\t{% endif %}
\t\t\t\t\t\t\t</a>
{{ include('Block/product_list_favorite_block.twig') }}
\t\t\t\t\t\t\t{#{% if Product.stock_find %}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {% set form = forms[Product.id] %}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t <form name=\"form{{ Product.id }}\" id=\"productForm{{ Product.id }}\" action=\"{{ url('product_add_cart', {id:Product.id}) }}\" method=\"post\">
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t <div class=\"ec-productRole__actions\">
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {% if form.classcategory_id1 is defined %}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t <div class=\"ec-select\">
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {{ form_widget(form.classcategory_id1) }}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {{ form_errors(form.classcategory_id1) }}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t </div>
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {% if form.classcategory_id2 is defined %}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t <div class=\"ec-select\">
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {{ form_widget(form.classcategory_id2) }}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {{ form_errors(form.classcategory_id2) }}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t </div>
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {% endif %}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {% endif %}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t <div class=\"ec-numberInput\"><span>{{ '数量'|trans }}</span>
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {{ form_widget(form.quantity, {'attr': {'class': 'quantity'}}) }}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {{ form_errors(form.quantity) }}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t </div>
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t </div>
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {{ form_rest(form) }}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t </form>
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t <div class=\"ec-productRole__btn\">
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t <button type=\"submit\" class=\"ec-blockBtn--action add-cart\" data-cartid=\"{{ Product.id }}\" form=\"productForm{{ Product.id }}\">
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {{ 'カートに入れる'|trans }}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t </button>
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t </div>
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {% else %}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t <div class=\"ec-productRole__btn\">
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t <button type=\"button\" class=\"ec-blockBtn--action\" disabled=\"disabled\">
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {{ 'ただいま品切れ中です。'|trans }}
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t </button>
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t </div>
\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {% endif %}#}
\t\t\t\t\t\t</li>
\t\t\t\t\t{% endfor %}
\t\t\t\t</ul>
\t\t\t<div class=\"ec-pagerRole\">
\t\t\t\t{% include \"pager.twig\" with {'pages': pagination.paginationData} %}
\t\t\t</div>
\t\t\t</div>
\t\t\t<div class=\"ec-modal\">
\t\t\t\t<div class=\"ec-modal-overlay\">
\t\t\t\t\t<div class=\"ec-modal-wrap\">
\t\t\t\t\t\t<span class=\"ec-modal-close\">
\t\t\t\t\t\t\t<span class=\"ec-icon\"><img src=\"{{ asset('assets/icon/cross-dark.svg') }}\" alt=\"\"/></span>
\t\t\t\t\t\t</span>
\t\t\t\t\t\t<div id=\"ec-modal-header\" class=\"text-center\">{{ 'カートに追加しました。'|trans }}</div>
\t\t\t\t\t\t<div class=\"ec-modal-box\">
\t\t\t\t\t\t\t<div class=\"ec-role\">
\t\t\t\t\t\t\t\t<span class=\"ec-inlineBtn--cancel\">{{ 'お買い物を続ける'|trans }}</span>
\t\t\t\t\t\t\t\t<a href=\"{{ url('cart') }}\" class=\"ec-inlineBtn--action\">{{ 'カートへ進む'|trans }}</a>
\t\t\t\t\t\t\t</div>
\t\t\t\t\t\t</div>
\t\t\t\t\t</div>
\t\t\t\t</div>
\t\t\t</div>
\t\t{% endif %}
\t{% endif %}
{% endblock %}", "Product/list.twig", "/home/c9635817/public_html/attrait-shop.com/app/template/default/Product/list.twig");
}
public function checkSecurity()
{
static $tags = array("set" => 13, "for" => 29, "if" => 30, "include" => 233);
static $filters = array("escape" => 30, "raw" => 30, "trans" => 58, "length" => 134, "merge" => 155, "no_image_product" => 241, "nl2br" => 246, "price" => 251);
static $functions = array("class_categories_as_json" => 30, "url" => 86, "form_widget" => 225, "asset" => 241, "include" => 266);
try {
$this->sandbox->checkSecurity(
['set', 'for', 'if', 'include'],
['escape', 'raw', 'trans', 'length', 'merge', 'no_image_product', 'nl2br', 'price'],
['class_categories_as_json', 'url', 'form_widget', 'asset', 'include'],
$this->source
);
} catch (SecurityError $e) {
$e->setSourceContext($this->source);
if ($e instanceof SecurityNotAllowedTagError && isset($tags[$e->getTagName()])) {
$e->setTemplateLine($tags[$e->getTagName()]);
} elseif ($e instanceof SecurityNotAllowedFilterError && isset($filters[$e->getFilterName()])) {
$e->setTemplateLine($filters[$e->getFilterName()]);
} elseif ($e instanceof SecurityNotAllowedFunctionError && isset($functions[$e->getFunctionName()])) {
$e->setTemplateLine($functions[$e->getFunctionName()]);
}
throw $e;
}
}
}