var/cache/dev/twig/a0/a0fb5115322ca5c1acc496e62b909aa4752f05be5eedd8a979a4a9c327ab2456.php line 38

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. /* @user_data/brand.twig */
  14. class __TwigTemplate_35b11ca06b76a5fcd7039abe39976572c96f0541feaafc857f31a57794d6f22e 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.             'main' => [$this'block_main'],
  24.         ];
  25.     }
  26.     protected function doGetParent(array $context)
  27.     {
  28.         // line 1
  29.         return "default_frame.twig";
  30.     }
  31.     protected function doDisplay(array $context, array $blocks = [])
  32.     {
  33.         $macros $this->macros;
  34.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  35.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@user_data/brand.twig"));
  36.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  37.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@user_data/brand.twig"));
  38.         $this->parent $this->loadTemplate("default_frame.twig""@user_data/brand.twig"1);
  39.         $this->parent->display($contextarray_merge($this->blocks$blocks));
  40.         
  41.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  42.         
  43.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  44.     }
  45.     // line 3
  46.     public function block_main($context, array $blocks = [])
  47.     {
  48.         $macros $this->macros;
  49.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  50.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""main"));
  51.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  52.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""main"));
  53.         // line 4
  54.         echo "
  55. ";
  56.         // line 7
  57.         echo "
  58. ";
  59.         // line 8
  60.         $context["parentId"] = 34;
  61.         // line 9
  62.         $context["ParentCategory"] = twig_get_attribute($this->env$this->source$this->env->getFunction('repository')->getCallable()("Eccube\\Entity\\Category"), "find", [=> (isset($context["parentId"]) || array_key_exists("parentId"$context) ? $context["parentId"] : (function () { throw new RuntimeError('Variable "parentId" does not exist.'9$this->source); })())], "method"falsefalsefalse9);
  63.         // line 10
  64.         $context["childCategories"] = twig_sort_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["ParentCategory"]) || array_key_exists("ParentCategory"$context) ? $context["ParentCategory"] : (function () { throw new RuntimeError('Variable "ParentCategory" does not exist.'10$this->source); })()), "children", [], "any"falsefalsefalse10), function ($__a__$__b__) use ($context$macros) { $context["a"] = $__a__$context["b"] = $__b__; return (twig_get_attribute($this->env$this->source, (isset($context["a"]) || array_key_exists("a"$context) ? $context["a"] : (function () { throw new RuntimeError('Variable "a" does not exist.'10$this->source); })()), "sortNo", [], "any"falsefalsefalse10) <=> twig_get_attribute($this->env$this->source, (isset($context["b"]) || array_key_exists("b"$context) ? $context["b"] : (function () { throw new RuntimeError('Variable "b" does not exist.'10$this->source); })()), "sortNo", [], "any"falsefalsefalse10)); });
  65.         // line 11
  66.         echo "
  67. Brand
  68. ブランドから探す
  69. <ul>
  70.     ";
  71.         // line 15
  72.         $context['_parent'] = $context;
  73.         $context['_seq'] = twig_ensure_traversable((isset($context["childCategories"]) || array_key_exists("childCategories"$context) ? $context["childCategories"] : (function () { throw new RuntimeError('Variable "childCategories" does not exist.'15$this->source); })()));
  74.         foreach ($context['_seq'] as $context["_key"] => $context["childCategory"]) {
  75.             // line 16
  76.             echo "        <li>
  77.             <a href=\"";
  78.             // line 17
  79.             echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("product_list");
  80.             echo "?brand_id=";
  81.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["childCategory"], "id", [], "any"falsefalsefalse17), "html"nulltrue);
  82.             echo "\">
  83.                 ";
  84.             // line 18
  85.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["childCategory"], "name", [], "any"falsefalsefalse18), "html"nulltrue);
  86.             echo "
  87.             </a>
  88.         </li>
  89.     ";
  90.         }
  91.         $_parent $context['_parent'];
  92.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['childCategory'], $context['_parent'], $context['loop']);
  93.         $context array_intersect_key($context$_parent) + $_parent;
  94.         // line 22
  95.         echo "</ul>
  96. ";
  97.         
  98.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  99.         
  100.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  101.     }
  102.     public function getTemplateName()
  103.     {
  104.         return "@user_data/brand.twig";
  105.     }
  106.     public function isTraitable()
  107.     {
  108.         return false;
  109.     }
  110.     public function getDebugInfo()
  111.     {
  112.         return array (  110 => 22,  100 => 18,  94 => 17,  91 => 16,  87 => 15,  81 => 11,  79 => 10,  77 => 9,  75 => 8,  72 => 7,  68 => 4,  58 => 3,  35 => 1,);
  113.     }
  114.     public function getSourceContext()
  115.     {
  116.         return new Source("{% extends 'default_frame.twig' %}
  117. {% block main %}
  118. {# ブランド[カテゴリID:34]の子カテゴリ一覧を表示 #}
  119. {% set parentId = 34 %}
  120. {% set ParentCategory = repository('Eccube\\\\Entity\\\\Category').find(parentId) %}
  121. {% set childCategories = ParentCategory.children|sort((a, b) => a.sortNo <=> b.sortNo) %}
  122. Brand
  123. ブランドから探す
  124. <ul>
  125.     {% for childCategory in childCategories %}
  126.         <li>
  127.             <a href=\"{{ url('product_list') }}?brand_id={{ childCategory.id }}\">
  128.                 {{ childCategory.name }}
  129.             </a>
  130.         </li>
  131.     {% endfor %}
  132. </ul>
  133. {% endblock %}""@user_data/brand.twig""/home/xs626321/ikus.furniture/public_html/dev/app/template/user_data/brand.twig");
  134.     }
  135. }