var/cache/dev/twig/1b/1b3cc6c3aa0ed72640dfd132c223983aad3a409aaac379be1c27d134c57205ab.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. /* index/index.html.twig */
  14. class __TwigTemplate_c525e23695abc2461bbb53c96965d9d0dca8cca610b892e55dc738cf70b90b5f extends 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.             'body' => [$this'block_body'],
  24.         ];
  25.     }
  26.     protected function doGetParent(array $context)
  27.     {
  28.         // line 1
  29.         return "base.html.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""index/index.html.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""index/index.html.twig"));
  38.         $this->parent $this->loadTemplate("base.html.twig""index/index.html.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 4
  46.     public function block_body($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""body"));
  51.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  52.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""body"));
  53.         // line 5
  54.         echo "    <!--首页内容-->
  55.     <div class=\"indexBigImg viewWidth\" style=\"background-image: url('";
  56.         // line 6
  57.         echo twig_escape_filter($this->env, ((isset($context["cdn_url"]) || array_key_exists("cdn_url"$context) ? $context["cdn_url"] : (function () { throw new RuntimeError('Variable "cdn_url" does not exist.'6$this->source); })()) . twig_get_attribute($this->env$this->source, (isset($context["firstImage"]) || array_key_exists("firstImage"$context) ? $context["firstImage"] : (function () { throw new RuntimeError('Variable "firstImage" does not exist.'6$this->source); })()), "oUrl", [], "any"falsefalsefalse6)), "html"nulltrue);
  58.         echo "')\">
  59.         <h3 class=\"small\">
  60.             <!--            <p> item1.desc </p>-->
  61.             <p>";
  62.         // line 9
  63.         echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["firstImage"]) || array_key_exists("firstImage"$context) ? $context["firstImage"] : (function () { throw new RuntimeError('Variable "firstImage" does not exist.'9$this->source); })()), "oTitle", [], "any"falsefalsefalse9), "html"nulltrue);
  64.         echo "</p>
  65.             <!--            <div class=\"bg\"></div>-->
  66.             <i>New arrivals in the Pro Team summer collection.</i>
  67.         </h3>
  68.     </div>
  69.     <div class=\"indexTitles indexWidth\">
  70.         <div class=\"wrapper\">
  71.             <b class=\"taC\">系列产品</b>
  72.         </div>
  73.     </div>
  74.     <div class=\"shopThe clearfix indexWidth\" >
  75.         <div class=\"titleDiv fl\">
  76.             <div class=\"leftTitle\">系列产品</div>
  77.         </div>
  78.         <div class=\"bannerVertical clearfix fl\">
  79.             <ul class=\"vertical-left fl\" id=\"indexVertical\">
  80.                 ";
  81.         // line 25
  82.         $context['_parent'] = $context;
  83.         $context['_seq'] = twig_ensure_traversable((isset($context["highlights"]) || array_key_exists("highlights"$context) ? $context["highlights"] : (function () { throw new RuntimeError('Variable "highlights" does not exist.'25$this->source); })()));
  84.         $context['loop'] = [
  85.           'parent' => $context['_parent'],
  86.           'index0' => 0,
  87.           'index'  => 1,
  88.           'first'  => true,
  89.         ];
  90.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  91.             $length count($context['_seq']);
  92.             $context['loop']['revindex0'] = $length 1;
  93.             $context['loop']['revindex'] = $length;
  94.             $context['loop']['length'] = $length;
  95.             $context['loop']['last'] = === $length;
  96.         }
  97.         foreach ($context['_seq'] as $context["_key"] => $context["n"]) {
  98.             // line 26
  99.             echo "                <li class=\"nav-item ";
  100.             if (twig_get_attribute($this->env$this->source$context["loop"], "first", [], "any"falsefalsefalse26)) {
  101.                 echo "activeP";
  102.             }
  103.             echo "\">
  104.                     <div class=\"item-wrapper\">
  105.                         <p class=\"title taC\">";
  106.             // line 28
  107.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["n"], "oName", [], "any"falsefalsefalse28), "html"nulltrue);
  108.             echo "</p>
  109.                         <span class=\"three\"></span>
  110.                     </div>
  111.                 </li>
  112.                 ";
  113.             ++$context['loop']['index0'];
  114.             ++$context['loop']['index'];
  115.             $context['loop']['first'] = false;
  116.             if (isset($context['loop']['length'])) {
  117.                 --$context['loop']['revindex0'];
  118.                 --$context['loop']['revindex'];
  119.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  120.             }
  121.         }
  122.         $_parent $context['_parent'];
  123.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['n'], $context['_parent'], $context['loop']);
  124.         $context array_intersect_key($context$_parent) + $_parent;
  125.         // line 33
  126.         echo "            </ul>
  127.             <ul class=\"vertical-center fl\" id=\"indexVerticalImg\">
  128.                 ";
  129.         // line 35
  130.         $context['_parent'] = $context;
  131.         $context['_seq'] = twig_ensure_traversable((isset($context["highlights"]) || array_key_exists("highlights"$context) ? $context["highlights"] : (function () { throw new RuntimeError('Variable "highlights" does not exist.'35$this->source); })()));
  132.         $context['loop'] = [
  133.           'parent' => $context['_parent'],
  134.           'index0' => 0,
  135.           'index'  => 1,
  136.           'first'  => true,
  137.         ];
  138.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  139.             $length count($context['_seq']);
  140.             $context['loop']['revindex0'] = $length 1;
  141.             $context['loop']['revindex'] = $length;
  142.             $context['loop']['length'] = $length;
  143.             $context['loop']['last'] = === $length;
  144.         }
  145.         foreach ($context['_seq'] as $context["_key"] => $context["n"]) {
  146.             // line 36
  147.             echo "                <li class=\"transition_img ";
  148.             if (twig_get_attribute($this->env$this->source$context["loop"], "first", [], "any"falsefalsefalse36)) {
  149.                 echo "activeImg";
  150.             }
  151.             echo "\">
  152.                     <img src=\"";
  153.             // line 37
  154.             echo twig_escape_filter($this->env, ((isset($context["cdn_url"]) || array_key_exists("cdn_url"$context) ? $context["cdn_url"] : (function () { throw new RuntimeError('Variable "cdn_url" does not exist.'37$this->source); })()) . twig_get_attribute($this->env$this->source$context["n"], "oImageUrl", [], "any"falsefalsefalse37)), "html"nulltrue);
  155.             echo "?imageView2/5/w/800/h/527/q/100\" alt=\"\">
  156.                 </li>
  157.                 ";
  158.             ++$context['loop']['index0'];
  159.             ++$context['loop']['index'];
  160.             $context['loop']['first'] = false;
  161.             if (isset($context['loop']['length'])) {
  162.                 --$context['loop']['revindex0'];
  163.                 --$context['loop']['revindex'];
  164.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  165.             }
  166.         }
  167.         $_parent $context['_parent'];
  168.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['n'], $context['_parent'], $context['loop']);
  169.         $context array_intersect_key($context$_parent) + $_parent;
  170.         // line 40
  171.         echo "            </ul>
  172.             <div class=\"vertical-right fr\" id=\"index_vertical_right\">
  173.                 ";
  174.         // line 42
  175.         $context['_parent'] = $context;
  176.         $context['_seq'] = twig_ensure_traversable((isset($context["highlights"]) || array_key_exists("highlights"$context) ? $context["highlights"] : (function () { throw new RuntimeError('Variable "highlights" does not exist.'42$this->source); })()));
  177.         $context['loop'] = [
  178.           'parent' => $context['_parent'],
  179.           'index0' => 0,
  180.           'index'  => 1,
  181.           'first'  => true,
  182.         ];
  183.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  184.             $length count($context['_seq']);
  185.             $context['loop']['revindex0'] = $length 1;
  186.             $context['loop']['revindex'] = $length;
  187.             $context['loop']['length'] = $length;
  188.             $context['loop']['last'] = === $length;
  189.         }
  190.         foreach ($context['_seq'] as $context["key"] => $context["n"]) {
  191.             // line 43
  192.             echo "                    ";
  193.             echo twig_include($this->env$context"common/_verticalRight.html.twig", ["key" => $context["key"], "n" => $context["n"]]);
  194.             echo "
  195.                 ";
  196.             ++$context['loop']['index0'];
  197.             ++$context['loop']['index'];
  198.             $context['loop']['first'] = false;
  199.             if (isset($context['loop']['length'])) {
  200.                 --$context['loop']['revindex0'];
  201.                 --$context['loop']['revindex'];
  202.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  203.             }
  204.         }
  205.         $_parent $context['_parent'];
  206.         unset($context['_seq'], $context['_iterated'], $context['key'], $context['n'], $context['_parent'], $context['loop']);
  207.         $context array_intersect_key($context$_parent) + $_parent;
  208.         // line 45
  209.         echo "            </div>
  210.         </div>
  211.     </div>
  212.     ";
  213.         // line 49
  214.         echo "    <div class=\"viewList clearfix indexWidth\" id=\"commodityTab\">
  215.         ";
  216.         // line 51
  217.         echo "        ";
  218.         $context['_parent'] = $context;
  219.         $context['_seq'] = twig_ensure_traversable((isset($context["indexGoods"]) || array_key_exists("indexGoods"$context) ? $context["indexGoods"] : (function () { throw new RuntimeError('Variable "indexGoods" does not exist.'51$this->source); })()));
  220.         $context['loop'] = [
  221.           'parent' => $context['_parent'],
  222.           'index0' => 0,
  223.           'index'  => 1,
  224.           'first'  => true,
  225.         ];
  226.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  227.             $length count($context['_seq']);
  228.             $context['loop']['revindex0'] = $length 1;
  229.             $context['loop']['revindex'] = $length;
  230.             $context['loop']['length'] = $length;
  231.             $context['loop']['last'] = === $length;
  232.         }
  233.         foreach ($context['_seq'] as $context["key"] => $context["val"]) {
  234.             // line 52
  235.             echo "            ";
  236.             echo twig_include($this->env$context"common/_productBanner.html.twig", ["index" => $context["key"], "goods" => $context["val"]]);
  237.             echo "
  238.         ";
  239.             ++$context['loop']['index0'];
  240.             ++$context['loop']['index'];
  241.             $context['loop']['first'] = false;
  242.             if (isset($context['loop']['length'])) {
  243.                 --$context['loop']['revindex0'];
  244.                 --$context['loop']['revindex'];
  245.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  246.             }
  247.         }
  248.         $_parent $context['_parent'];
  249.         unset($context['_seq'], $context['_iterated'], $context['key'], $context['val'], $context['_parent'], $context['loop']);
  250.         $context array_intersect_key($context$_parent) + $_parent;
  251.         // line 54
  252.         echo "    </div>
  253. ";
  254.         
  255.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  256.         
  257.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  258.     }
  259.     public function getTemplateName()
  260.     {
  261.         return "index/index.html.twig";
  262.     }
  263.     public function isTraitable()
  264.     {
  265.         return false;
  266.     }
  267.     public function getDebugInfo()
  268.     {
  269.         return array (  266 => 54,  249 => 52,  231 => 51,  228 => 49,  223 => 45,  206 => 43,  189 => 42,  185 => 40,  168 => 37,  161 => 36,  144 => 35,  140 => 33,  121 => 28,  113 => 26,  96 => 25,  77 => 9,  71 => 6,  68 => 5,  58 => 4,  35 => 1,);
  270.     }
  271.     public function getSourceContext()
  272.     {
  273.         return new Source("{% extends 'base.html.twig' %}
  274. {% block body %}
  275.     <!--首页内容-->
  276.     <div class=\"indexBigImg viewWidth\" style=\"background-image: url('{{ cdn_url~firstImage.oUrl }}')\">
  277.         <h3 class=\"small\">
  278.             <!--            <p> item1.desc </p>-->
  279.             <p>{{ firstImage.oTitle }}</p>
  280.             <!--            <div class=\"bg\"></div>-->
  281.             <i>New arrivals in the Pro Team summer collection.</i>
  282.         </h3>
  283.     </div>
  284.     <div class=\"indexTitles indexWidth\">
  285.         <div class=\"wrapper\">
  286.             <b class=\"taC\">系列产品</b>
  287.         </div>
  288.     </div>
  289.     <div class=\"shopThe clearfix indexWidth\" >
  290.         <div class=\"titleDiv fl\">
  291.             <div class=\"leftTitle\">系列产品</div>
  292.         </div>
  293.         <div class=\"bannerVertical clearfix fl\">
  294.             <ul class=\"vertical-left fl\" id=\"indexVertical\">
  295.                 {% for n in highlights %}
  296.                 <li class=\"nav-item {% if loop.first %}activeP{% endif %}\">
  297.                     <div class=\"item-wrapper\">
  298.                         <p class=\"title taC\">{{ n.oName }}</p>
  299.                         <span class=\"three\"></span>
  300.                     </div>
  301.                 </li>
  302.                 {% endfor %}
  303.             </ul>
  304.             <ul class=\"vertical-center fl\" id=\"indexVerticalImg\">
  305.                 {% for n in highlights %}
  306.                 <li class=\"transition_img {% if loop.first %}activeImg{% endif %}\">
  307.                     <img src=\"{{ cdn_url~n.oImageUrl }}?imageView2/5/w/800/h/527/q/100\" alt=\"\">
  308.                 </li>
  309.                 {% endfor %}
  310.             </ul>
  311.             <div class=\"vertical-right fr\" id=\"index_vertical_right\">
  312.                 {% for key,n in highlights %}
  313.                     {{ include('common/_verticalRight.html.twig',{ key: key, n: n }) }}
  314.                 {% endfor %}
  315.             </div>
  316.         </div>
  317.     </div>
  318.     {#首页商品列表#}
  319.     <div class=\"viewList clearfix indexWidth\" id=\"commodityTab\">
  320.         {#模拟循环次数,正式的需要外部循环一次,并将数据传入,在组件内循环商品资料,用index匹配封装的js#}
  321.         {% for key,val in indexGoods %}
  322.             {{ include('common/_productBanner.html.twig',{ index: key, goods: val }) }}
  323.         {% endfor %}
  324.     </div>
  325. {% endblock %}
  326. ""index/index.html.twig""/home/wwwroot/ada.santic.com/templates/index/index.html.twig");
  327.     }
  328. }