var/cache/dev/twig/e5/e558259b7d4120d1d57eab1cde64e293.php line 114

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. /* @SyliusShop/Common/_addToWishlist.html.twig */
  14. class __TwigTemplate_bb6879cf95f10bc24494256f16365423 extends \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->parent false;
  23.         $this->blocks = [
  24.         ];
  25.     }
  26.     protected function doDisplay(array $context, array $blocks = [])
  27.     {
  28.         $macros $this->macros;
  29.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  30.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@SyliusShop/Common/_addToWishlist.html.twig"));
  31.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  32.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@SyliusShop/Common/_addToWishlist.html.twig"));
  33.         // line 1
  34.         if (twig_get_attribute($this->env$this->source, (isset($context["app"]) || array_key_exists("app"$context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.'1$this->source); })()), "user", [], "any"falsefalsefalse1)) {
  35.             // line 2
  36.             echo "    ";
  37.             if ((twig_length_filter($this->env$this->extensions['BitBag\SyliusWishlistPlugin\Twig\WishlistExtension']->findAllByShopUserAndToken(twig_get_attribute($this->env$this->source, (isset($context["app"]) || array_key_exists("app"$context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.'2$this->source); })()), "user", [], "any"falsefalsefalse2))) < 2)) {
  38.                 // line 3
  39.                 echo "        <a
  40.                 href=\"";
  41.                 // line 4
  42.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("bitbag_sylius_wishlist_plugin_shop_wishlist_add_product", ["productId" => twig_get_attribute($this->env$this->source, (isset($context["product"]) || array_key_exists("product"$context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.'4$this->source); })()), "id", [], "any"falsefalsefalse4)]), "html"nulltrue);
  43.                 echo "\"
  44.                 class=\"bitbag-add-to-wishlist ui icon labeled button blue\"
  45.                 data-product-name=\"";
  46.                 // line 6
  47.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["product"]) || array_key_exists("product"$context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.'6$this->source); })()), "name", [], "any"falsefalsefalse6), "html"nulltrue);
  48.                 echo "\"
  49.                 ";
  50.                 // line 7
  51.                 echo $this->env->getFunction('sylius_test_html_attribute')->getCallable()("wishlist-add-product");
  52.                 echo "
  53.         >
  54.             <i class=\"icon heart\"></i>
  55. ";
  56.                 // line 11
  57.                 echo "        </a>
  58.     ";
  59.             } else {
  60.                 // line 13
  61.                 echo "        <div class=\"ui dropdown button\">
  62.             <i class=\"heart icon\"></i>
  63.             <div class=\"menu\" data-bb-wishlist-hrefs=\"hrefs-adding-variant\">
  64.                 ";
  65.                 // line 16
  66.                 $context['_parent'] = $context;
  67.                 $context['_seq'] = twig_ensure_traversable($this->extensions['BitBag\SyliusWishlistPlugin\Twig\WishlistExtension']->findAllByShopUserAndToken(twig_get_attribute($this->env$this->source, (isset($context["app"]) || array_key_exists("app"$context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.'16$this->source); })()), "user", [], "any"falsefalsefalse16)));
  68.                 foreach ($context['_seq'] as $context["_key"] => $context["wishlist"]) {
  69.                     // line 17
  70.                     echo "                    <a
  71.                             href=\"";
  72.                     // line 18
  73.                     echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("bitbag_sylius_wishlist_plugin_shop_wishlist_add_product_to_selected_wishlist", ["wishlistId" => twig_get_attribute($this->env$this->source$context["wishlist"], "id", [], "any"falsefalsefalse18), "productId" => twig_get_attribute($this->env$this->source, (isset($context["product"]) || array_key_exists("product"$context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.'18$this->source); })()), "id", [], "any"falsefalsefalse18)]), "html"nulltrue);
  74.                     echo "\"
  75.                             class=\"item\"
  76.                             data-product-name=\"";
  77.                     // line 20
  78.                     echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["product"]) || array_key_exists("product"$context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.'20$this->source); })()), "name", [], "any"falsefalsefalse20), "html"nulltrue);
  79.                     echo "\"
  80.                             ";
  81.                     // line 21
  82.                     echo $this->env->getFunction('sylius_test_html_attribute')->getCallable()("bitbag-add-to-wishlist");
  83.                     echo "
  84.                     >
  85.                         <span>
  86.                             ";
  87.                     // line 24
  88.                     echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["wishlist"], "name", [], "any"falsefalsefalse24), "html"nulltrue);
  89.                     echo "
  90.                         </span>
  91.                     </a>
  92.                 ";
  93.                 }
  94.                 $_parent $context['_parent'];
  95.                 unset($context['_seq'], $context['_iterated'], $context['_key'], $context['wishlist'], $context['_parent'], $context['loop']);
  96.                 $context array_intersect_key($context$_parent) + $_parent;
  97.                 // line 28
  98.                 echo "            </div>
  99.         </div>
  100.     ";
  101.             }
  102.         } else {
  103.             // line 32
  104.             echo "    ";
  105.             if ((twig_length_filter($this->env$this->extensions['BitBag\SyliusWishlistPlugin\Twig\WishlistExtension']->findAllByAnonymousAndChannel(twig_get_attribute($this->env$this->source, (isset($context["sylius"]) || array_key_exists("sylius"$context) ? $context["sylius"] : (function () { throw new RuntimeError('Variable "sylius" does not exist.'32$this->source); })()), "channel", [], "any"falsefalsefalse32))) < 2)) {
  106.                 // line 33
  107.                 echo "        <a
  108.                 href=\"";
  109.                 // line 34
  110.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("bitbag_sylius_wishlist_plugin_shop_wishlist_add_product", ["productId" => twig_get_attribute($this->env$this->source, (isset($context["product"]) || array_key_exists("product"$context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.'34$this->source); })()), "id", [], "any"falsefalsefalse34)]), "html"nulltrue);
  111.                 echo "\"
  112.                 class=\"bitbag-add-to-wishlist ui icon labeled button blue\"
  113.                 data-product-name=\"";
  114.                 // line 36
  115.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["product"]) || array_key_exists("product"$context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.'36$this->source); })()), "name", [], "any"falsefalsefalse36), "html"nulltrue);
  116.                 echo "\"
  117.                 ";
  118.                 // line 37
  119.                 echo $this->env->getFunction('sylius_test_html_attribute')->getCallable()("wishlist-add-product");
  120.                 echo "
  121.         >
  122.             <i class=\"icon heart\"></i>
  123. ";
  124.                 // line 41
  125.                 echo "        </a>
  126.     ";
  127.             } else {
  128.                 // line 43
  129.                 echo "        <div class=\"ui dropdown button\">
  130.             <i class=\"heart icon\"></i>
  131.             <div class=\"menu\" data-bb-wishlist-hrefs=\"hrefs-adding-variant\">
  132.                 ";
  133.                 // line 46
  134.                 $context['_parent'] = $context;
  135.                 $context['_seq'] = twig_ensure_traversable($this->extensions['BitBag\SyliusWishlistPlugin\Twig\WishlistExtension']->findAllByAnonymousAndChannel(twig_get_attribute($this->env$this->source, (isset($context["sylius"]) || array_key_exists("sylius"$context) ? $context["sylius"] : (function () { throw new RuntimeError('Variable "sylius" does not exist.'46$this->source); })()), "channel", [], "any"falsefalsefalse46)));
  136.                 foreach ($context['_seq'] as $context["_key"] => $context["wishlist"]) {
  137.                     // line 47
  138.                     echo "                    <a
  139.                             href=\"";
  140.                     // line 48
  141.                     echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("bitbag_sylius_wishlist_plugin_shop_wishlist_add_product_to_selected_wishlist", ["wishlistId" => twig_get_attribute($this->env$this->source$context["wishlist"], "id", [], "any"falsefalsefalse48), "productId" => twig_get_attribute($this->env$this->source, (isset($context["product"]) || array_key_exists("product"$context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.'48$this->source); })()), "id", [], "any"falsefalsefalse48)]), "html"nulltrue);
  142.                     echo "\"
  143.                             class=\"item\"
  144.                             data-product-name=\"";
  145.                     // line 50
  146.                     echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["product"]) || array_key_exists("product"$context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.'50$this->source); })()), "name", [], "any"falsefalsefalse50), "html"nulltrue);
  147.                     echo "\"
  148.                             ";
  149.                     // line 51
  150.                     echo $this->env->getFunction('sylius_test_html_attribute')->getCallable()("wishlist-add-product");
  151.                     echo "
  152.                     >
  153.                         <span>
  154.                             ";
  155.                     // line 54
  156.                     echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["wishlist"], "name", [], "any"falsefalsefalse54), "html"nulltrue);
  157.                     echo "
  158.                         </span>
  159.                     </a>
  160.                 ";
  161.                 }
  162.                 $_parent $context['_parent'];
  163.                 unset($context['_seq'], $context['_iterated'], $context['_key'], $context['wishlist'], $context['_parent'], $context['loop']);
  164.                 $context array_intersect_key($context$_parent) + $_parent;
  165.                 // line 58
  166.                 echo "            </div>
  167.         </div>
  168.     ";
  169.             }
  170.             // line 61
  171.             echo "    <style>
  172.         /*.bitbag-add-to-wishlist.ui.icon.labeled.button.blue{*/
  173.         /*    padding: 0 !important;*/
  174.         /*    position: absolute;*/
  175.         /*    top: 2rem;*/
  176.         /*    right: 4rem;*/
  177.         /*    z-index: 999;*/
  178.         /*    width: fit-content;*/
  179.         /*}*/
  180.         /*.bitbag-add-to-wishlist.ui.icon.labeled.button.blue i{*/
  181.         /*    background-color: transparent !important;*/
  182.         /*    font-size: var(--sm-fz) !important;*/
  183.         /*}*/
  184.         /*.bitbag-add-to-wishlist.ui.icon.labeled.button.blue i:hover{*/
  185.         /*    color: #E35E31 !important;*/
  186.         /*}*/
  187.     </style>
  188. ";
  189.         }
  190.         // line 79
  191.         echo "
  192. ";
  193.         
  194.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  195.         
  196.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  197.     }
  198.     public function getTemplateName()
  199.     {
  200.         return "@SyliusShop/Common/_addToWishlist.html.twig";
  201.     }
  202.     public function isTraitable()
  203.     {
  204.         return false;
  205.     }
  206.     public function getDebugInfo()
  207.     {
  208.         return array (  200 => 79,  180 => 61,  175 => 58,  165 => 54,  159 => 51,  155 => 50,  150 => 48,  147 => 47,  143 => 46,  138 => 43,  134 => 41,  128 => 37,  124 => 36,  119 => 34,  116 => 33,  113 => 32,  107 => 28,  97 => 24,  91 => 21,  87 => 20,  82 => 18,  79 => 17,  75 => 16,  70 => 13,  66 => 11,  60 => 7,  56 => 6,  51 => 4,  48 => 3,  45 => 2,  43 => 1,);
  209.     }
  210.     public function getSourceContext()
  211.     {
  212.         return new Source("{% if app.user %}
  213.     {% if findAllByShopUserAndToken(app.user)|length < 2 %}
  214.         <a
  215.                 href=\"{{ path('bitbag_sylius_wishlist_plugin_shop_wishlist_add_product', {'productId': product.id}) }}\"
  216.                 class=\"bitbag-add-to-wishlist ui icon labeled button blue\"
  217.                 data-product-name=\"{{ product.name }}\"
  218.                 {{ sylius_test_html_attribute('wishlist-add-product') }}
  219.         >
  220.             <i class=\"icon heart\"></i>
  221. {#            {{ 'bitbag_sylius_wishlist_plugin.ui.add_to_wishlist'|trans }}#}
  222.         </a>
  223.     {% else %}
  224.         <div class=\"ui dropdown button\">
  225.             <i class=\"heart icon\"></i>
  226.             <div class=\"menu\" data-bb-wishlist-hrefs=\"hrefs-adding-variant\">
  227.                 {% for wishlist in findAllByShopUserAndToken(app.user)  %}
  228.                     <a
  229.                             href=\"{{ path('bitbag_sylius_wishlist_plugin_shop_wishlist_add_product_to_selected_wishlist', {'wishlistId': wishlist.id, 'productId': product.id}) }}\"
  230.                             class=\"item\"
  231.                             data-product-name=\"{{ product.name }}\"
  232.                             {{ sylius_test_html_attribute('bitbag-add-to-wishlist') }}
  233.                     >
  234.                         <span>
  235.                             {{ wishlist.name }}
  236.                         </span>
  237.                     </a>
  238.                 {% endfor %}
  239.             </div>
  240.         </div>
  241.     {% endif %}
  242. {% else %}
  243.     {% if findAllByAnonymousAndChannel(sylius.channel)|length < 2 %}
  244.         <a
  245.                 href=\"{{ path('bitbag_sylius_wishlist_plugin_shop_wishlist_add_product', {'productId': product.id}) }}\"
  246.                 class=\"bitbag-add-to-wishlist ui icon labeled button blue\"
  247.                 data-product-name=\"{{ product.name }}\"
  248.                 {{ sylius_test_html_attribute('wishlist-add-product') }}
  249.         >
  250.             <i class=\"icon heart\"></i>
  251. {#            {{ 'bitbag_sylius_wishlist_plugin.ui.add_to_wishlist'|trans }}#}
  252.         </a>
  253.     {% else %}
  254.         <div class=\"ui dropdown button\">
  255.             <i class=\"heart icon\"></i>
  256.             <div class=\"menu\" data-bb-wishlist-hrefs=\"hrefs-adding-variant\">
  257.                 {% for wishlist in findAllByAnonymousAndChannel(sylius.channel) %}
  258.                     <a
  259.                             href=\"{{ path('bitbag_sylius_wishlist_plugin_shop_wishlist_add_product_to_selected_wishlist', {'wishlistId': wishlist.id, 'productId': product.id}) }}\"
  260.                             class=\"item\"
  261.                             data-product-name=\"{{ product.name }}\"
  262.                             {{ sylius_test_html_attribute('wishlist-add-product') }}
  263.                     >
  264.                         <span>
  265.                             {{ wishlist.name }}
  266.                         </span>
  267.                     </a>
  268.                 {% endfor %}
  269.             </div>
  270.         </div>
  271.     {% endif %}
  272.     <style>
  273.         /*.bitbag-add-to-wishlist.ui.icon.labeled.button.blue{*/
  274.         /*    padding: 0 !important;*/
  275.         /*    position: absolute;*/
  276.         /*    top: 2rem;*/
  277.         /*    right: 4rem;*/
  278.         /*    z-index: 999;*/
  279.         /*    width: fit-content;*/
  280.         /*}*/
  281.         /*.bitbag-add-to-wishlist.ui.icon.labeled.button.blue i{*/
  282.         /*    background-color: transparent !important;*/
  283.         /*    font-size: var(--sm-fz) !important;*/
  284.         /*}*/
  285.         /*.bitbag-add-to-wishlist.ui.icon.labeled.button.blue i:hover{*/
  286.         /*    color: #E35E31 !important;*/
  287.         /*}*/
  288.     </style>
  289. {% endif %}
  290. ""@SyliusShop/Common/_addToWishlist.html.twig""/var/www/Bikers/templates/bundles/SyliusShopBundle/Common/_addToWishlist.html.twig");
  291.     }
  292. }