<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\CoreExtension;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Source;
use Twig\Template;
use Twig\TemplateWrapper;
/* @Portal/Catalog/catalog-nav.html.twig */
class __TwigTemplate_dbbbccd870f8d21561e0fa2a63a54fe1 extends Template
{
private Source $source;
/**
* @var array<string, Template>
*/
private array $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->parent = false;
$this->blocks = [
];
}
protected function doDisplay(array $context, array $blocks = []): iterable
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@Portal/Catalog/catalog-nav.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@Portal/Catalog/catalog-nav.html.twig"));
// line 2
yield "<div class=\"swiper_selection_catalog\">
\t<div class=\"swiper selection__catalog__car-slider selection__catalog__wrapper\">
\t\t<div class=\"swiper-wrapper selection-swiper-wrapper\">
\t\t\t";
// line 5
$context['_parent'] = $context;
$context['_seq'] = CoreExtension::ensureTraversable((isset($context["catalogNav"]) || array_key_exists("catalogNav", $context) ? $context["catalogNav"] : (function () { throw new RuntimeError('Variable "catalogNav" does not exist.', 5, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
// line 6
yield "\t\t\t\t";
if (CoreExtension::getAttribute($this->env, $this->source, $context["item"], "brand", [], "any", true, true, false, 6)) {
// line 7
yield "\t\t\t\t\t<a href=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "url", [], "any", false, false, false, 7), "html", null, true);
yield "\" class=\"swiper-slide selection__catalog__box\">
\t\t\t\t\t\t<img class=\"catalog__box-img\" src=\"";
// line 8
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getRuntime('Sonata\MediaBundle\Twig\MediaRuntime')->path(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["item"], "brand", [], "any", false, false, false, 8), "logo", [], "any", false, false, false, 8), "reference"), "html", null, true);
yield "\" alt=\"\">
\t\t\t\t\t\t<span class=\"catalog__box-name catalog__box-height\">";
// line 9
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["item"], "brand", [], "any", false, false, false, 9), "name", [], "any", false, false, false, 9), "html", null, true);
yield "</span>
\t\t\t\t\t\t<div class=\"catalog__box-price catalog__box-price-step-2\">";
// line 10
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("new_catalog.from", [], "portal_base"), "html", null, true);
yield "
\t\t\t\t\t\t\t";
// line 11
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['DcSiteBundle\Twig\TwigDcExtension']->priceFilter(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "min_price", [], "any", false, false, false, 11)), "html", null, true);
yield "
\t\t\t\t\t\t\tгрн -
\t\t\t\t\t\t\t<span>";
// line 13
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "vehicle_count", [], "any", false, false, false, 13), "html", null, true);
yield "
\t\t\t\t\t\t\t\tавто</span>
\t\t\t\t\t\t</div>
\t\t\t\t\t</a>
\t\t\t\t";
} elseif (CoreExtension::getAttribute($this->env, $this->source, // line 17
$context["item"], "model", [], "any", true, true, false, 17)) {
// line 18
yield "\t\t\t\t\t<a href=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "url", [], "any", false, false, false, 18), "html", null, true);
yield "\" class=\"swiper-slide selection__catalog__box catalog__box-left-car\">
\t\t\t\t\t\t<img class=\"catalog__box-img catalog__box-img-car\" src=\"";
// line 19
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getRuntime('Sonata\MediaBundle\Twig\MediaRuntime')->path(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["item"], "model", [], "any", false, false, false, 19), "image", [], "any", false, false, false, 19), "reference"), "html", null, true);
yield "\" alt=\"\">
\t\t\t\t\t\t<span class=\"catalog__box-name\">";
// line 20
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["item"], "model", [], "any", false, false, false, 20), "title", [], "any", false, false, false, 20), "html", null, true);
yield "</span>
\t\t\t\t\t\t<div class=\"catalog__box-price\">";
// line 21
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("new_catalog.from", [], "portal_base"), "html", null, true);
yield "
\t\t\t\t\t\t\t";
// line 22
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['DcSiteBundle\Twig\TwigDcExtension']->priceFilter(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "min_price", [], "any", false, false, false, 22)), "html", null, true);
yield "
\t\t\t\t\t\t\tгрн -
\t\t\t\t\t\t\t<span>";
// line 24
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "vehicle_count", [], "any", false, false, false, 24), "html", null, true);
yield "
\t\t\t\t\t\t\t\tавто</span>
\t\t\t\t\t\t\t<img src=\"";
// line 26
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("/bundles/portal/img/catalog-car/head-icon/arrow-head.svg"), "html", null, true);
yield "\" alt=\"\">
\t\t\t\t\t\t</div>
\t\t\t\t\t</a>
\t\t\t\t";
} else {
// line 30
yield "\t\t\t\t\t<a href=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "url", [], "any", false, false, false, 30), "html", null, true);
yield "\" class=\"swiper-slide selection__catalog__box\">
\t\t\t\t\t\t<img class=\"catalog__box-img\" src=\"";
// line 31
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl((("/bundles/portal/img/catalog-car/head-icon/catalog-head-icon-" . CoreExtension::getAttribute($this->env, $this->source, $context["item"], "tag", [], "any", false, false, false, 31)) . ".svg")), "html", null, true);
yield "\" alt=\"\">
\t\t\t\t\t\t<span class=\"catalog__box-name\">";
// line 32
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "title", [], "any", false, false, false, 32), "html", null, true);
yield "</span>
\t\t\t\t\t\t<div class=\"catalog__box-price\">";
// line 33
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("new_catalog.from", [], "portal_base"), "html", null, true);
yield "
\t\t\t\t\t\t\t";
// line 34
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['DcSiteBundle\Twig\TwigDcExtension']->priceFilter(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "min_price", [], "any", false, false, false, 34)), "html", null, true);
yield "
\t\t\t\t\t\t\tгрн
\t\t\t\t\t\t\t<img src=\"";
// line 36
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("/bundles/portal/img/catalog-car/head-icon/arrow-head.svg"), "html", null, true);
yield "\" alt=\"\">
\t\t\t\t\t\t</div>
\t\t\t\t\t</a>
\t\t\t\t";
}
// line 40
yield "\t\t\t";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_key'], $context['item'], $context['_parent']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 41
yield "\t\t</div>
\t\t<div class=\"swiper-button-next\"></div>
\t</div>
\t<div class=\"swiper-button-prev button-selection-catalog\"></div>
</div>
";
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
yield from [];
}
/**
* @codeCoverageIgnore
*/
public function getTemplateName(): string
{
return "@Portal/Catalog/catalog-nav.html.twig";
}
/**
* @codeCoverageIgnore
*/
public function isTraitable(): bool
{
return false;
}
/**
* @codeCoverageIgnore
*/
public function getDebugInfo(): array
{
return array ( 160 => 41, 154 => 40, 147 => 36, 142 => 34, 138 => 33, 134 => 32, 130 => 31, 125 => 30, 118 => 26, 113 => 24, 108 => 22, 104 => 21, 100 => 20, 96 => 19, 91 => 18, 89 => 17, 82 => 13, 77 => 11, 73 => 10, 69 => 9, 65 => 8, 60 => 7, 57 => 6, 53 => 5, 48 => 2,);
}
public function getSourceContext(): Source
{
return new Source("{# STEP 1 ... #}
<div class=\"swiper_selection_catalog\">
\t<div class=\"swiper selection__catalog__car-slider selection__catalog__wrapper\">
\t\t<div class=\"swiper-wrapper selection-swiper-wrapper\">
\t\t\t{% for item in catalogNav %}
\t\t\t\t{% if item.brand is defined %}
\t\t\t\t\t<a href=\"{{ item.url }}\" class=\"swiper-slide selection__catalog__box\">
\t\t\t\t\t\t<img class=\"catalog__box-img\" src=\"{{ sonata_path(item.brand.logo, 'reference') }}\" alt=\"\">
\t\t\t\t\t\t<span class=\"catalog__box-name catalog__box-height\">{{ item.brand.name }}</span>
\t\t\t\t\t\t<div class=\"catalog__box-price catalog__box-price-step-2\">{{ 'new_catalog.from'|trans({}, 'portal_base') }}
\t\t\t\t\t\t\t{{ item.min_price|price }}
\t\t\t\t\t\t\tгрн -
\t\t\t\t\t\t\t<span>{{ item.vehicle_count }}
\t\t\t\t\t\t\t\tавто</span>
\t\t\t\t\t\t</div>
\t\t\t\t\t</a>
\t\t\t\t{% elseif item.model is defined %}
\t\t\t\t\t<a href=\"{{ item.url }}\" class=\"swiper-slide selection__catalog__box catalog__box-left-car\">
\t\t\t\t\t\t<img class=\"catalog__box-img catalog__box-img-car\" src=\"{{ sonata_path(item.model.image, 'reference') }}\" alt=\"\">
\t\t\t\t\t\t<span class=\"catalog__box-name\">{{ item.model.title }}</span>
\t\t\t\t\t\t<div class=\"catalog__box-price\">{{ 'new_catalog.from'|trans({}, 'portal_base') }}
\t\t\t\t\t\t\t{{ item.min_price|price }}
\t\t\t\t\t\t\tгрн -
\t\t\t\t\t\t\t<span>{{ item.vehicle_count }}
\t\t\t\t\t\t\t\tавто</span>
\t\t\t\t\t\t\t<img src=\"{{ asset('/bundles/portal/img/catalog-car/head-icon/arrow-head.svg') }}\" alt=\"\">
\t\t\t\t\t\t</div>
\t\t\t\t\t</a>
\t\t\t\t{% else %}
\t\t\t\t\t<a href=\"{{ item.url }}\" class=\"swiper-slide selection__catalog__box\">
\t\t\t\t\t\t<img class=\"catalog__box-img\" src=\"{{ asset('/bundles/portal/img/catalog-car/head-icon/catalog-head-icon-'~item.tag~'.svg') }}\" alt=\"\">
\t\t\t\t\t\t<span class=\"catalog__box-name\">{{ item.title }}</span>
\t\t\t\t\t\t<div class=\"catalog__box-price\">{{ 'new_catalog.from'|trans({}, 'portal_base') }}
\t\t\t\t\t\t\t{{ item.min_price|price }}
\t\t\t\t\t\t\tгрн
\t\t\t\t\t\t\t<img src=\"{{ asset('/bundles/portal/img/catalog-car/head-icon/arrow-head.svg') }}\" alt=\"\">
\t\t\t\t\t\t</div>
\t\t\t\t\t</a>
\t\t\t\t{% endif %}
\t\t\t{% endfor %}
\t\t</div>
\t\t<div class=\"swiper-button-next\"></div>
\t</div>
\t<div class=\"swiper-button-prev button-selection-catalog\"></div>
</div>
", "@Portal/Catalog/catalog-nav.html.twig", "/var/www/vidi.ua/releases/251027-872b0c76/src/PortalBundle/Resources/views/Catalog/catalog-nav.html.twig");
}
}