<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
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;
/* Slivki/comments/comments_live.html.twig */
class __TwigTemplate_c5869eaa945019e1fa57c1e5795ef0fc72c1226bd2e98ff78f08b205520e324d extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'stylesheets' => [$this, 'block_stylesheets'],
'mainColumnClass' => [$this, 'block_mainColumnClass'],
'header' => [$this, 'block_header'],
'main_content' => [$this, 'block_main_content'],
'popups' => [$this, 'block_popups'],
'javascripts' => [$this, 'block_javascripts'],
'assetsBottom' => [$this, 'block_assetsBottom'],
];
}
protected function doGetParent(array $context)
{
// line 1
return "base.html.twig";
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Slivki/comments/comments_live.html.twig"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Slivki/comments/comments_live.html.twig"));
$this->parent = $this->loadTemplate("base.html.twig", "Slivki/comments/comments_live.html.twig", 1);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
}
// line 3
public function block_stylesheets($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "stylesheets"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "stylesheets"));
// line 4
echo " <link rel=\"stylesheet\" href=\"/css/swiper/swiper.min.css\" />
";
// line 5
$this->displayParentBlock("stylesheets", $context, $blocks);
echo "
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 8
public function block_mainColumnClass($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "mainColumnClass"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "mainColumnClass"));
// line 9
echo " ";
$this->displayParentBlock("mainColumnClass", $context, $blocks);
echo "
one-column comments-live-content
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 12
public function block_header($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "header"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "header"));
// line 13
echo " ";
if ($this->extensions['Slivki\Twig\SlivkiTwigExtension']->isMobileDevice()) {
// line 14
echo " ";
$this->loadTemplate("Slivki/comments/comments_live.html.twig", "Slivki/comments/comments_live.html.twig", 14, "1885919430")->display($context);
// line 22
echo " ";
} else {
// line 23
echo " ";
$this->loadTemplate("Slivki/comments/comments_live.html.twig", "Slivki/comments/comments_live.html.twig", 23, "1702376164")->display($context);
// line 28
echo " ";
}
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 31
public function block_main_content($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "main_content"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "main_content"));
// line 32
echo " <div id=\"commentsBox\">
<div class=\"breadcrumbs\">
<a href=\"";
// line 34
echo twig_escape_filter($this->env, (isset($context["base_url"]) || array_key_exists("base_url", $context) ? $context["base_url"] : (function () { throw new RuntimeError('Variable "base_url" does not exist.', 34, $this->source); })()), "html", null, true);
echo "\">Главная</a>
";
// line 35
if (array_key_exists("category", $context)) {
// line 36
echo " <i class=\"fa fa-angle-right\"></i> <a href=\"";
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("commentsLive");
echo "\">Отзывы</a>
";
// line 37
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["parentCategories"]) || array_key_exists("parentCategories", $context) ? $context["parentCategories"] : (function () { throw new RuntimeError('Variable "parentCategories" does not exist.', 37, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["parentCategory"]) {
// line 38
echo " <i class=\"fa fa-angle-right\"></i> <a href=\"/otzyvy";
echo twig_escape_filter($this->env, $this->extensions['Slivki\Twig\SlivkiTwigExtension']->getCategoryURL($context["parentCategory"]), "html", null, true);
echo "\">";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["parentCategory"], "getName", [], "method", false, false, false, 38), "html", null, true);
echo "</a>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['parentCategory'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 40
echo " <i class=\"fa fa-angle-right\"></i> ";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["category"]) || array_key_exists("category", $context) ? $context["category"] : (function () { throw new RuntimeError('Variable "category" does not exist.', 40, $this->source); })()), "getName", [], "method", false, false, false, 40), "html", null, true);
echo "
";
} else {
// line 42
echo " <i class=\"fa fa-angle-right\"></i> Отзывы
";
}
// line 44
echo " </div>
<div class=\"clear\"></div>
<div class=\"stock-group-header\">
";
// line 47
if (array_key_exists("title", $context)) {
// line 48
echo " <div class=\"title\">";
echo (isset($context["title"]) || array_key_exists("title", $context) ? $context["title"] : (function () { throw new RuntimeError('Variable "title" does not exist.', 48, $this->source); })());
echo "</div>
";
}
// line 50
echo " ";
if (array_key_exists("subCategories", $context)) {
// line 51
echo " <div class=\"subcategories-list\">
";
// line 52
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["subCategories"]) || array_key_exists("subCategories", $context) ? $context["subCategories"] : (function () { throw new RuntimeError('Variable "subCategories" does not exist.', 52, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["subCategory"]) {
// line 53
echo " <a href=\"";
echo twig_escape_filter($this->env, $this->extensions['Slivki\Twig\SlivkiTwigExtension']->getURL(twig_constant("Slivki\\Repository\\SeoRepository::RESOURCE_URL_CATEGORY_COMMENTS"), twig_get_attribute($this->env, $this->source, $context["subCategory"], "getID", [], "method", false, false, false, 53)), "html", null, true);
echo "\">
";
// line 54
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["subCategory"], "getName", [], "method", false, false, false, 54), "html", null, true);
echo "
<span class=\"green\">(";
// line 55
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["subCategory"], "getEntityCount", [], "method", false, false, false, 55), "html", null, true);
echo ")</span>
</a>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['subCategory'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 58
echo " </div>
";
}
// line 60
echo " </div>
<div class=\"clear\"></div>
";
// line 62
if (array_key_exists("categoryID", $context)) {
// line 63
echo " ";
echo $this->extensions['Slivki\Twig\SlivkiTwigExtension']->getUserCommentsMediaBlockByEntityID($this->env, (isset($context["categoryID"]) || array_key_exists("categoryID", $context) ? $context["categoryID"] : (function () { throw new RuntimeError('Variable "categoryID" does not exist.', 63, $this->source); })()), "category");
echo "
";
} else {
// line 65
echo " ";
if (array_key_exists("offerID", $context)) {
// line 66
echo " ";
$context["userCommentMediaBlock"] = $this->extensions['Slivki\Twig\SlivkiTwigExtension']->getUserCommentsMediaBlockByEntityID($this->env, (isset($context["offerID"]) || array_key_exists("offerID", $context) ? $context["offerID"] : (function () { throw new RuntimeError('Variable "offerID" does not exist.', 66, $this->source); })()), "offer");
// line 67
echo " ";
$context["offerSupplierPhotoBlock"] = $this->extensions['Slivki\Twig\SlivkiTwigExtension']->getSupplierOfferPhotoBlockByOfferID($this->env, (isset($context["offerID"]) || array_key_exists("offerID", $context) ? $context["offerID"] : (function () { throw new RuntimeError('Variable "offerID" does not exist.', 67, $this->source); })()));
// line 68
echo " ";
if (((0 !== twig_compare((isset($context["userCommentMediaBlock"]) || array_key_exists("userCommentMediaBlock", $context) ? $context["userCommentMediaBlock"] : (function () { throw new RuntimeError('Variable "userCommentMediaBlock" does not exist.', 68, $this->source); })()), "")) && (0 !== twig_compare((isset($context["offerSupplierPhotoBlock"]) || array_key_exists("offerSupplierPhotoBlock", $context) ? $context["offerSupplierPhotoBlock"] : (function () { throw new RuntimeError('Variable "offerSupplierPhotoBlock" does not exist.', 68, $this->source); })()), "")))) {
// line 69
echo " <ul id=\"commentPhotoTabs\" class=\"nav nav-tabs\" role=\"tablist\">
<li class=\"active single-line\"><a href=\"#commentSupplierPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото работ</a></li>
<li class=\"single-line\"><a href=\"#commentUserPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото из отзывов</a></li>
</ul>
<div class=\"tab-content\">
<div class=\"tab-pane fade\" id=\"commentSupplierPhotoTab\">
";
// line 75
echo (isset($context["offerSupplierPhotoBlock"]) || array_key_exists("offerSupplierPhotoBlock", $context) ? $context["offerSupplierPhotoBlock"] : (function () { throw new RuntimeError('Variable "offerSupplierPhotoBlock" does not exist.', 75, $this->source); })());
echo "
</div>
<div class=\"tab-pane fade in active show\" id=\"commentUserPhotoTab\">
";
// line 78
echo (isset($context["userCommentMediaBlock"]) || array_key_exists("userCommentMediaBlock", $context) ? $context["userCommentMediaBlock"] : (function () { throw new RuntimeError('Variable "userCommentMediaBlock" does not exist.', 78, $this->source); })());
echo "
</div>
</div>
";
} elseif ((0 !== twig_compare( // line 81
(isset($context["userCommentMediaBlock"]) || array_key_exists("userCommentMediaBlock", $context) ? $context["userCommentMediaBlock"] : (function () { throw new RuntimeError('Variable "userCommentMediaBlock" does not exist.', 81, $this->source); })()), ""))) {
// line 82
echo " ";
echo (isset($context["userCommentMediaBlock"]) || array_key_exists("userCommentMediaBlock", $context) ? $context["userCommentMediaBlock"] : (function () { throw new RuntimeError('Variable "userCommentMediaBlock" does not exist.', 82, $this->source); })());
echo "
";
} elseif ((0 !== twig_compare( // line 83
(isset($context["offerSupplierPhotoBlock"]) || array_key_exists("offerSupplierPhotoBlock", $context) ? $context["offerSupplierPhotoBlock"] : (function () { throw new RuntimeError('Variable "offerSupplierPhotoBlock" does not exist.', 83, $this->source); })()), ""))) {
// line 84
echo " ";
echo (isset($context["offerSupplierPhotoBlock"]) || array_key_exists("offerSupplierPhotoBlock", $context) ? $context["offerSupplierPhotoBlock"] : (function () { throw new RuntimeError('Variable "offerSupplierPhotoBlock" does not exist.', 84, $this->source); })());
echo "
";
}
// line 86
echo " ";
} else {
// line 87
echo " ";
echo $this->extensions['Slivki\Twig\SlivkiTwigExtension']->getUserCommentsMediaBlockByEntityID($this->env, null, "all");
echo "
";
}
// line 89
echo " ";
}
// line 90
echo " <div class=\"comments-list userVotes message\">
<div><img class=\"ajaxLoader\" src=\"/images/image-preview-ajax-loader.gif\" alt=\"Загрузка...\"></div>
";
// line 92
echo (isset($context["comments"]) || array_key_exists("comments", $context) ? $context["comments"] : (function () { throw new RuntimeError('Variable "comments" does not exist.', 92, $this->source); })());
echo "
</div>
</div>
";
// line 95
if (array_key_exists("offerID", $context)) {
// line 96
echo " <input type=\"hidden\" id=\"stock-id\" value=\"";
echo twig_escape_filter($this->env, (isset($context["offerID"]) || array_key_exists("offerID", $context) ? $context["offerID"] : (function () { throw new RuntimeError('Variable "offerID" does not exist.', 96, $this->source); })()), "html", null, true);
echo "\">
";
// line 97
if ( !$this->extensions['Symfony\Bridge\Twig\Extension\SecurityExtension']->isGranted(twig_constant("Slivki\\Entity\\UserGroup::COMMENTS_BANNED_ROLE_NAME"))) {
// line 98
echo " <span style=\"display: none\" id=\"addVoteLink\" data-oid=\"";
echo twig_escape_filter($this->env, (isset($context["offerID"]) || array_key_exists("offerID", $context) ? $context["offerID"] : (function () { throw new RuntimeError('Variable "offerID" does not exist.', 98, $this->source); })()), "html", null, true);
echo "\" data-type=\"";
echo twig_escape_filter($this->env, twig_constant("Slivki\\Entity\\Comment::TYPE_OFFER_COMMENT"), "html", null, true);
echo "\" data-action=\"comment_add\" data-toggle=\"modal\" data-target=\"";
echo ((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.', 98, $this->source); })()), "user", [], "any", false, false, false, 98)) ? ("#addVoteBox") : ("#onlyRegistered"));
echo "\" >Добавить отзыв</span>
";
}
// line 100
echo " ";
}
// line 101
echo " ";
if (array_key_exists("categoryID", $context)) {
// line 102
echo " <input type=\"hidden\" id=\"category-id\" value=\"";
echo twig_escape_filter($this->env, (isset($context["categoryID"]) || array_key_exists("categoryID", $context) ? $context["categoryID"] : (function () { throw new RuntimeError('Variable "categoryID" does not exist.', 102, $this->source); })()), "html", null, true);
echo "\">
";
// line 103
if ((0 === twig_compare(twig_get_attribute($this->env, $this->source, (isset($context["category"]) || array_key_exists("category", $context) ? $context["category"] : (function () { throw new RuntimeError('Variable "category" does not exist.', 103, $this->source); })()), "getTypeID", [], "any", false, false, false, 103), twig_constant("Slivki\\Entity\\Category::SUPPLIER_CATEGORY_TYPE")))) {
// line 104
echo " ";
$this->loadTemplate("Slivki/pagination.html.twig", "Slivki/comments/comments_live.html.twig", 104)->display(twig_array_merge($context, ["paginationID" => "categoryCommentPagination", "total" => (int) floor(((isset($context["commentsCount"]) || array_key_exists("commentsCount", $context) ? $context["commentsCount"] : (function () { throw new RuntimeError('Variable "commentsCount" does not exist.', 104, $this->source); })()) / 10)), "current" => (isset($context["page"]) || array_key_exists("page", $context) ? $context["page"] : (function () { throw new RuntimeError('Variable "page" does not exist.', 104, $this->source); })()), "url" => (twig_get_attribute($this->env, $this->source, 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.', 104, $this->source); })()), "request", [], "any", false, false, false, 104), "pathInfo", [], "method", false, false, false, 104) . "?page=")]));
// line 105
echo " ";
}
// line 106
echo " ";
}
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 109
public function block_popups($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "popups"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "popups"));
// line 110
echo " ";
$this->displayParentBlock("popups", $context, $blocks);
echo "
";
// line 111
$this->loadTemplate("Slivki/popups/comment_media_block_popup.html.twig", "Slivki/comments/comments_live.html.twig", 111)->display($context);
// line 112
echo " ";
if ( !$this->extensions['Slivki\Twig\SlivkiTwigExtension']->isMobileDevice()) {
// line 113
echo " ";
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.', 113, $this->source); })()), "user", [], "any", false, false, false, 113)) {
// line 114
echo " ";
$this->loadTemplate("Slivki/popups/add_comment_popup.html.twig", "Slivki/comments/comments_live.html.twig", 114)->display(twig_array_merge($context, ["id" => "addVoteBox"]));
// line 115
echo " ";
$this->loadTemplate("Slivki/popups/edit_comment_popup.html.twig", "Slivki/comments/comments_live.html.twig", 115)->display(twig_array_merge($context, ["id" => "editVoteBox"]));
// line 116
echo " ";
} else {
// line 117
echo " ";
$this->loadTemplate("Slivki/popups/comment_only_registered_popup.html.twig", "Slivki/comments/comments_live.html.twig", 117)->display(twig_array_merge($context, ["id" => "onlyRegistered"]));
// line 118
echo " ";
}
// line 119
echo " ";
}
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 122
public function block_javascripts($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "javascripts"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "javascripts"));
// line 123
echo " ";
$this->displayParentBlock("javascripts", $context, $blocks);
echo "
<script src=\"/js/jquery.jcarousel.min.js?v=1\"></script>
<script src=\"/js/swiper-js/swiper.min.js\"></script>
<script type=\"text/javascript\">
\$(document).ready(function(){
uploadPhoto('/comment/image_upload', '/comment/image_remove');
});
";
// line 130
if (array_key_exists("offerID", $context)) {
// line 131
echo " initVoteBox();
initSupplierPhotoSwiper();
";
}
// line 134
echo " </script>
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 136
public function block_assetsBottom($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "assetsBottom"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "assetsBottom"));
// line 137
echo " ";
$this->displayParentBlock("assetsBottom", $context, $blocks);
echo "
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
public function getTemplateName()
{
return "Slivki/comments/comments_live.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 469 => 137, 459 => 136, 448 => 134, 443 => 131, 441 => 130, 430 => 123, 420 => 122, 409 => 119, 406 => 118, 403 => 117, 400 => 116, 397 => 115, 394 => 114, 391 => 113, 388 => 112, 386 => 111, 381 => 110, 371 => 109, 360 => 106, 357 => 105, 354 => 104, 352 => 103, 347 => 102, 344 => 101, 341 => 100, 331 => 98, 329 => 97, 324 => 96, 322 => 95, 316 => 92, 312 => 90, 309 => 89, 303 => 87, 300 => 86, 294 => 84, 292 => 83, 287 => 82, 285 => 81, 279 => 78, 273 => 75, 265 => 69, 262 => 68, 259 => 67, 256 => 66, 253 => 65, 247 => 63, 245 => 62, 241 => 60, 237 => 58, 228 => 55, 224 => 54, 219 => 53, 215 => 52, 212 => 51, 209 => 50, 203 => 48, 201 => 47, 196 => 44, 192 => 42, 186 => 40, 175 => 38, 171 => 37, 166 => 36, 164 => 35, 160 => 34, 156 => 32, 146 => 31, 135 => 28, 132 => 23, 129 => 22, 126 => 14, 123 => 13, 113 => 12, 99 => 9, 89 => 8, 77 => 5, 74 => 4, 64 => 3, 41 => 1,);
}
public function getSourceContext()
{
return new Source("{% extends 'base.html.twig' %}
{% block stylesheets %}
<link rel=\"stylesheet\" href=\"/css/swiper/swiper.min.css\" />
{{ parent() }}
{% endblock %}
{% block mainColumnClass %}
{{ parent() }}
one-column comments-live-content
{% endblock %}
{% block header %}
{% if isMobileDevice() %}
{% embed 'header_mobile.html.twig' %}
{% block menuBlock %}
<li class=\"title\"><span>ОТЗЫВЫ</span></li>
{% for item in topMenu %}
<li><a href=\"{{ item.getURL() }}\">{{ item.getAlias() != null ? item.getAlias() : item.getName() }}</a></li>
{% endfor %}
{% endblock %}
{% endembed %}
{% else %}
{% embed 'header.html.twig' %}
{% block headerTopMenu %}
{% include 'Slivki/header_menu.html.twig' with {'menuSelected': constant('Slivki\\\\Entity\\\\MainMenu::MENU_ID_COMMENT')} %}
{% endblock %}
{% endembed %}
{% endif %}
{% endblock %}
{% block main_content %}
<div id=\"commentsBox\">
<div class=\"breadcrumbs\">
<a href=\"{{ base_url }}\">Главная</a>
{% if category is defined %}
<i class=\"fa fa-angle-right\"></i> <a href=\"{{ path('commentsLive') }}\">Отзывы</a>
{% for parentCategory in parentCategories %}
<i class=\"fa fa-angle-right\"></i> <a href=\"/otzyvy{{ getCategoryURL(parentCategory) }}\">{{ parentCategory.getName() }}</a>
{% endfor %}
<i class=\"fa fa-angle-right\"></i> {{ category.getName() }}
{% else %}
<i class=\"fa fa-angle-right\"></i> Отзывы
{% endif %}
</div>
<div class=\"clear\"></div>
<div class=\"stock-group-header\">
{% if title is defined %}
<div class=\"title\">{{ title|raw }}</div>
{% endif %}
{% if subCategories is defined %}
<div class=\"subcategories-list\">
{% for subCategory in subCategories %}
<a href=\"{{ getURL(constant('Slivki\\\\Repository\\\\SeoRepository::RESOURCE_URL_CATEGORY_COMMENTS'), subCategory.getID()) }}\">
{{ subCategory.getName() }}
<span class=\"green\">({{ subCategory.getEntityCount() }})</span>
</a>
{% endfor %}
</div>
{% endif %}
</div>
<div class=\"clear\"></div>
{% if categoryID is defined %}
{{ getUserCommentsMediaBlockByEntityID(categoryID, 'category') }}
{% else %}
{% if offerID is defined %}
{% set userCommentMediaBlock = getUserCommentsMediaBlockByEntityID(offerID, 'offer') %}
{% set offerSupplierPhotoBlock = getSupplierOfferPhotoBlockByOfferID(offerID) %}
{% if userCommentMediaBlock != '' and offerSupplierPhotoBlock != '' %}
<ul id=\"commentPhotoTabs\" class=\"nav nav-tabs\" role=\"tablist\">
<li class=\"active single-line\"><a href=\"#commentSupplierPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото работ</a></li>
<li class=\"single-line\"><a href=\"#commentUserPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото из отзывов</a></li>
</ul>
<div class=\"tab-content\">
<div class=\"tab-pane fade\" id=\"commentSupplierPhotoTab\">
{{ offerSupplierPhotoBlock|raw }}
</div>
<div class=\"tab-pane fade in active show\" id=\"commentUserPhotoTab\">
{{ userCommentMediaBlock|raw }}
</div>
</div>
{% elseif userCommentMediaBlock != '' %}
{{ userCommentMediaBlock|raw }}
{% elseif offerSupplierPhotoBlock != '' %}
{{ offerSupplierPhotoBlock|raw }}
{% endif %}
{% else %}
{{ getUserCommentsMediaBlockByEntityID(null, 'all') }}
{% endif %}
{% endif %}
<div class=\"comments-list userVotes message\">
<div><img class=\"ajaxLoader\" src=\"/images/image-preview-ajax-loader.gif\" alt=\"Загрузка...\"></div>
{{ comments|raw }}
</div>
</div>
{% if offerID is defined %}
<input type=\"hidden\" id=\"stock-id\" value=\"{{ offerID }}\">
{% if (not is_granted(constant('Slivki\\\\Entity\\\\UserGroup::COMMENTS_BANNED_ROLE_NAME'))) %}
<span style=\"display: none\" id=\"addVoteLink\" data-oid=\"{{ offerID }}\" data-type=\"{{ constant('Slivki\\\\Entity\\\\Comment::TYPE_OFFER_COMMENT') }}\" data-action=\"comment_add\" data-toggle=\"modal\" data-target=\"{{ app.user ? '#addVoteBox' : '#onlyRegistered' }}\" >Добавить отзыв</span>
{% endif %}
{% endif %}
{% if categoryID is defined %}
<input type=\"hidden\" id=\"category-id\" value=\"{{ categoryID }}\">
{% if category.getTypeID == constant('Slivki\\\\Entity\\\\Category::SUPPLIER_CATEGORY_TYPE') %}
{% include 'Slivki/pagination.html.twig' with {'paginationID': 'categoryCommentPagination', 'total': commentsCount//10, 'current': page, 'url': app.request.pathInfo() ~ '?page='} %}
{% endif %}
{% endif %}
{% endblock %}
{% block popups %}
{{ parent() }}
{% include 'Slivki/popups/comment_media_block_popup.html.twig' %}
{% if not isMobileDevice() %}
{% if app.user %}
{% include 'Slivki/popups/add_comment_popup.html.twig' with {'id': 'addVoteBox'} %}
{% include 'Slivki/popups/edit_comment_popup.html.twig' with {'id': 'editVoteBox'} %}
{% else %}
{% include 'Slivki/popups/comment_only_registered_popup.html.twig' with {'id': 'onlyRegistered'} %}
{% endif %}
{% endif %}
{% endblock %}
{% block javascripts %}
{{ parent() }}
<script src=\"/js/jquery.jcarousel.min.js?v=1\"></script>
<script src=\"/js/swiper-js/swiper.min.js\"></script>
<script type=\"text/javascript\">
\$(document).ready(function(){
uploadPhoto('/comment/image_upload', '/comment/image_remove');
});
{% if offerID is defined %}
initVoteBox();
initSupplierPhotoSwiper();
{% endif %}
</script>
{% endblock %}
{% block assetsBottom %}
{{ parent() }}
{% endblock %}", "Slivki/comments/comments_live.html.twig", "/mnt/data/virtwww/dima/templates/Slivki/comments/comments_live.html.twig");
}
}
/* Slivki/comments/comments_live.html.twig */
class __TwigTemplate_c5869eaa945019e1fa57c1e5795ef0fc72c1226bd2e98ff78f08b205520e324d___1885919430 extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'menuBlock' => [$this, 'block_menuBlock'],
];
}
protected function doGetParent(array $context)
{
// line 14
return "header_mobile.html.twig";
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Slivki/comments/comments_live.html.twig"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Slivki/comments/comments_live.html.twig"));
$this->parent = $this->loadTemplate("header_mobile.html.twig", "Slivki/comments/comments_live.html.twig", 14);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
}
// line 15
public function block_menuBlock($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "menuBlock"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "menuBlock"));
// line 16
echo " <li class=\"title\"><span>ОТЗЫВЫ</span></li>
";
// line 17
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["topMenu"]) || array_key_exists("topMenu", $context) ? $context["topMenu"] : (function () { throw new RuntimeError('Variable "topMenu" does not exist.', 17, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
// line 18
echo " <li><a href=\"";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["item"], "getURL", [], "method", false, false, false, 18), "html", null, true);
echo "\">";
echo twig_escape_filter($this->env, (((0 !== twig_compare(twig_get_attribute($this->env, $this->source, $context["item"], "getAlias", [], "method", false, false, false, 18), null))) ? (twig_get_attribute($this->env, $this->source, $context["item"], "getAlias", [], "method", false, false, false, 18)) : (twig_get_attribute($this->env, $this->source, $context["item"], "getName", [], "method", false, false, false, 18))), "html", null, true);
echo "</a></li>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 20
echo " ";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
public function getTemplateName()
{
return "Slivki/comments/comments_live.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 711 => 20, 700 => 18, 696 => 17, 693 => 16, 683 => 15, 660 => 14, 469 => 137, 459 => 136, 448 => 134, 443 => 131, 441 => 130, 430 => 123, 420 => 122, 409 => 119, 406 => 118, 403 => 117, 400 => 116, 397 => 115, 394 => 114, 391 => 113, 388 => 112, 386 => 111, 381 => 110, 371 => 109, 360 => 106, 357 => 105, 354 => 104, 352 => 103, 347 => 102, 344 => 101, 341 => 100, 331 => 98, 329 => 97, 324 => 96, 322 => 95, 316 => 92, 312 => 90, 309 => 89, 303 => 87, 300 => 86, 294 => 84, 292 => 83, 287 => 82, 285 => 81, 279 => 78, 273 => 75, 265 => 69, 262 => 68, 259 => 67, 256 => 66, 253 => 65, 247 => 63, 245 => 62, 241 => 60, 237 => 58, 228 => 55, 224 => 54, 219 => 53, 215 => 52, 212 => 51, 209 => 50, 203 => 48, 201 => 47, 196 => 44, 192 => 42, 186 => 40, 175 => 38, 171 => 37, 166 => 36, 164 => 35, 160 => 34, 156 => 32, 146 => 31, 135 => 28, 132 => 23, 129 => 22, 126 => 14, 123 => 13, 113 => 12, 99 => 9, 89 => 8, 77 => 5, 74 => 4, 64 => 3, 41 => 1,);
}
public function getSourceContext()
{
return new Source("{% extends 'base.html.twig' %}
{% block stylesheets %}
<link rel=\"stylesheet\" href=\"/css/swiper/swiper.min.css\" />
{{ parent() }}
{% endblock %}
{% block mainColumnClass %}
{{ parent() }}
one-column comments-live-content
{% endblock %}
{% block header %}
{% if isMobileDevice() %}
{% embed 'header_mobile.html.twig' %}
{% block menuBlock %}
<li class=\"title\"><span>ОТЗЫВЫ</span></li>
{% for item in topMenu %}
<li><a href=\"{{ item.getURL() }}\">{{ item.getAlias() != null ? item.getAlias() : item.getName() }}</a></li>
{% endfor %}
{% endblock %}
{% endembed %}
{% else %}
{% embed 'header.html.twig' %}
{% block headerTopMenu %}
{% include 'Slivki/header_menu.html.twig' with {'menuSelected': constant('Slivki\\\\Entity\\\\MainMenu::MENU_ID_COMMENT')} %}
{% endblock %}
{% endembed %}
{% endif %}
{% endblock %}
{% block main_content %}
<div id=\"commentsBox\">
<div class=\"breadcrumbs\">
<a href=\"{{ base_url }}\">Главная</a>
{% if category is defined %}
<i class=\"fa fa-angle-right\"></i> <a href=\"{{ path('commentsLive') }}\">Отзывы</a>
{% for parentCategory in parentCategories %}
<i class=\"fa fa-angle-right\"></i> <a href=\"/otzyvy{{ getCategoryURL(parentCategory) }}\">{{ parentCategory.getName() }}</a>
{% endfor %}
<i class=\"fa fa-angle-right\"></i> {{ category.getName() }}
{% else %}
<i class=\"fa fa-angle-right\"></i> Отзывы
{% endif %}
</div>
<div class=\"clear\"></div>
<div class=\"stock-group-header\">
{% if title is defined %}
<div class=\"title\">{{ title|raw }}</div>
{% endif %}
{% if subCategories is defined %}
<div class=\"subcategories-list\">
{% for subCategory in subCategories %}
<a href=\"{{ getURL(constant('Slivki\\\\Repository\\\\SeoRepository::RESOURCE_URL_CATEGORY_COMMENTS'), subCategory.getID()) }}\">
{{ subCategory.getName() }}
<span class=\"green\">({{ subCategory.getEntityCount() }})</span>
</a>
{% endfor %}
</div>
{% endif %}
</div>
<div class=\"clear\"></div>
{% if categoryID is defined %}
{{ getUserCommentsMediaBlockByEntityID(categoryID, 'category') }}
{% else %}
{% if offerID is defined %}
{% set userCommentMediaBlock = getUserCommentsMediaBlockByEntityID(offerID, 'offer') %}
{% set offerSupplierPhotoBlock = getSupplierOfferPhotoBlockByOfferID(offerID) %}
{% if userCommentMediaBlock != '' and offerSupplierPhotoBlock != '' %}
<ul id=\"commentPhotoTabs\" class=\"nav nav-tabs\" role=\"tablist\">
<li class=\"active single-line\"><a href=\"#commentSupplierPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото работ</a></li>
<li class=\"single-line\"><a href=\"#commentUserPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото из отзывов</a></li>
</ul>
<div class=\"tab-content\">
<div class=\"tab-pane fade\" id=\"commentSupplierPhotoTab\">
{{ offerSupplierPhotoBlock|raw }}
</div>
<div class=\"tab-pane fade in active show\" id=\"commentUserPhotoTab\">
{{ userCommentMediaBlock|raw }}
</div>
</div>
{% elseif userCommentMediaBlock != '' %}
{{ userCommentMediaBlock|raw }}
{% elseif offerSupplierPhotoBlock != '' %}
{{ offerSupplierPhotoBlock|raw }}
{% endif %}
{% else %}
{{ getUserCommentsMediaBlockByEntityID(null, 'all') }}
{% endif %}
{% endif %}
<div class=\"comments-list userVotes message\">
<div><img class=\"ajaxLoader\" src=\"/images/image-preview-ajax-loader.gif\" alt=\"Загрузка...\"></div>
{{ comments|raw }}
</div>
</div>
{% if offerID is defined %}
<input type=\"hidden\" id=\"stock-id\" value=\"{{ offerID }}\">
{% if (not is_granted(constant('Slivki\\\\Entity\\\\UserGroup::COMMENTS_BANNED_ROLE_NAME'))) %}
<span style=\"display: none\" id=\"addVoteLink\" data-oid=\"{{ offerID }}\" data-type=\"{{ constant('Slivki\\\\Entity\\\\Comment::TYPE_OFFER_COMMENT') }}\" data-action=\"comment_add\" data-toggle=\"modal\" data-target=\"{{ app.user ? '#addVoteBox' : '#onlyRegistered' }}\" >Добавить отзыв</span>
{% endif %}
{% endif %}
{% if categoryID is defined %}
<input type=\"hidden\" id=\"category-id\" value=\"{{ categoryID }}\">
{% if category.getTypeID == constant('Slivki\\\\Entity\\\\Category::SUPPLIER_CATEGORY_TYPE') %}
{% include 'Slivki/pagination.html.twig' with {'paginationID': 'categoryCommentPagination', 'total': commentsCount//10, 'current': page, 'url': app.request.pathInfo() ~ '?page='} %}
{% endif %}
{% endif %}
{% endblock %}
{% block popups %}
{{ parent() }}
{% include 'Slivki/popups/comment_media_block_popup.html.twig' %}
{% if not isMobileDevice() %}
{% if app.user %}
{% include 'Slivki/popups/add_comment_popup.html.twig' with {'id': 'addVoteBox'} %}
{% include 'Slivki/popups/edit_comment_popup.html.twig' with {'id': 'editVoteBox'} %}
{% else %}
{% include 'Slivki/popups/comment_only_registered_popup.html.twig' with {'id': 'onlyRegistered'} %}
{% endif %}
{% endif %}
{% endblock %}
{% block javascripts %}
{{ parent() }}
<script src=\"/js/jquery.jcarousel.min.js?v=1\"></script>
<script src=\"/js/swiper-js/swiper.min.js\"></script>
<script type=\"text/javascript\">
\$(document).ready(function(){
uploadPhoto('/comment/image_upload', '/comment/image_remove');
});
{% if offerID is defined %}
initVoteBox();
initSupplierPhotoSwiper();
{% endif %}
</script>
{% endblock %}
{% block assetsBottom %}
{{ parent() }}
{% endblock %}", "Slivki/comments/comments_live.html.twig", "/mnt/data/virtwww/dima/templates/Slivki/comments/comments_live.html.twig");
}
}
/* Slivki/comments/comments_live.html.twig */
class __TwigTemplate_c5869eaa945019e1fa57c1e5795ef0fc72c1226bd2e98ff78f08b205520e324d___1702376164 extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'headerTopMenu' => [$this, 'block_headerTopMenu'],
];
}
protected function doGetParent(array $context)
{
// line 23
return "header.html.twig";
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Slivki/comments/comments_live.html.twig"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Slivki/comments/comments_live.html.twig"));
$this->parent = $this->loadTemplate("header.html.twig", "Slivki/comments/comments_live.html.twig", 23);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
}
// line 24
public function block_headerTopMenu($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "headerTopMenu"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "headerTopMenu"));
// line 25
echo " ";
$this->loadTemplate("Slivki/header_menu.html.twig", "Slivki/comments/comments_live.html.twig", 25)->display(twig_array_merge($context, ["menuSelected" => twig_constant("Slivki\\Entity\\MainMenu::MENU_ID_COMMENT")]));
// line 26
echo " ";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
public function getTemplateName()
{
return "Slivki/comments/comments_live.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 935 => 26, 932 => 25, 922 => 24, 899 => 23, 711 => 20, 700 => 18, 696 => 17, 693 => 16, 683 => 15, 660 => 14, 469 => 137, 459 => 136, 448 => 134, 443 => 131, 441 => 130, 430 => 123, 420 => 122, 409 => 119, 406 => 118, 403 => 117, 400 => 116, 397 => 115, 394 => 114, 391 => 113, 388 => 112, 386 => 111, 381 => 110, 371 => 109, 360 => 106, 357 => 105, 354 => 104, 352 => 103, 347 => 102, 344 => 101, 341 => 100, 331 => 98, 329 => 97, 324 => 96, 322 => 95, 316 => 92, 312 => 90, 309 => 89, 303 => 87, 300 => 86, 294 => 84, 292 => 83, 287 => 82, 285 => 81, 279 => 78, 273 => 75, 265 => 69, 262 => 68, 259 => 67, 256 => 66, 253 => 65, 247 => 63, 245 => 62, 241 => 60, 237 => 58, 228 => 55, 224 => 54, 219 => 53, 215 => 52, 212 => 51, 209 => 50, 203 => 48, 201 => 47, 196 => 44, 192 => 42, 186 => 40, 175 => 38, 171 => 37, 166 => 36, 164 => 35, 160 => 34, 156 => 32, 146 => 31, 135 => 28, 132 => 23, 129 => 22, 126 => 14, 123 => 13, 113 => 12, 99 => 9, 89 => 8, 77 => 5, 74 => 4, 64 => 3, 41 => 1,);
}
public function getSourceContext()
{
return new Source("{% extends 'base.html.twig' %}
{% block stylesheets %}
<link rel=\"stylesheet\" href=\"/css/swiper/swiper.min.css\" />
{{ parent() }}
{% endblock %}
{% block mainColumnClass %}
{{ parent() }}
one-column comments-live-content
{% endblock %}
{% block header %}
{% if isMobileDevice() %}
{% embed 'header_mobile.html.twig' %}
{% block menuBlock %}
<li class=\"title\"><span>ОТЗЫВЫ</span></li>
{% for item in topMenu %}
<li><a href=\"{{ item.getURL() }}\">{{ item.getAlias() != null ? item.getAlias() : item.getName() }}</a></li>
{% endfor %}
{% endblock %}
{% endembed %}
{% else %}
{% embed 'header.html.twig' %}
{% block headerTopMenu %}
{% include 'Slivki/header_menu.html.twig' with {'menuSelected': constant('Slivki\\\\Entity\\\\MainMenu::MENU_ID_COMMENT')} %}
{% endblock %}
{% endembed %}
{% endif %}
{% endblock %}
{% block main_content %}
<div id=\"commentsBox\">
<div class=\"breadcrumbs\">
<a href=\"{{ base_url }}\">Главная</a>
{% if category is defined %}
<i class=\"fa fa-angle-right\"></i> <a href=\"{{ path('commentsLive') }}\">Отзывы</a>
{% for parentCategory in parentCategories %}
<i class=\"fa fa-angle-right\"></i> <a href=\"/otzyvy{{ getCategoryURL(parentCategory) }}\">{{ parentCategory.getName() }}</a>
{% endfor %}
<i class=\"fa fa-angle-right\"></i> {{ category.getName() }}
{% else %}
<i class=\"fa fa-angle-right\"></i> Отзывы
{% endif %}
</div>
<div class=\"clear\"></div>
<div class=\"stock-group-header\">
{% if title is defined %}
<div class=\"title\">{{ title|raw }}</div>
{% endif %}
{% if subCategories is defined %}
<div class=\"subcategories-list\">
{% for subCategory in subCategories %}
<a href=\"{{ getURL(constant('Slivki\\\\Repository\\\\SeoRepository::RESOURCE_URL_CATEGORY_COMMENTS'), subCategory.getID()) }}\">
{{ subCategory.getName() }}
<span class=\"green\">({{ subCategory.getEntityCount() }})</span>
</a>
{% endfor %}
</div>
{% endif %}
</div>
<div class=\"clear\"></div>
{% if categoryID is defined %}
{{ getUserCommentsMediaBlockByEntityID(categoryID, 'category') }}
{% else %}
{% if offerID is defined %}
{% set userCommentMediaBlock = getUserCommentsMediaBlockByEntityID(offerID, 'offer') %}
{% set offerSupplierPhotoBlock = getSupplierOfferPhotoBlockByOfferID(offerID) %}
{% if userCommentMediaBlock != '' and offerSupplierPhotoBlock != '' %}
<ul id=\"commentPhotoTabs\" class=\"nav nav-tabs\" role=\"tablist\">
<li class=\"active single-line\"><a href=\"#commentSupplierPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото работ</a></li>
<li class=\"single-line\"><a href=\"#commentUserPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото из отзывов</a></li>
</ul>
<div class=\"tab-content\">
<div class=\"tab-pane fade\" id=\"commentSupplierPhotoTab\">
{{ offerSupplierPhotoBlock|raw }}
</div>
<div class=\"tab-pane fade in active show\" id=\"commentUserPhotoTab\">
{{ userCommentMediaBlock|raw }}
</div>
</div>
{% elseif userCommentMediaBlock != '' %}
{{ userCommentMediaBlock|raw }}
{% elseif offerSupplierPhotoBlock != '' %}
{{ offerSupplierPhotoBlock|raw }}
{% endif %}
{% else %}
{{ getUserCommentsMediaBlockByEntityID(null, 'all') }}
{% endif %}
{% endif %}
<div class=\"comments-list userVotes message\">
<div><img class=\"ajaxLoader\" src=\"/images/image-preview-ajax-loader.gif\" alt=\"Загрузка...\"></div>
{{ comments|raw }}
</div>
</div>
{% if offerID is defined %}
<input type=\"hidden\" id=\"stock-id\" value=\"{{ offerID }}\">
{% if (not is_granted(constant('Slivki\\\\Entity\\\\UserGroup::COMMENTS_BANNED_ROLE_NAME'))) %}
<span style=\"display: none\" id=\"addVoteLink\" data-oid=\"{{ offerID }}\" data-type=\"{{ constant('Slivki\\\\Entity\\\\Comment::TYPE_OFFER_COMMENT') }}\" data-action=\"comment_add\" data-toggle=\"modal\" data-target=\"{{ app.user ? '#addVoteBox' : '#onlyRegistered' }}\" >Добавить отзыв</span>
{% endif %}
{% endif %}
{% if categoryID is defined %}
<input type=\"hidden\" id=\"category-id\" value=\"{{ categoryID }}\">
{% if category.getTypeID == constant('Slivki\\\\Entity\\\\Category::SUPPLIER_CATEGORY_TYPE') %}
{% include 'Slivki/pagination.html.twig' with {'paginationID': 'categoryCommentPagination', 'total': commentsCount//10, 'current': page, 'url': app.request.pathInfo() ~ '?page='} %}
{% endif %}
{% endif %}
{% endblock %}
{% block popups %}
{{ parent() }}
{% include 'Slivki/popups/comment_media_block_popup.html.twig' %}
{% if not isMobileDevice() %}
{% if app.user %}
{% include 'Slivki/popups/add_comment_popup.html.twig' with {'id': 'addVoteBox'} %}
{% include 'Slivki/popups/edit_comment_popup.html.twig' with {'id': 'editVoteBox'} %}
{% else %}
{% include 'Slivki/popups/comment_only_registered_popup.html.twig' with {'id': 'onlyRegistered'} %}
{% endif %}
{% endif %}
{% endblock %}
{% block javascripts %}
{{ parent() }}
<script src=\"/js/jquery.jcarousel.min.js?v=1\"></script>
<script src=\"/js/swiper-js/swiper.min.js\"></script>
<script type=\"text/javascript\">
\$(document).ready(function(){
uploadPhoto('/comment/image_upload', '/comment/image_remove');
});
{% if offerID is defined %}
initVoteBox();
initSupplierPhotoSwiper();
{% endif %}
</script>
{% endblock %}
{% block assetsBottom %}
{{ parent() }}
{% endblock %}", "Slivki/comments/comments_live.html.twig", "/mnt/data/virtwww/dima/templates/Slivki/comments/comments_live.html.twig");
}
}