var/cache/dev_h41800f5fdfafa409ea382bf45d0f7c63/twig/27/2789f4b2e4647c035a23e2d6a0b077636c42f66742339860f1dd3b2aa1b7eb4d.php line 301

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use function Shopware\Core\Framework\Adapter\Twig\sw_get_attribute;
  4. use function Shopware\Core\Framework\Adapter\Twig\sw_escape_filter;
  5. use Twig\Error\LoaderError;
  6. use Twig\Error\RuntimeError;
  7. use Twig\Extension\SandboxExtension;
  8. use Twig\Markup;
  9. use Twig\Sandbox\SecurityError;
  10. use Twig\Sandbox\SecurityNotAllowedTagError;
  11. use Twig\Sandbox\SecurityNotAllowedFilterError;
  12. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  13. use Twig\Source;
  14. use Twig\Template;
  15. /* @SchilderSysteme/storefront/component/product/table.html.twig */
  16. class __TwigTemplate_ad1d89ea8bbd31a8865d3e9ff7064b32ce4c8df3139bc3d67909c7afdc4119a6 extends Template
  17. {
  18.     private $source;
  19.     private $macros = [];
  20.     public function __construct(Environment $env)
  21.     {
  22.         parent::__construct($env);
  23.         $this->source $this->getSourceContext();
  24.         $this->parent false;
  25.         $this->blocks = [
  26.             'component_product_table_container' => [$this'block_component_product_table_container'],
  27.         ];
  28.     }
  29.     protected function doDisplay(array $context, array $blocks = [])
  30.     {
  31.         $macros $this->macros;
  32.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  33.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@SchilderSysteme/storefront/component/product/table.html.twig"));
  34.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  35.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@SchilderSysteme/storefront/component/product/table.html.twig"));
  36.         // line 1
  37.         $this->displayBlock('component_product_table_container'$context$blocks);
  38.         
  39.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  40.         
  41.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  42.     }
  43.     public function block_component_product_table_container($context, array $blocks = [])
  44.     {
  45.         $macros $this->macros;
  46.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  47.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""component_product_table_container"));
  48.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  49.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""component_product_table_container"));
  50.         // line 2
  51.         echo "    ";
  52.         $context["variants"] = sw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source, ($context["page"] ?? null), "product", [], "any"falsefalsefalse2), "customFields", [], "any"falsefalsefalse2), "variants", [], "any"falsefalsefalse2);
  53.         // line 3
  54.         echo "    ";
  55.         $context["ruleId"] = sw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source, ($context["page"] ?? null), "product", [], "any"falsefalsefalse3), "cheapestPrice", [], "any"falsefalsefalse3), "ruleId", [], "any"falsefalsefalse3);
  56.         // line 4
  57.         echo "    ";
  58.         $context["staplelength"] = (twig_length_filter($this->envsw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source, ($context["product"] ?? null), "calculatedPrices", [], "any"falsefalsefalse4), "elements", [], "any"falsefalsefalse4)) - 1);
  59.         // line 5
  60.         echo "
  61.     ";
  62.         // line 6
  63.         if ((=== twig_compare(twig_length_filter($this->env, ($context["variants"] ?? null)), 0))) {
  64.             // line 7
  65.             echo "        ";
  66.             if ((=== twig_compare(twig_length_filter($this->envsw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source, ($context["page"] ?? null), "product", [], "any"falsefalsefalse7), "calculatedPrices", [], "any"falsefalsefalse7)), 1))) {
  67.                 // line 8
  68.                 echo "            ";
  69.                 $context["bestprice"] = false;
  70.                 // line 9
  71.                 echo "            ";
  72.                 $context['_parent'] = $context;
  73.                 $context['_seq'] = twig_ensure_traversable(twig_array_filter($this->env, ($context["variants"] ?? null), function ($__variant__) use ($context$macros) { $context["variant"] = $__variant__; return (=== twig_compare(sw_get_attribute($this->env$this->source$context["variant"], "availableStock", [], "any"falsefalsefalse9), true)); }));
  74.                 foreach ($context['_seq'] as $context["_key"] => $context["variant"]) {
  75.                     // line 10
  76.                     echo "                ";
  77.                     if ((!== twig_compare(sw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source$context["variant"], "customFields", [], "any"falsefalsefalse10), "custom_units_piece_per_pu", [], "any"falsefalsefalse10), 1))) {
  78.                         // line 11
  79.                         echo "                    ";
  80.                         $context["bestprice"] = true;
  81.                         // line 12
  82.                         echo "                ";
  83.                     }
  84.                     // line 13
  85.                     echo "            ";
  86.                 }
  87.                 $_parent $context['_parent'];
  88.                 unset($context['_seq'], $context['_iterated'], $context['_key'], $context['variant'], $context['_parent'], $context['loop']);
  89.                 $context array_intersect_key($context$_parent) + $_parent;
  90.                 // line 14
  91.                 echo "            ";
  92.                 if ((=== twig_compare(($context["bestprice"] ?? null), true))) {
  93.                     // line 15
  94.                     echo "                <div class=\"product-detail-table-container\">
  95.                     <table class=\"product-detail-table ";
  96.                     // line 16
  97.                     if ((=== twig_compare(twig_length_filter($this->envsw_get_attribute($this->env$this->source, ($context["product"] ?? null), "calculatedPrices", [], "any"falsefalsefalse16)), 1))) {
  98.                         echo "has-badge";
  99.                     }
  100.                     echo "\">
  101.                         <tr class=\"table--header\">
  102.                             <th align=\"center\" class=\"price-list-item\">";
  103.                     // line 18
  104.                     echo $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("detail.TableArtNr"));
  105.                     echo "</th>
  106.                             <th align=\"center\" class=\"price-list-item\">Variante</th>
  107.                             <th align=\"center\" class=\"price-list-item\">VE</th>
  108.                             <th align=\"center\"
  109.                                 class=\"price-list-item\">";
  110.                     // line 22
  111.                     echo $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("detail.tableAvailable"));
  112.                     echo "</th>
  113.                             <th align=\"center\"
  114.                                 class=\"price-list-item\">";
  115.                     // line 24
  116.                     echo $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("detail.tableQuantity"));
  117.                     echo "</th>
  118.                             ";
  119.                     // line 25
  120.                     $context['_parent'] = $context;
  121.                     $context['_seq'] = twig_ensure_traversable(sw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source, ($context["product"] ?? null), "calculatedPrices", [], "any"falsefalsefalse25), "elements", [], "any"falsefalsefalse25));
  122.                     $context['loop'] = [
  123.                       'parent' => $context['_parent'],
  124.                       'index0' => 0,
  125.                       'index'  => 1,
  126.                       'first'  => true,
  127.                     ];
  128.                     if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  129.                         $length count($context['_seq']);
  130.                         $context['loop']['revindex0'] = $length 1;
  131.                         $context['loop']['revindex'] = $length;
  132.                         $context['loop']['length'] = $length;
  133.                         $context['loop']['last'] = === $length;
  134.                     }
  135.                     foreach ($context['_seq'] as $context["_key"] => $context["price"]) {
  136.                         // line 26
  137.                         echo "                                ";
  138.                         if (((=== twig_compare(sw_get_attribute($this->env$this->source$context["loop"], "last", [], "any"falsefalsefalse26), false)) && (>= twig_compare(sw_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsefalse26), 4)))) {
  139.                             // line 27
  140.                             echo "                                    <th align=\"center\" class=\"price-list-item\">
  141.                                         ";
  142.                             // line 28
  143.                             if ((=== twig_compare(twig_length_filter($this->envsw_get_attribute($this->env$this->source, ($context["product"] ?? null), "calculatedPrices", [], "any"falsefalsefalse28)), 1))) {
  144.                                 // line 29
  145.                                 echo "                                            <div class=\"discount-badge\">
  146.                                                 ";
  147.                                 // line 30
  148.                                 if ((=== twig_compare(sw_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsefalse30), 1))) {
  149.                                     echo "-5%";
  150.                                 }
  151.                                 // line 31
  152.                                 echo "                                                ";
  153.                                 if ((=== twig_compare(sw_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsefalse31), 2))) {
  154.                                     echo "-8%";
  155.                                 }
  156.                                 // line 32
  157.                                 echo "                                                ";
  158.                                 if ((=== twig_compare(sw_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsefalse32), 3))) {
  159.                                     echo "-10%";
  160.                                 }
  161.                                 // line 33
  162.                                 echo "                                                ";
  163.                                 if ((=== twig_compare(sw_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsefalse33), 4))) {
  164.                                     echo "-12%";
  165.                                 }
  166.                                 // line 34
  167.                                 echo "                                            </div>
  168.                                         ";
  169.                             }
  170.                             // line 36
  171.                             echo "                                        ";
  172.                             echo sw_escape_filter($this->env, (sw_get_attribute($this->env$this->source$context["price"], "quantity", [], "any"falsefalsefalse36) + 1), "html"nulltrue);
  173.                             echo " VE / Stück
  174.                                     </th>
  175.                                 ";
  176.                         }
  177.                         // line 39
  178.                         echo "                            ";
  179.                         ++$context['loop']['index0'];
  180.                         ++$context['loop']['index'];
  181.                         $context['loop']['first'] = false;
  182.                         if (isset($context['loop']['length'])) {
  183.                             --$context['loop']['revindex0'];
  184.                             --$context['loop']['revindex'];
  185.                             $context['loop']['last'] = === $context['loop']['revindex0'];
  186.                         }
  187.                     }
  188.                     $_parent $context['_parent'];
  189.                     unset($context['_seq'], $context['_iterated'], $context['_key'], $context['price'], $context['_parent'], $context['loop']);
  190.                     $context array_intersect_key($context$_parent) + $_parent;
  191.                     // line 40
  192.                     echo "                            <th align=\"center\"
  193.                                 class=\"price-list-item\">";
  194.                     // line 41
  195.                     echo $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\SwSanitizeTwigFilter']->sanitize($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("detail.tableDesiredQuantityVE"));
  196.                     echo "</th>
  197.                         </tr>
  198.                         <tr>
  199.                             ";
  200.                     // line 44
  201.                     $context['_parent'] = $context;
  202.                     $context['_seq'] = twig_ensure_traversable(twig_array_filter($this->env, ($context["variants"] ?? null), function ($__variant__) use ($context$macros) { $context["variant"] = $__variant__; return (=== twig_compare(sw_get_attribute($this->env$this->source$context["variant"], "availableStock", [], "any"falsefalsefalse44), true)); }));
  203.                     $context['loop'] = [
  204.                       'parent' => $context['_parent'],
  205.                       'index0' => 0,
  206.                       'index'  => 1,
  207.                       'first'  => true,
  208.                     ];
  209.                     if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  210.                         $length count($context['_seq']);
  211.                         $context['loop']['revindex0'] = $length 1;
  212.                         $context['loop']['revindex'] = $length;
  213.                         $context['loop']['length'] = $length;
  214.                         $context['loop']['last'] = === $length;
  215.                     }
  216.                     foreach ($context['_seq'] as $context["_key"] => $context["variant"]) {
  217.                         // line 45
  218.                         echo "                            ";
  219.                         if ((!== twig_compare(sw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source$context["variant"], "customFields", [], "any"falsefalsefalse45), "custom_units_piece_per_pu", [], "any"falsefalsefalse45), "1"))) {
  220.                             // line 46
  221.                             echo "                            ";
  222.                             $context["pricesVariant"] = twig_sort_filter($this->envsw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source$context["variant"], "prices", [], "any"falsefalsefalse46), "elements", [], "any"falsefalsefalse46), function ($__a__$__b__) use ($context$macros) { $context["a"] = $__a__$context["b"] = $__b__; return (sw_get_attribute($this->env$this->source, ($context["a"] ?? null), "quantityStart", [], "any"falsefalsefalse46) <=> sw_get_attribute($this->env$this->source, ($context["b"] ?? null), "quantityStart", [], "any"falsefalsefalse46)); });
  223.                             // line 47
  224.                             echo "                        <tr>
  225.                             <td>";
  226.                             // line 48
  227.                             echo sw_escape_filter($this->envsw_get_attribute($this->env$this->source$context["variant"], "productNumber", [], "any"falsefalsefalse48), "html"nulltrue);
  228.                             echo "</td>
  229.                             <td>
  230.                                 ";
  231.                             // line 50
  232.                             $context['_parent'] = $context;
  233.                             $context['_seq'] = twig_ensure_traversable(sw_get_attribute($this->env$this->source$context["variant"], "variation", [], "any"falsefalsefalse50));
  234.                             $context['loop'] = [
  235.                               'parent' => $context['_parent'],
  236.                               'index0' => 0,
  237.                               'index'  => 1,
  238.                               'first'  => true,
  239.                             ];
  240.                             if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  241.                                 $length count($context['_seq']);
  242.                                 $context['loop']['revindex0'] = $length 1;
  243.                                 $context['loop']['revindex'] = $length;
  244.                                 $context['loop']['length'] = $length;
  245.                                 $context['loop']['last'] = === $length;
  246.                             }
  247.                             foreach ($context['_seq'] as $context["_key"] => $context["variation"]) {
  248.                                 // line 51
  249.                                 echo "                                    ";
  250.                                 if (sw_get_attribute($this->env$this->source$context["loop"], "first", [], "any"falsefalsefalse51)) {
  251.                                     echo sw_escape_filter($this->envsw_get_attribute($this->env$this->source$context["variation"], "option", [], "any"falsefalsefalse51), "html"nulltrue);
  252.                                 } else {
  253.                                     echo ", ";
  254.                                     echo sw_escape_filter($this->envsw_get_attribute($this->env$this->source$context["variation"], "option", [], "any"falsefalsefalse51), "html"nulltrue);
  255.                                 }
  256.                                 // line 52
  257.                                 echo "                                ";
  258.                                 ++$context['loop']['index0'];
  259.                                 ++$context['loop']['index'];
  260.                                 $context['loop']['first'] = false;
  261.                                 if (isset($context['loop']['length'])) {
  262.                                     --$context['loop']['revindex0'];
  263.                                     --$context['loop']['revindex'];
  264.                                     $context['loop']['last'] = === $context['loop']['revindex0'];
  265.                                 }
  266.                             }
  267.                             $_parent $context['_parent'];
  268.                             unset($context['_seq'], $context['_iterated'], $context['_key'], $context['variation'], $context['_parent'], $context['loop']);
  269.                             $context array_intersect_key($context$_parent) + $_parent;
  270.                             // line 53
  271.                             echo "                            </td>
  272.                             <td>";
  273.                             // line 55
  274.                             echo sw_escape_filter($this->envsw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source$context["variant"], "customFields", [], "any"falsefalsefalse55), "custom_units_piece_per_pu", [], "any"falsefalsefalse55), "html"nulltrue);
  275.                             echo "</td>
  276.                             <td class=\"d-flex\">";
  277.                             // line 56
  278.                             if (sw_get_attribute($this->env$this->source$context["variant"], "availableStock", [], "any"falsefalsefalse56)) {
  279.                                 echo " <span
  280.                                         class=\"delivery-status-indicator bg-success mx-auto\"></span>";
  281.                             }
  282.                             // line 57
  283.                             echo "</td>
  284.                             <td>";
  285.                             // line 58
  286.                             echo sw_escape_filter($this->env$this->extensions['Shopware\Core\Framework\Adapter\Twig\Filter\CurrencyFilter']->formatCurrency($contexttwig_round((sw_get_attribute($this->env$this->sourcetwig_first($this->envsw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source$context["variant"], "price", [], "any"falsefalsefalse58), "elements", [], "any"falsefalsefalse58)), "net", [], "any"falsefalsefalse58) / sw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source$context["variant"], "customFields", [], "any"falsefalsefalse58), "custom_units_piece_per_pu", [], "any"falsefalsefalse58)), 2"floor")), "html"nulltrue);
  287.                             echo "</td>
  288.                             ";
  289.                             // line 60
  290.                             $context["arrayRuleId"] = twig_array_filter($this->env, ($context["pricesVariant"] ?? null), function ($__el__) use ($context$macros) { $context["el"] = $__el__; return (=== twig_compare(sw_get_attribute($this->env$this->source, ($context["el"] ?? null), "ruleId", [], "any"falsefalsefalse60), ($context["ruleId"] ?? null))); });
  291.                             // line 61
  292.                             echo "                            ";
  293.                             $context['_parent'] = $context;
  294.                             $context['_seq'] = twig_ensure_traversable(range(1, ($context["staplelength"] ?? null)));
  295.                             $context['loop'] = [
  296.                               'parent' => $context['_parent'],
  297.                               'index0' => 0,
  298.                               'index'  => 1,
  299.                               'first'  => true,
  300.                             ];
  301.                             if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  302.                                 $length count($context['_seq']);
  303.                                 $context['loop']['revindex0'] = $length 1;
  304.                                 $context['loop']['revindex'] = $length;
  305.                                 $context['loop']['length'] = $length;
  306.                                 $context['loop']['last'] = === $length;
  307.                             }
  308.                             foreach ($context['_seq'] as $context["_key"] => $context["i"]) {
  309.                                 // line 62
  310.                                 echo "                                ";
  311.                                 $context["mainloop"] = (sw_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsefalse62) + 1);
  312.                                 // line 63
  313.                                 echo "                                ";
  314.                                 if ((>= twig_compare(($context["mainloop"] ?? null), 5))) {
  315.                                     // line 64
  316.                                     echo "                                    <td align=\"center\">
  317.                                         <strong>
  318.                                             ";
  319.                                     // line 66
  320.                                     $context['_parent'] = $context;
  321.                                     $context['_seq'] = twig_ensure_traversable(($context["arrayRuleId"] ?? null));
  322.                                     $context['loop'] = [
  323.                                       'parent' => $context['_parent'],
  324.                                       'index0' => 0,
  325.                                       'index'  => 1,
  326.                                       'first'  => true,
  327.                                     ];
  328.                                     if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  329.                                         $length count($context['_seq']);
  330.                                         $context['loop']['revindex0'] = $length 1;
  331.                                         $context['loop']['revindex'] = $length;
  332.                                         $context['loop']['length'] = $length;
  333.                                         $context['loop']['last'] = === $length;
  334.                                     }
  335.                                     foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
  336.                                         // line 67
  337.                                         echo "                                                ";
  338.                                         if ((=== twig_compare(sw_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsefalse67), ($context["mainloop"] ?? null)))) {
  339.                                             // line 68
  340.                                             echo "                                                    ";
  341.                                             echo sw_escape_filter($this->env$this->extensions['Shopware\Core\Framework\Adapter\Twig\Filter\CurrencyFilter']->formatCurrency($contexttwig_round((sw_get_attribute($this->env$this->sourcetwig_first($this->envsw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source$context["item"], "price", [], "any"falsefalsefalse68), "elements", [], "any"falsefalsefalse68)), "net", [], "any"falsefalsefalse68) / sw_get_attribute($this->env$this->sourcesw_get_attribute($this->env$this->source$context["variant"], "customFields", [], "any"falsefalsefalse68), "custom_units_piece_per_pu", [], "any"falsefalsefalse68)), 2"floor")), "html"nulltrue);
  342.                                             echo "
  343.                                                 ";
  344.                                         }
  345.                                         // line 70
  346.                                         echo "                                            ";
  347.                                         ++$context['loop']['index0'];
  348.                                         ++$context['loop']['index'];
  349.                                         $context['loop']['first'] = false;
  350.                                         if (isset($context['loop']['length'])) {
  351.                                             --$context['loop']['revindex0'];
  352.                                             --$context['loop']['revindex'];
  353.                                             $context['loop']['last'] = === $context['loop']['revindex0'];
  354.                                         }
  355.                                     }
  356.                                     $_parent $context['_parent'];
  357.                                     unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
  358.                                     $context array_intersect_key($context$_parent) + $_parent;
  359.                                     // line 71
  360.                                     echo "                                        </strong>
  361.                                     </td>
  362.                                 ";
  363.                                 }
  364.                                 // line 74
  365.                                 echo "                            ";
  366.                                 ++$context['loop']['index0'];
  367.                                 ++$context['loop']['index'];
  368.                                 $context['loop']['first'] = false;
  369.                                 if (isset($context['loop']['length'])) {
  370.                                     --$context['loop']['revindex0'];
  371.                                     --$context['loop']['revindex'];
  372.                                     $context['loop']['last'] = === $context['loop']['revindex0'];
  373.                                 }
  374.                             }
  375.                             $_parent $context['_parent'];
  376.                             unset($context['_seq'], $context['_iterated'], $context['_key'], $context['i'], $context['_parent'], $context['loop']);
  377.                             $context array_intersect_key($context$_parent) + $_parent;
  378.                             // line 75
  379.                             echo "                            <td>
  380.                                 ";
  381.                             // line 76
  382.                             $this->loadTemplate("@SchilderSysteme/storefront/page/product-detail/buy-widget-form-table.html.twig""@SchilderSysteme/storefront/component/product/table.html.twig"76)->display(twig_array_merge($context, ["productTable" =>                             // line 77
  383. $context["variant"]]));
  384.                             // line 79
  385.                             echo "                            </td>
  386.                         </tr>
  387.                         ";
  388.                         }
  389.                         // line 82
  390.                         echo "                        ";
  391.                         ++$context['loop']['index0'];
  392.                         ++$context['loop']['index'];
  393.                         $context['loop']['first'] = false;
  394.                         if (isset($context['loop']['length'])) {
  395.                             --$context['loop']['revindex0'];
  396.                             --$context['loop']['revindex'];
  397.                             $context['loop']['last'] = === $context['loop']['revindex0'];
  398.                         }
  399.                     }
  400.                     $_parent $context['_parent'];
  401.                     unset($context['_seq'], $context['_iterated'], $context['_key'], $context['variant'], $context['_parent'], $context['loop']);
  402.                     $context array_intersect_key($context$_parent) + $_parent;
  403.                     // line 83
  404.                     echo "                    </table>
  405.                 </div>
  406.             ";
  407.                 }
  408.                 // line 86
  409.                 echo "        ";
  410.             }
  411.             // line 87
  412.             echo "    ";
  413.         }
  414.         
  415.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  416.         
  417.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  418.     }
  419.     public function getTemplateName()
  420.     {
  421.         return "@SchilderSysteme/storefront/component/product/table.html.twig";
  422.     }
  423.     public function getDebugInfo()
  424.     {
  425.         return array (  426 => 87,  423 => 86,  418 => 83,  404 => 82,  399 => 79,  397 => 77,  396 => 76,  393 => 75,  379 => 74,  374 => 71,  360 => 70,  354 => 68,  351 => 67,  334 => 66,  330 => 64,  327 => 63,  324 => 62,  306 => 61,  304 => 60,  299 => 58,  296 => 57,  291 => 56,  287 => 55,  283 => 53,  269 => 52,  261 => 51,  244 => 50,  239 => 48,  236 => 47,  233 => 46,  230 => 45,  213 => 44,  207 => 41,  204 => 40,  190 => 39,  183 => 36,  179 => 34,  174 => 33,  169 => 32,  164 => 31,  160 => 30,  157 => 29,  155 => 28,  152 => 27,  149 => 26,  132 => 25,  128 => 24,  123 => 22,  116 => 18,  109 => 16,  106 => 15,  103 => 14,  97 => 13,  94 => 12,  91 => 11,  88 => 10,  83 => 9,  80 => 8,  77 => 7,  75 => 6,  72 => 5,  69 => 4,  66 => 3,  63 => 2,  44 => 1,);
  426.     }
  427.     public function getSourceContext()
  428.     {
  429.         return new Source("{% block component_product_table_container %}
  430.     {% set variants = page.product.customFields.variants %}
  431.     {% set ruleId = page.product.cheapestPrice.ruleId %}
  432.     {% set staplelength = product.calculatedPrices.elements|length - 1 %}
  433.     {% if variants|length > 0 %}
  434.         {% if page.product.calculatedPrices|length > 1 %}
  435.             {% set bestprice = false %}
  436.             {% for variant in variants|filter((variant) => variant.availableStock == true) %}
  437.                 {% if variant.customFields.custom_units_piece_per_pu != 1 %}
  438.                     {% set bestprice = true %}
  439.                 {% endif %}
  440.             {% endfor %}
  441.             {% if bestprice == true %}
  442.                 <div class=\"product-detail-table-container\">
  443.                     <table class=\"product-detail-table {% if product.calculatedPrices|length > 1 %}has-badge{% endif %}\">
  444.                         <tr class=\"table--header\">
  445.                             <th align=\"center\" class=\"price-list-item\">{{ \"detail.TableArtNr\"|trans|sw_sanitize }}</th>
  446.                             <th align=\"center\" class=\"price-list-item\">Variante</th>
  447.                             <th align=\"center\" class=\"price-list-item\">VE</th>
  448.                             <th align=\"center\"
  449.                                 class=\"price-list-item\">{{ \"detail.tableAvailable\"|trans|sw_sanitize }}</th>
  450.                             <th align=\"center\"
  451.                                 class=\"price-list-item\">{{ \"detail.tableQuantity\"|trans|sw_sanitize }}</th>
  452.                             {% for price in product.calculatedPrices.elements %}
  453.                                 {% if loop.last == false and loop.index<=4 %}
  454.                                     <th align=\"center\" class=\"price-list-item\">
  455.                                         {% if product.calculatedPrices|length > 1 %}
  456.                                             <div class=\"discount-badge\">
  457.                                                 {% if loop.index == 1 %}-5%{% endif %}
  458.                                                 {% if loop.index == 2 %}-8%{% endif %}
  459.                                                 {% if loop.index == 3 %}-10%{% endif %}
  460.                                                 {% if loop.index == 4 %}-12%{% endif %}
  461.                                             </div>
  462.                                         {% endif %}
  463.                                         {{ (price.quantity + 1) }} VE / Stück
  464.                                     </th>
  465.                                 {% endif %}
  466.                             {% endfor %}
  467.                             <th align=\"center\"
  468.                                 class=\"price-list-item\">{{ \"detail.tableDesiredQuantityVE\"|trans|sw_sanitize }}</th>
  469.                         </tr>
  470.                         <tr>
  471.                             {% for variant in variants|filter((variant) => variant.availableStock == true) %}
  472.                             {% if variant.customFields.custom_units_piece_per_pu !='1' %}
  473.                             {% set pricesVariant = variant.prices.elements|sort((a, b) => a.quantityStart <=> b.quantityStart) %}
  474.                         <tr>
  475.                             <td>{{ variant.productNumber }}</td>
  476.                             <td>
  477.                                 {% for variation in variant.variation %}
  478.                                     {% if loop.first %}{{ variation.option }}{% else %}, {{ variation.option }}{% endif %}
  479.                                 {% endfor %}
  480.                             </td>
  481.                             <td>{{ variant.customFields.custom_units_piece_per_pu }}</td>
  482.                             <td class=\"d-flex\">{% if variant.availableStock %} <span
  483.                                         class=\"delivery-status-indicator bg-success mx-auto\"></span>{% endif %}</td>
  484.                             <td>{{ (variant.price.elements|first.net/variant.customFields.custom_units_piece_per_pu)|round(2, 'floor')|currency }}</td>
  485.                             {% set arrayRuleId = pricesVariant|filter((el) => el.ruleId == ruleId) %}
  486.                             {% for i in 1..staplelength %}
  487.                                 {% set mainloop = loop.index + 1 %}
  488.                                 {% if mainloop <= 5 %}
  489.                                     <td align=\"center\">
  490.                                         <strong>
  491.                                             {% for item in arrayRuleId %}
  492.                                                 {% if loop.index == mainloop %}
  493.                                                     {{ (item.price.elements|first.net/variant.customFields.custom_units_piece_per_pu)|round(2, 'floor')|currency }}
  494.                                                 {% endif %}
  495.                                             {% endfor %}
  496.                                         </strong>
  497.                                     </td>
  498.                                 {% endif %}
  499.                             {% endfor %}
  500.                             <td>
  501.                                 {% sw_include '@Storefront/storefront/page/product-detail/buy-widget-form-table.html.twig' with {
  502.                                     productTable: variant
  503.                                 } %}
  504.                             </td>
  505.                         </tr>
  506.                         {% endif %}
  507.                         {% endfor %}
  508.                     </table>
  509.                 </div>
  510.             {% endif %}
  511.         {% endif %}
  512.     {% endif %}
  513. {% endblock %}""@SchilderSysteme/storefront/component/product/table.html.twig""/data/www/stage.tuerschildshop/custom/plugins/SchilderSysteme/src/Resources/views/storefront/component/product/table.html.twig");
  514.     }
  515. }