var/cache/dev/twig/09/0998fd2b6dae66dd6915a65fcd2b59e8.php line 41

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\SandboxExtension;
  6. use Twig\Markup;
  7. use Twig\Sandbox\SecurityError;
  8. use Twig\Sandbox\SecurityNotAllowedTagError;
  9. use Twig\Sandbox\SecurityNotAllowedFilterError;
  10. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  11. use Twig\Source;
  12. use Twig\Template;
  13. /* Product/list.twig */
  14. class __TwigTemplate_b64d2eed0b0d5a2876351f4a02910d35 extends \Eccube\Twig\Template
  15. {
  16.     private $source;
  17.     private $macros = [];
  18.     public function __construct(Environment $env)
  19.     {
  20.         parent::__construct($env);
  21.         $this->source $this->getSourceContext();
  22.         $this->blocks = [
  23.             'javascript' => [$this'block_javascript'],
  24.             'main' => [$this'block_main'],
  25.         ];
  26.         $this->sandbox $this->env->getExtension('\Twig\Extension\SandboxExtension');
  27.         $this->checkSecurity();
  28.     }
  29.     protected function doGetParent(array $context)
  30.     {
  31.         // line 11
  32.         return "default_frame.twig";
  33.     }
  34.     protected function doDisplay(array $context, array $blocks = [])
  35.     {
  36.         $macros $this->macros;
  37.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  38.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""Product/list.twig"));
  39.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  40.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""Product/list.twig"));
  41.         // line 13
  42.         $context["body_class"] = "product_page";
  43.         // line 11
  44.         $this->parent $this->loadTemplate("default_frame.twig""Product/list.twig"11);
  45.         $this->parent->display($contextarray_merge($this->blocks$blocks));
  46.         
  47.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  48.         
  49.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  50.     }
  51.     // line 15
  52.     public function block_javascript($context, array $blocks = [])
  53.     {
  54.         $macros $this->macros;
  55.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  56.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""javascript"));
  57.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  58.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""javascript"));
  59.         // line 16
  60.         echo "    <script>
  61.         eccube.productsClassCategories = {
  62.             ";
  63.         // line 18
  64.         $context['_parent'] = $context;
  65.         $context['_seq'] = twig_ensure_traversable((isset($context["pagination"]) || array_key_exists("pagination"$context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.'18$this->source); })()));
  66.         $context['loop'] = [
  67.           'parent' => $context['_parent'],
  68.           'index0' => 0,
  69.           'index'  => 1,
  70.           'first'  => true,
  71.         ];
  72.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  73.             $length count($context['_seq']);
  74.             $context['loop']['revindex0'] = $length 1;
  75.             $context['loop']['revindex'] = $length;
  76.             $context['loop']['length'] = $length;
  77.             $context['loop']['last'] = === $length;
  78.         }
  79.         foreach ($context['_seq'] as $context["_key"] => $context["Product"]) {
  80.             // line 19
  81.             echo "            \"";
  82.             echo twig_escape_filter($this->envtwig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "id", [], "any"falsefalsetrue19), 19$this->source), "js"), "html"nulltrue);
  83.             echo "\": ";
  84.             echo $this->extensions['Eccube\Twig\Extension\EccubeExtension']->getClassCategoriesAsJson($this->sandbox->ensureToStringAllowed($context["Product"], 19$this->source));
  85.             if ((twig_get_attribute($this->env$this->source$context["loop"], "last", [], "any"falsefalsetrue19) == false)) {
  86.                 echo ", ";
  87.             }
  88.             // line 20
  89.             echo "            ";
  90.             ++$context['loop']['index0'];
  91.             ++$context['loop']['index'];
  92.             $context['loop']['first'] = false;
  93.             if (isset($context['loop']['length'])) {
  94.                 --$context['loop']['revindex0'];
  95.                 --$context['loop']['revindex'];
  96.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  97.             }
  98.         }
  99.         $_parent $context['_parent'];
  100.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['Product'], $context['_parent'], $context['loop']);
  101.         $context array_intersect_key($context$_parent) + $_parent;
  102.         // line 21
  103.         echo "        };
  104.         \$(function() {
  105.             // 表示件数を変更
  106.             \$('.disp-number').change(function() {
  107.                 var dispNumber = \$(this).val();
  108.                 \$('#disp_number').val(dispNumber);
  109.                 \$('#pageno').val(1);
  110.                 \$(\"#form1\").submit();
  111.             });
  112.             // 並び順を変更
  113.             \$('.order-by').change(function() {
  114.                 var orderBy = \$(this).val();
  115.                 \$('#orderby').val(orderBy);
  116.                 \$('#pageno').val(1);
  117.                 \$(\"#form1\").submit();
  118.             });
  119.             \$('.add-cart').on('click', function(e) {
  120.                 var \$form = \$(this).parents('li').find('form');
  121.                 // 個数フォームのチェック
  122.                 var \$quantity = \$form.parent().find('.quantity');
  123.                 if (\$quantity.val() < 1) {
  124.                     \$quantity[0].setCustomValidity('";
  125.         // line 47
  126.         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("1以上で入力してください。"), "html"nulltrue);
  127.         echo "');
  128.                     setTimeout(function() {
  129.                         loadingOverlay('hide');
  130.                     }, 100);
  131.                     return true;
  132.                 } else {
  133.                     \$quantity[0].setCustomValidity('');
  134.                 }
  135.                 e.preventDefault();
  136.                 \$.ajax({
  137.                     url: \$form.attr('action'),
  138.                     type: \$form.attr('method'),
  139.                     data: \$form.serialize(),
  140.                     dataType: 'json',
  141.                     beforeSend: function(xhr, settings) {
  142.                         // Buttonを無効にする
  143.                         \$('.add-cart').prop('disabled', true);
  144.                     }
  145.                 }).done(function(data) {
  146.                     // レスポンス内のメッセージをalertで表示
  147.                     \$.each(data.messages, function() {
  148.                         \$('#ec-modal-header').text(this);
  149.                     });
  150.                     \$('.ec-modal').show()
  151.                     // カートブロックを更新する
  152.                     \$.ajax({
  153.                         url: '";
  154.         // line 75
  155.         echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("block_cart");
  156.         echo "',
  157.                         type: 'GET',
  158.                         dataType: 'html'
  159.                     }).done(function(html) {
  160.                         \$('.ec-headerRole__cart').html(html);
  161.                     });
  162.                 }).fail(function(data) {
  163.                     alert('";
  164.         // line 82
  165.         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートへの追加に失敗しました。"), "html"nulltrue);
  166.         echo "');
  167.                 }).always(function(data) {
  168.                     // Buttonを有効にする
  169.                     \$('.add-cart').prop('disabled', false);
  170.                 });
  171.             });
  172.         });
  173.         \$('.ec-modal-wrap').on('click', function(e) {
  174.             // モーダル内の処理は外側にバブリングさせない
  175.             e.stopPropagation();
  176.         });
  177.         \$('.ec-modal-overlay, .ec-modal, .ec-modal-close, .ec-inlineBtn--cancel').on('click', function() {
  178.             \$('.ec-modal').hide()
  179.         });
  180.     </script>
  181. ";
  182.         
  183.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  184.         
  185.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  186.     }
  187.     // line 100
  188.     public function block_main($context, array $blocks = [])
  189.     {
  190.         $macros $this->macros;
  191.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  192.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""main"));
  193.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  194.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""main"));
  195.         // line 101
  196.         echo "    ";
  197.         if ((twig_length_filter($this->envtwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->sourcetwig_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.'101$this->source); })()), "category_id", [], "any"falsefalsetrue101), "vars", [], "any"falsefalsetrue101), "errors", [], "any"falsefalsetrue101)) > 0)) {
  198.             // line 102
  199.             echo "        <div class=\"ec-searchnavRole\">
  200.             <p class=\"errormsg text-danger\">";
  201.             // line 103
  202.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("ご指定のカテゴリは存在しません"), "html"nulltrue);
  203.             echo "</p>
  204.         </div>
  205.     ";
  206.         } else {
  207.             // line 106
  208.             echo "        <div class=\"ec-searchnavRole\">
  209.             <form name=\"form1\" id=\"form1\" method=\"get\" action=\"?\">
  210.                 ";
  211.             // line 108
  212.             $context['_parent'] = $context;
  213.             $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.'108$this->source); })()));
  214.             foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
  215.                 // line 109
  216.                 echo "                    <input type=\"hidden\" id=\"";
  217.                 echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["item"], "vars", [], "any"falsefalsetrue109), "id", [], "any"falsefalsetrue109), 109$this->source), "html"nulltrue);
  218.                 echo "\"
  219.                            name=\"";
  220.                 // line 110
  221.                 echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["item"], "vars", [], "any"falsefalsetrue110), "full_name", [], "any"falsefalsetrue110), 110$this->source), "html"nulltrue);
  222.                 echo "\"
  223.                            ";
  224.                 // line 111
  225.                 if ( !twig_test_empty(twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["item"], "vars", [], "any"falsefalsetrue111), "value", [], "any"falsefalsetrue111))) {
  226.                     echo "value=\"";
  227.                     echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["item"], "vars", [], "any"falsefalsetrue111), "value", [], "any"falsefalsetrue111), 111$this->source), "html"nulltrue);
  228.                     echo "\" ";
  229.                 }
  230.                 echo "/>
  231.                 ";
  232.             }
  233.             $_parent $context['_parent'];
  234.             unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
  235.             $context array_intersect_key($context$_parent) + $_parent;
  236.             // line 113
  237.             echo "            </form>
  238.             <div class=\"ec-searchnavRole__topicpath\">
  239.                 <ol class=\"ec-topicpath\">
  240.                     <li class=\"ec-topicpath__item\"><a href=\"";
  241.             // line 116
  242.             echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("product_list");
  243.             echo "\">";
  244.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("全て"), "html"nulltrue);
  245.             echo "</a>
  246.                     </li>
  247.                     ";
  248.             // line 118
  249.             if ( !(null === (isset($context["Category"]) || array_key_exists("Category"$context) ? $context["Category"] : (function () { throw new RuntimeError('Variable "Category" does not exist.'118$this->source); })()))) {
  250.                 // line 119
  251.                 echo "                        ";
  252.                 $context['_parent'] = $context;
  253.                 $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.'119$this->source); })()), "path", [], "any"falsefalsetrue119));
  254.                 $context['loop'] = [
  255.                   'parent' => $context['_parent'],
  256.                   'index0' => 0,
  257.                   'index'  => 1,
  258.                   'first'  => true,
  259.                 ];
  260.                 if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  261.                     $length count($context['_seq']);
  262.                     $context['loop']['revindex0'] = $length 1;
  263.                     $context['loop']['revindex'] = $length;
  264.                     $context['loop']['length'] = $length;
  265.                     $context['loop']['last'] = === $length;
  266.                 }
  267.                 foreach ($context['_seq'] as $context["_key"] => $context["Path"]) {
  268.                     // line 120
  269.                     echo "                            <li class=\"ec-topicpath__divider\">|</li>
  270.                             <li class=\"ec-topicpath__item";
  271.                     // line 121
  272.                     if (twig_get_attribute($this->env$this->source$context["loop"], "last", [], "any"falsefalsetrue121)) {
  273.                         echo "--active";
  274.                     }
  275.                     echo "\"><a
  276.                                         href=\"";
  277.                     // line 122
  278.                     echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("product_list");
  279.                     echo "?category_id=";
  280.                     echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Path"], "id", [], "any"falsefalsetrue122), 122$this->source), "html"nulltrue);
  281.                     echo "\">";
  282.                     echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Path"], "name", [], "any"falsefalsetrue122), 122$this->source), "html"nulltrue);
  283.                     echo "</a>
  284.                             </li>
  285.                         ";
  286.                     ++$context['loop']['index0'];
  287.                     ++$context['loop']['index'];
  288.                     $context['loop']['first'] = false;
  289.                     if (isset($context['loop']['length'])) {
  290.                         --$context['loop']['revindex0'];
  291.                         --$context['loop']['revindex'];
  292.                         $context['loop']['last'] = === $context['loop']['revindex0'];
  293.                     }
  294.                 }
  295.                 $_parent $context['_parent'];
  296.                 unset($context['_seq'], $context['_iterated'], $context['_key'], $context['Path'], $context['_parent'], $context['loop']);
  297.                 $context array_intersect_key($context$_parent) + $_parent;
  298.                 // line 125
  299.                 echo "                    ";
  300.             }
  301.             // line 126
  302.             echo "                    ";
  303.             if ((twig_get_attribute($this->env$this->sourcetwig_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.'126$this->source); })()), "vars", [], "any"falsefalsetrue126), "value", [], "any"falsefalsetrue126) && twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->sourcetwig_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.'126$this->source); })()), "vars", [], "any"falsefalsetrue126), "value", [], "any"falsefalsetrue126), "name", [], "any"falsefalsetrue126))) {
  304.                 // line 127
  305.                 echo "                        <li class=\"ec-topicpath__divider\">|</li>
  306.                         <li class=\"ec-topicpath__item\">";
  307.                 // line 128
  308.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("「%name%」の検索結果", ["%name%" => twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->sourcetwig_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.'128$this->source); })()), "vars", [], "any"falsefalsetrue128), "value", [], "any"falsefalsetrue128), "name", [], "any"falsefalsetrue128)]), "html"nulltrue);
  309.                 echo "</li>
  310.                     ";
  311.             }
  312.             // line 130
  313.             echo "                </ol>
  314.             </div>
  315.             <div class=\"ec-searchnavRole__infos\">
  316.                 <div class=\"ec-searchnavRole__counter\">
  317.                     ";
  318.             // line 134
  319.             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.'134$this->source); })()), "totalItemCount", [], "any"falsefalsetrue134) > 0)) {
  320.                 // line 135
  321.                 echo "                        ";
  322.                 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.'135$this->source); })()), "totalItemCount", [], "any"falsefalsetrue135)]);
  323.                 echo "
  324.                     ";
  325.             } else {
  326.                 // line 137
  327.                 echo "                        <span>";
  328.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("お探しの商品は見つかりませんでした"), "html"nulltrue);
  329.                 echo "</span>
  330.                     ";
  331.             }
  332.             // line 139
  333.             echo "                </div>
  334.                 ";
  335.             // line 140
  336.             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.'140$this->source); })()), "totalItemCount", [], "any"falsefalsetrue140) > 0)) {
  337.                 // line 141
  338.                 echo "                    <div class=\"ec-searchnavRole__actions\">
  339.                         <div class=\"ec-select\">
  340.                             ";
  341.                 // line 143
  342.                 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.'143$this->source); })()), "disp_number", [], "any"falsefalsetrue143), 143$this->source), 'widget', ["id" => """attr" => ["class" => "disp-number"]]);
  343.                 echo "
  344.                             ";
  345.                 // line 144
  346.                 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.'144$this->source); })()), "orderby", [], "any"falsefalsetrue144), 144$this->source), 'widget', ["id" => """attr" => ["class" => "order-by"]]);
  347.                 echo "
  348.                         </div>
  349.                     </div>
  350.                 ";
  351.             }
  352.             // line 148
  353.             echo "            </div>
  354.         </div>
  355.         ";
  356.             // line 150
  357.             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.'150$this->source); })()), "totalItemCount", [], "any"falsefalsetrue150) > 0)) {
  358.                 // line 151
  359.                 echo "            <div class=\"ec-shelfRole\">
  360.                 <ul class=\"ec-shelfGrid\">
  361.                     ";
  362.                 // line 153
  363.                 $context['_parent'] = $context;
  364.                 $context['_seq'] = twig_ensure_traversable((isset($context["pagination"]) || array_key_exists("pagination"$context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.'153$this->source); })()));
  365.                 $context['loop'] = [
  366.                   'parent' => $context['_parent'],
  367.                   'index0' => 0,
  368.                   'index'  => 1,
  369.                   'first'  => true,
  370.                 ];
  371.                 if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  372.                     $length count($context['_seq']);
  373.                     $context['loop']['revindex0'] = $length 1;
  374.                     $context['loop']['revindex'] = $length;
  375.                     $context['loop']['length'] = $length;
  376.                     $context['loop']['last'] = === $length;
  377.                 }
  378.                 foreach ($context['_seq'] as $context["_key"] => $context["Product"]) {
  379.                     // line 154
  380.                     echo "                        <li class=\"ec-shelfGrid__item\">
  381.                             <a href=\"";
  382.                     // line 155
  383.                     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"falsefalsetrue155)]), "html"nulltrue);
  384.                     echo "\">
  385.                                 ";
  386.                     // line 156
  387.                     if (twig_get_attribute($this->env$this->source$context["Product"], "stock_find", [], "any"falsefalsetrue156)) {
  388.                         // line 157
  389.                         echo "                                  <p class=\"ec-shelfGrid__item-image\">
  390.                                       <img src=\"";
  391.                         // line 158
  392.                         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"falsefalsetrue158), 158$this->source)), "save_image"), "html"nulltrue);
  393.                         echo "\" alt=\"";
  394.                         echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "name", [], "any"falsefalsetrue158), 158$this->source), "html"nulltrue);
  395.                         echo "\" ";
  396.                         if ((twig_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsetrue158) > 5)) {
  397.                             echo " loading=\"lazy\"";
  398.                         }
  399.                         echo ">
  400.                                   </p>
  401.                                   <p class=\"ec-shelfGrid__title\">";
  402.                         // line 160
  403.                         echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "name", [], "any"falsefalsetrue160), 160$this->source), "html"nulltrue);
  404.                         echo "</p>
  405.                                   ";
  406.                         // line 161
  407.                         if (twig_get_attribute($this->env$this->source$context["Product"], "description_list", [], "any"falsefalsetrue161)) {
  408.                             // line 162
  409.                             echo "                                      <p class=\"ec-shelfGrid__title\">";
  410.                             echo twig_nl2br($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "description_list", [], "any"falsefalsetrue162), 162$this->source));
  411.                             echo "</p>
  412.                                   ";
  413.                         }
  414.                         // line 164
  415.                         echo "                                  <p class=\"ec-shelfGrid__price\">
  416.                                       ";
  417.                         // line 165
  418.                         if (twig_get_attribute($this->env$this->source$context["Product"], "hasProductClass", [], "any"falsefalsetrue165)) {
  419.                             // line 166
  420.                             echo "                                          ";
  421.                             if ((twig_get_attribute($this->env$this->source$context["Product"], "getPrice02Min", [], "any"falsefalsetrue166) == twig_get_attribute($this->env$this->source$context["Product"], "getPrice02Max", [], "any"falsefalsetrue166))) {
  422.                                 // line 167
  423.                                 echo "                                              ";
  424.                                 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"falsefalsetrue167), 167$this->source)), "html"nulltrue);
  425.                                 echo "
  426.                                           ";
  427.                             } else {
  428.                                 // line 169
  429.                                 echo "                                              ";
  430.                                 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"falsefalsetrue169), 169$this->source)), "html"nulltrue);
  431.                                 echo " ~ ";
  432.                                 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"falsefalsetrue169), 169$this->source)), "html"nulltrue);
  433.                                 echo "
  434.                                           ";
  435.                             }
  436.                             // line 171
  437.                             echo "                                      ";
  438.                         } else {
  439.                             // line 172
  440.                             echo "                                          ";
  441.                             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"falsefalsetrue172), 172$this->source)), "html"nulltrue);
  442.                             echo "
  443.                                       ";
  444.                         }
  445.                         // line 174
  446.                         echo "                                  </p>
  447.                                 ";
  448.                     } else {
  449.                         // line 176
  450.                         echo "                                  <p class=\"ec-shelfGrid__item-image soldout\">
  451.                                       <img src=\"";
  452.                         // line 177
  453.                         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"falsefalsetrue177), 177$this->source)), "save_image"), "html"nulltrue);
  454.                         echo "\" alt=\"";
  455.                         echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "name", [], "any"falsefalsetrue177), 177$this->source), "html"nulltrue);
  456.                         echo "\" ";
  457.                         if ((twig_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsetrue177) > 5)) {
  458.                             echo " loading=\"lazy\"";
  459.                         }
  460.                         echo ">
  461.                                   </p>
  462.                                   <p class=\"ec-shelfGrid__title\">";
  463.                         // line 179
  464.                         echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "name", [], "any"falsefalsetrue179), 179$this->source), "html"nulltrue);
  465.                         echo "</p>
  466.                                   ";
  467.                         // line 180
  468.                         if (twig_get_attribute($this->env$this->source$context["Product"], "description_list", [], "any"falsefalsetrue180)) {
  469.                             // line 181
  470.                             echo "                                      <p class=\"ec-shelfGrid__title\">";
  471.                             echo twig_nl2br($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "description_list", [], "any"falsefalsetrue181), 181$this->source));
  472.                             echo "</p>
  473.                                   ";
  474.                         }
  475.                         // line 183
  476.                         echo "                                    <p class=\"ec-shelfGrid__price soldout\">SOLDOUT</p>
  477.                                 ";
  478.                     }
  479.                     // line 185
  480.                     echo "                            </a>
  481.                             ";
  482.                     // line 187
  483.                     if (twig_get_attribute($this->env$this->source$context["Product"], "stock_find", [], "any"falsefalsetrue187)) {
  484.                         // line 188
  485.                         echo "                                ";
  486.                         $context["form"] = twig_get_attribute($this->env$this->source, (isset($context["forms"]) || array_key_exists("forms"$context) ? $context["forms"] : (function () { throw new RuntimeError('Variable "forms" does not exist.'188$this->source); })()), twig_get_attribute($this->env$this->source$context["Product"], "id", [], "any"falsefalsetrue188), [], "array"falsefalsetrue188);
  487.                         // line 189
  488.                         echo "                                <form name=\"form";
  489.                         echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "id", [], "any"falsefalsetrue189), 189$this->source), "html"nulltrue);
  490.                         echo "\" id=\"productForm";
  491.                         echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "id", [], "any"falsefalsetrue189), 189$this->source), "html"nulltrue);
  492.                         echo "\" action=\"";
  493.                         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("product_add_cart", ["id" => twig_get_attribute($this->env$this->source$context["Product"], "id", [], "any"falsefalsetrue189)]), "html"nulltrue);
  494.                         echo "\" method=\"post\">
  495.                                     <div class=\"ec-productRole__actions\">
  496.                                         ";
  497.                         // line 191
  498.                         if (twig_get_attribute($this->env$this->source, ($context["form"] ?? null), "classcategory_id1", [], "any"truetruetrue191)) {
  499.                             // line 192
  500.                             echo "                                            <div class=\"ec-select\">
  501.                                                 ";
  502.                             // line 193
  503.                             echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source, (isset($context["form"]) || array_key_exists("form"$context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.'193$this->source); })()), "classcategory_id1", [], "any"falsefalsetrue193), 193$this->source), 'widget');
  504.                             echo "
  505.                                                 ";
  506.                             // line 194
  507.                             echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source, (isset($context["form"]) || array_key_exists("form"$context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.'194$this->source); })()), "classcategory_id1", [], "any"falsefalsetrue194), 194$this->source), 'errors');
  508.                             echo "
  509.                                             </div>
  510.                                             ";
  511.                             // line 196
  512.                             if (twig_get_attribute($this->env$this->source, ($context["form"] ?? null), "classcategory_id2", [], "any"truetruetrue196)) {
  513.                                 // line 197
  514.                                 echo "                                                <div class=\"ec-select\">
  515.                                                     ";
  516.                                 // line 198
  517.                                 echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source, (isset($context["form"]) || array_key_exists("form"$context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.'198$this->source); })()), "classcategory_id2", [], "any"falsefalsetrue198), 198$this->source), 'widget');
  518.                                 echo "
  519.                                                     ";
  520.                                 // line 199
  521.                                 echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source, (isset($context["form"]) || array_key_exists("form"$context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.'199$this->source); })()), "classcategory_id2", [], "any"falsefalsetrue199), 199$this->source), 'errors');
  522.                                 echo "
  523.                                                 </div>
  524.                                             ";
  525.                             }
  526.                             // line 202
  527.                             echo "                                        ";
  528.                         }
  529.                         // line 203
  530.                         echo "                                        <div class=\"ec-numberInput\"><span>";
  531.                         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("数量"), "html"nulltrue);
  532.                         echo "</span>
  533.                                             ";
  534.                         // line 204
  535.                         echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source, (isset($context["form"]) || array_key_exists("form"$context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.'204$this->source); })()), "quantity", [], "any"falsefalsetrue204), 204$this->source), 'widget', ["attr" => ["class" => "quantity"]]);
  536.                         echo "
  537.                                             ";
  538.                         // line 205
  539.                         echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source, (isset($context["form"]) || array_key_exists("form"$context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.'205$this->source); })()), "quantity", [], "any"falsefalsetrue205), 205$this->source), 'errors');
  540.                         echo "
  541.                                         </div>
  542.                                     </div>
  543.                                     ";
  544.                         // line 208
  545.                         echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock($this->sandbox->ensureToStringAllowed((isset($context["form"]) || array_key_exists("form"$context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.'208$this->source); })()), 208$this->source), 'rest');
  546.                         echo "
  547.                                 </form>
  548.                                 <div class=\"ec-productRole__btn\">
  549.                                     <button type=\"submit\" class=\"ec-blockBtn--action add-cart\" data-cartid=\"";
  550.                         // line 211
  551.                         echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "id", [], "any"falsefalsetrue211), 211$this->source), "html"nulltrue);
  552.                         echo "\" form=\"productForm";
  553.                         echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source$context["Product"], "id", [], "any"falsefalsetrue211), 211$this->source), "html"nulltrue);
  554.                         echo "\">
  555.                                         ";
  556.                         // line 212
  557.                         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートに入れる"), "html"nulltrue);
  558.                         echo "
  559.                                     </button>
  560.                                 </div>
  561.                             ";
  562.                     } else {
  563.                         // line 216
  564.                         echo "                                <div class=\"ec-productRole__btn\">
  565.                                     <button type=\"button\" class=\"ec-blockBtn--action\" disabled=\"disabled\">
  566.                                         ";
  567.                         // line 218
  568.                         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("品切れ中です"), "html"nulltrue);
  569.                         echo "
  570.                                     </button>
  571.                                 </div>
  572.                             ";
  573.                     }
  574.                     // line 222
  575.                     echo "                        </li>
  576.                     ";
  577.                     ++$context['loop']['index0'];
  578.                     ++$context['loop']['index'];
  579.                     $context['loop']['first'] = false;
  580.                     if (isset($context['loop']['length'])) {
  581.                         --$context['loop']['revindex0'];
  582.                         --$context['loop']['revindex'];
  583.                         $context['loop']['last'] = === $context['loop']['revindex0'];
  584.                     }
  585.                 }
  586.                 $_parent $context['_parent'];
  587.                 unset($context['_seq'], $context['_iterated'], $context['_key'], $context['Product'], $context['_parent'], $context['loop']);
  588.                 $context array_intersect_key($context$_parent) + $_parent;
  589.                 // line 224
  590.                 echo "                </ul>
  591.             </div>
  592.             <div class=\"ec-modal\">
  593.                 <div class=\"ec-modal-overlay\">
  594.                     <div class=\"ec-modal-wrap\">
  595.                         <span class=\"ec-modal-close\"><span class=\"ec-icon\"><img src=\"";
  596.                 // line 229
  597.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("assets/icon/cross-dark.svg"), "html"nulltrue);
  598.                 echo "\" alt=\"\"/></span></span>
  599.                         <div id=\"ec-modal-header\" class=\"text-center\">";
  600.                 // line 230
  601.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートに追加しました。"), "html"nulltrue);
  602.                 echo "</div>
  603.                         <div class=\"ec-modal-box\">
  604.                             <div class=\"ec-role\">
  605.                                 <span class=\"ec-inlineBtn--cancel\">";
  606.                 // line 233
  607.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("お買い物を続ける"), "html"nulltrue);
  608.                 echo "</span>
  609.                                 <a href=\"";
  610.                 // line 234
  611.                 echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("cart");
  612.                 echo "\" class=\"ec-inlineBtn--action\">";
  613.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートへ進む"), "html"nulltrue);
  614.                 echo "</a>
  615.                             </div>
  616.                         </div>
  617.                     </div>
  618.                 </div>
  619.             </div>
  620.             <div class=\"ec-pagerRole\">
  621.                 ";
  622.                 // line 241
  623.                 $this->loadTemplate("pager.twig""Product/list.twig"241)->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.'241$this->source); })()), "paginationData", [], "any"falsefalsetrue241)]));
  624.                 // line 242
  625.                 echo "            </div>
  626.         ";
  627.             }
  628.             // line 244
  629.             echo "    ";
  630.         }
  631.         
  632.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  633.         
  634.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  635.     }
  636.     public function getTemplateName()
  637.     {
  638.         return "Product/list.twig";
  639.     }
  640.     public function isTraitable()
  641.     {
  642.         return false;
  643.     }
  644.     public function getDebugInfo()
  645.     {
  646.         return array (  657 => 244,  653 => 242,  651 => 241,  639 => 234,  635 => 233,  629 => 230,  625 => 229,  618 => 224,  603 => 222,  596 => 218,  592 => 216,  585 => 212,  579 => 211,  573 => 208,  567 => 205,  563 => 204,  558 => 203,  555 => 202,  549 => 199,  545 => 198,  542 => 197,  540 => 196,  535 => 194,  531 => 193,  528 => 192,  526 => 191,  516 => 189,  513 => 188,  511 => 187,  507 => 185,  503 => 183,  497 => 181,  495 => 180,  491 => 179,  480 => 177,  477 => 176,  473 => 174,  467 => 172,  464 => 171,  456 => 169,  450 => 167,  447 => 166,  445 => 165,  442 => 164,  436 => 162,  434 => 161,  430 => 160,  419 => 158,  416 => 157,  414 => 156,  410 => 155,  407 => 154,  390 => 153,  386 => 151,  384 => 150,  380 => 148,  373 => 144,  369 => 143,  365 => 141,  363 => 140,  360 => 139,  354 => 137,  348 => 135,  346 => 134,  340 => 130,  335 => 128,  332 => 127,  329 => 126,  326 => 125,  305 => 122,  299 => 121,  296 => 120,  278 => 119,  276 => 118,  269 => 116,  264 => 113,  252 => 111,  248 => 110,  243 => 109,  239 => 108,  235 => 106,  229 => 103,  226 => 102,  223 => 101,  213 => 100,  186 => 82,  176 => 75,  145 => 47,  117 => 21,  103 => 20,  95 => 19,  78 => 18,  74 => 16,  64 => 15,  53 => 11,  51 => 13,  38 => 11,);
  647.     }
  648.     public function getSourceContext()
  649.     {
  650.         return new Source("{#
  651. This file is part of EC-CUBE
  652. Copyright(c) EC-CUBE CO.,LTD. All Rights Reserved.
  653. http://www.ec-cube.co.jp/
  654. For the full copyright and license information, please view the LICENSE
  655. file that was distributed with this source code.
  656. #}
  657. {% extends 'default_frame.twig' %}
  658. {% set body_class = 'product_page' %}
  659. {% block javascript %}
  660.     <script>
  661.         eccube.productsClassCategories = {
  662.             {% for Product in pagination %}
  663.             \"{{ Product.id|escape('js') }}\": {{ class_categories_as_json(Product)|raw }}{% if loop.last == false %}, {% endif %}
  664.             {% endfor %}
  665.         };
  666.         \$(function() {
  667.             // 表示件数を変更
  668.             \$('.disp-number').change(function() {
  669.                 var dispNumber = \$(this).val();
  670.                 \$('#disp_number').val(dispNumber);
  671.                 \$('#pageno').val(1);
  672.                 \$(\"#form1\").submit();
  673.             });
  674.             // 並び順を変更
  675.             \$('.order-by').change(function() {
  676.                 var orderBy = \$(this).val();
  677.                 \$('#orderby').val(orderBy);
  678.                 \$('#pageno').val(1);
  679.                 \$(\"#form1\").submit();
  680.             });
  681.             \$('.add-cart').on('click', function(e) {
  682.                 var \$form = \$(this).parents('li').find('form');
  683.                 // 個数フォームのチェック
  684.                 var \$quantity = \$form.parent().find('.quantity');
  685.                 if (\$quantity.val() < 1) {
  686.                     \$quantity[0].setCustomValidity('{{ '1以上で入力してください。'|trans }}');
  687.                     setTimeout(function() {
  688.                         loadingOverlay('hide');
  689.                     }, 100);
  690.                     return true;
  691.                 } else {
  692.                     \$quantity[0].setCustomValidity('');
  693.                 }
  694.                 e.preventDefault();
  695.                 \$.ajax({
  696.                     url: \$form.attr('action'),
  697.                     type: \$form.attr('method'),
  698.                     data: \$form.serialize(),
  699.                     dataType: 'json',
  700.                     beforeSend: function(xhr, settings) {
  701.                         // Buttonを無効にする
  702.                         \$('.add-cart').prop('disabled', true);
  703.                     }
  704.                 }).done(function(data) {
  705.                     // レスポンス内のメッセージをalertで表示
  706.                     \$.each(data.messages, function() {
  707.                         \$('#ec-modal-header').text(this);
  708.                     });
  709.                     \$('.ec-modal').show()
  710.                     // カートブロックを更新する
  711.                     \$.ajax({
  712.                         url: '{{ url('block_cart') }}',
  713.                         type: 'GET',
  714.                         dataType: 'html'
  715.                     }).done(function(html) {
  716.                         \$('.ec-headerRole__cart').html(html);
  717.                     });
  718.                 }).fail(function(data) {
  719.                     alert('{{ 'カートへの追加に失敗しました。'|trans }}');
  720.                 }).always(function(data) {
  721.                     // Buttonを有効にする
  722.                     \$('.add-cart').prop('disabled', false);
  723.                 });
  724.             });
  725.         });
  726.         \$('.ec-modal-wrap').on('click', function(e) {
  727.             // モーダル内の処理は外側にバブリングさせない
  728.             e.stopPropagation();
  729.         });
  730.         \$('.ec-modal-overlay, .ec-modal, .ec-modal-close, .ec-inlineBtn--cancel').on('click', function() {
  731.             \$('.ec-modal').hide()
  732.         });
  733.     </script>
  734. {% endblock %}
  735. {% block main %}
  736.     {% if search_form.category_id.vars.errors|length > 0 %}
  737.         <div class=\"ec-searchnavRole\">
  738.             <p class=\"errormsg text-danger\">{{ 'ご指定のカテゴリは存在しません'|trans }}</p>
  739.         </div>
  740.     {% else %}
  741.         <div class=\"ec-searchnavRole\">
  742.             <form name=\"form1\" id=\"form1\" method=\"get\" action=\"?\">
  743.                 {% for item in search_form %}
  744.                     <input type=\"hidden\" id=\"{{ item.vars.id }}\"
  745.                            name=\"{{ item.vars.full_name }}\"
  746.                            {% if item.vars.value is not empty %}value=\"{{ item.vars.value }}\" {% endif %}/>
  747.                 {% endfor %}
  748.             </form>
  749.             <div class=\"ec-searchnavRole__topicpath\">
  750.                 <ol class=\"ec-topicpath\">
  751.                     <li class=\"ec-topicpath__item\"><a href=\"{{ url('product_list') }}\">{{ '全て'|trans }}</a>
  752.                     </li>
  753.                     {% if Category is not null %}
  754.                         {% for Path in Category.path %}
  755.                             <li class=\"ec-topicpath__divider\">|</li>
  756.                             <li class=\"ec-topicpath__item{% if loop.last %}--active{% endif %}\"><a
  757.                                         href=\"{{ url('product_list') }}?category_id={{ Path.id }}\">{{ Path.name }}</a>
  758.                             </li>
  759.                         {% endfor %}
  760.                     {% endif %}
  761.                     {% if search_form.vars.value and search_form.vars.value.name %}
  762.                         <li class=\"ec-topicpath__divider\">|</li>
  763.                         <li class=\"ec-topicpath__item\">{{ '「%name%」の検索結果'|trans({ '%name%': search_form.vars.value.name }) }}</li>
  764.                     {% endif %}
  765.                 </ol>
  766.             </div>
  767.             <div class=\"ec-searchnavRole__infos\">
  768.                 <div class=\"ec-searchnavRole__counter\">
  769.                     {% if pagination.totalItemCount > 0 %}
  770.                         {{ '<span class=\"ec-font-bold\">%count%件</span><span>の商品が見つかりました</span>'|trans({ '%count%': pagination.totalItemCount })|raw }}
  771.                     {% else %}
  772.                         <span>{{ 'お探しの商品は見つかりませんでした'|trans }}</span>
  773.                     {% endif %}
  774.                 </div>
  775.                 {% if pagination.totalItemCount > 0 %}
  776.                     <div class=\"ec-searchnavRole__actions\">
  777.                         <div class=\"ec-select\">
  778.                             {{ form_widget(search_form.disp_number, {'id': '', 'attr': {'class': 'disp-number'}}) }}
  779.                             {{ form_widget(search_form.orderby, {'id': '', 'attr': {'class': 'order-by'}}) }}
  780.                         </div>
  781.                     </div>
  782.                 {% endif %}
  783.             </div>
  784.         </div>
  785.         {% if pagination.totalItemCount > 0 %}
  786.             <div class=\"ec-shelfRole\">
  787.                 <ul class=\"ec-shelfGrid\">
  788.                     {% for Product in pagination %}
  789.                         <li class=\"ec-shelfGrid__item\">
  790.                             <a href=\"{{ url('product_detail', {'id': Product.id}) }}\">
  791.                                 {% if Product.stock_find %}
  792.                                   <p class=\"ec-shelfGrid__item-image\">
  793.                                       <img src=\"{{ asset(Product.main_list_image|no_image_product, 'save_image') }}\" alt=\"{{ Product.name }}\" {% if loop.index > 5 %} loading=\"lazy\"{% endif %}>
  794.                                   </p>
  795.                                   <p class=\"ec-shelfGrid__title\">{{ Product.name }}</p>
  796.                                   {% if Product.description_list %}
  797.                                       <p class=\"ec-shelfGrid__title\">{{ Product.description_list|raw|nl2br }}</p>
  798.                                   {% endif %}
  799.                                   <p class=\"ec-shelfGrid__price\">
  800.                                       {% if Product.hasProductClass %}
  801.                                           {% if Product.getPrice02Min == Product.getPrice02Max %}
  802.                                               {{ Product.getPrice02IncTaxMin|price }}
  803.                                           {% else %}
  804.                                               {{ Product.getPrice02IncTaxMin|price }} ~ {{ Product.getPrice02IncTaxMax|price }}
  805.                                           {% endif %}
  806.                                       {% else %}
  807.                                           {{ Product.getPrice02IncTaxMin|price }}
  808.                                       {% endif %}
  809.                                   </p>
  810.                                 {% else %}
  811.                                   <p class=\"ec-shelfGrid__item-image soldout\">
  812.                                       <img src=\"{{ asset(Product.main_list_image|no_image_product, 'save_image') }}\" alt=\"{{ Product.name }}\" {% if loop.index > 5 %} loading=\"lazy\"{% endif %}>
  813.                                   </p>
  814.                                   <p class=\"ec-shelfGrid__title\">{{ Product.name }}</p>
  815.                                   {% if Product.description_list %}
  816.                                       <p class=\"ec-shelfGrid__title\">{{ Product.description_list|raw|nl2br }}</p>
  817.                                   {% endif %}
  818.                                     <p class=\"ec-shelfGrid__price soldout\">SOLDOUT</p>
  819.                                 {% endif %}
  820.                             </a>
  821.                             {% if Product.stock_find %}
  822.                                 {% set form = forms[Product.id] %}
  823.                                 <form name=\"form{{ Product.id }}\" id=\"productForm{{ Product.id }}\" action=\"{{ url('product_add_cart', {id:Product.id}) }}\" method=\"post\">
  824.                                     <div class=\"ec-productRole__actions\">
  825.                                         {% if form.classcategory_id1 is defined %}
  826.                                             <div class=\"ec-select\">
  827.                                                 {{ form_widget(form.classcategory_id1) }}
  828.                                                 {{ form_errors(form.classcategory_id1) }}
  829.                                             </div>
  830.                                             {% if form.classcategory_id2 is defined %}
  831.                                                 <div class=\"ec-select\">
  832.                                                     {{ form_widget(form.classcategory_id2) }}
  833.                                                     {{ form_errors(form.classcategory_id2) }}
  834.                                                 </div>
  835.                                             {% endif %}
  836.                                         {% endif %}
  837.                                         <div class=\"ec-numberInput\"><span>{{ '数量'|trans }}</span>
  838.                                             {{ form_widget(form.quantity, {'attr': {'class': 'quantity'}}) }}
  839.                                             {{ form_errors(form.quantity) }}
  840.                                         </div>
  841.                                     </div>
  842.                                     {{ form_rest(form) }}
  843.                                 </form>
  844.                                 <div class=\"ec-productRole__btn\">
  845.                                     <button type=\"submit\" class=\"ec-blockBtn--action add-cart\" data-cartid=\"{{ Product.id }}\" form=\"productForm{{ Product.id }}\">
  846.                                         {{ 'カートに入れる'|trans }}
  847.                                     </button>
  848.                                 </div>
  849.                             {% else %}
  850.                                 <div class=\"ec-productRole__btn\">
  851.                                     <button type=\"button\" class=\"ec-blockBtn--action\" disabled=\"disabled\">
  852.                                         {{ '品切れ中です'|trans }}
  853.                                     </button>
  854.                                 </div>
  855.                             {% endif %}
  856.                         </li>
  857.                     {% endfor %}
  858.                 </ul>
  859.             </div>
  860.             <div class=\"ec-modal\">
  861.                 <div class=\"ec-modal-overlay\">
  862.                     <div class=\"ec-modal-wrap\">
  863.                         <span class=\"ec-modal-close\"><span class=\"ec-icon\"><img src=\"{{ asset('assets/icon/cross-dark.svg') }}\" alt=\"\"/></span></span>
  864.                         <div id=\"ec-modal-header\" class=\"text-center\">{{ 'カートに追加しました。'|trans }}</div>
  865.                         <div class=\"ec-modal-box\">
  866.                             <div class=\"ec-role\">
  867.                                 <span class=\"ec-inlineBtn--cancel\">{{ 'お買い物を続ける'|trans }}</span>
  868.                                 <a href=\"{{ url('cart') }}\" class=\"ec-inlineBtn--action\">{{ 'カートへ進む'|trans }}</a>
  869.                             </div>
  870.                         </div>
  871.                     </div>
  872.                 </div>
  873.             </div>
  874.             <div class=\"ec-pagerRole\">
  875.                 {% include \"pager.twig\" with {'pages': pagination.paginationData} %}
  876.             </div>
  877.         {% endif %}
  878.     {% endif %}
  879. {% endblock %}""Product/list.twig""/home/egonet/c-bcl.com/public_html/shop/app/template/lag/Product/list.twig");
  880.     }
  881.     
  882.     public function checkSecurity()
  883.     {
  884.         static $tags = array("set" => 13"for" => 18"if" => 19"include" => 241);
  885.         static $filters = array("escape" => 19"raw" => 19"trans" => 47"length" => 101"no_image_product" => 158"nl2br" => 162"price" => 167);
  886.         static $functions = array("class_categories_as_json" => 19"url" => 75"form_widget" => 143"asset" => 158"form_errors" => 194"form_rest" => 208);
  887.         try {
  888.             $this->sandbox->checkSecurity(
  889.                 ['set''for''if''include'],
  890.                 ['escape''raw''trans''length''no_image_product''nl2br''price'],
  891.                 ['class_categories_as_json''url''form_widget''asset''form_errors''form_rest']
  892.             );
  893.         } catch (SecurityError $e) {
  894.             $e->setSourceContext($this->source);
  895.             if ($e instanceof SecurityNotAllowedTagError && isset($tags[$e->getTagName()])) {
  896.                 $e->setTemplateLine($tags[$e->getTagName()]);
  897.             } elseif ($e instanceof SecurityNotAllowedFilterError && isset($filters[$e->getFilterName()])) {
  898.                 $e->setTemplateLine($filters[$e->getFilterName()]);
  899.             } elseif ($e instanceof SecurityNotAllowedFunctionError && isset($functions[$e->getFunctionName()])) {
  900.                 $e->setTemplateLine($functions[$e->getFunctionName()]);
  901.             }
  902.             throw $e;
  903.         }
  904.     }
  905. }