var/cache/dev/twig/5f/5f65a95c0dce8ea90755745718f6fd7947916eb3a3176337ba0c8349e560d4ac.php line 54

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. /* Slivki/comments/comments_live.html.twig */
  14. class __TwigTemplate_c5869eaa945019e1fa57c1e5795ef0fc72c1226bd2e98ff78f08b205520e324d extends Template
  15. {
  16.     private $source;
  17.     private $macros = [];
  18.     public function __construct(Environment $env)
  19.     {
  20.         parent::__construct($env);
  21.         $this->source $this->getSourceContext();
  22.         $this->blocks = [
  23.             'stylesheets' => [$this'block_stylesheets'],
  24.             'mainColumnClass' => [$this'block_mainColumnClass'],
  25.             'header' => [$this'block_header'],
  26.             'main_content' => [$this'block_main_content'],
  27.             'popups' => [$this'block_popups'],
  28.             'javascripts' => [$this'block_javascripts'],
  29.             'assetsBottom' => [$this'block_assetsBottom'],
  30.         ];
  31.     }
  32.     protected function doGetParent(array $context)
  33.     {
  34.         // line 1
  35.         return "base.html.twig";
  36.     }
  37.     protected function doDisplay(array $context, array $blocks = [])
  38.     {
  39.         $macros $this->macros;
  40.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  41.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""Slivki/comments/comments_live.html.twig"));
  42.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  43.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""Slivki/comments/comments_live.html.twig"));
  44.         $this->parent $this->loadTemplate("base.html.twig""Slivki/comments/comments_live.html.twig"1);
  45.         $this->parent->display($contextarray_merge($this->blocks$blocks));
  46.         
  47.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  48.         
  49.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  50.     }
  51.     // line 3
  52.     public function block_stylesheets($context, array $blocks = [])
  53.     {
  54.         $macros $this->macros;
  55.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  56.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""stylesheets"));
  57.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  58.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""stylesheets"));
  59.         // line 4
  60.         echo "    <link rel=\"stylesheet\" href=\"/css/swiper/swiper.min.css\" />
  61.     ";
  62.         // line 5
  63.         $this->displayParentBlock("stylesheets"$context$blocks);
  64.         echo "
  65. ";
  66.         
  67.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  68.         
  69.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  70.     }
  71.     // line 8
  72.     public function block_mainColumnClass($context, array $blocks = [])
  73.     {
  74.         $macros $this->macros;
  75.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  76.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""mainColumnClass"));
  77.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  78.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""mainColumnClass"));
  79.         // line 9
  80.         echo "    ";
  81.         $this->displayParentBlock("mainColumnClass"$context$blocks);
  82.         echo "
  83.     one-column comments-live-content
  84. ";
  85.         
  86.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  87.         
  88.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  89.     }
  90.     // line 12
  91.     public function block_header($context, array $blocks = [])
  92.     {
  93.         $macros $this->macros;
  94.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  95.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""header"));
  96.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  97.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""header"));
  98.         // line 13
  99.         echo "    ";
  100.         if ($this->extensions['Slivki\Twig\SlivkiTwigExtension']->isMobileDevice()) {
  101.             // line 14
  102.             echo "        ";
  103.             $this->loadTemplate("Slivki/comments/comments_live.html.twig""Slivki/comments/comments_live.html.twig"14"962409009")->display($context);
  104.             // line 22
  105.             echo "    ";
  106.         } else {
  107.             // line 23
  108.             echo "        ";
  109.             $this->loadTemplate("Slivki/comments/comments_live.html.twig""Slivki/comments/comments_live.html.twig"23"513150748")->display($context);
  110.             // line 28
  111.             echo "    ";
  112.         }
  113.         
  114.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  115.         
  116.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  117.     }
  118.     // line 31
  119.     public function block_main_content($context, array $blocks = [])
  120.     {
  121.         $macros $this->macros;
  122.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  123.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""main_content"));
  124.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  125.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""main_content"));
  126.         // line 32
  127.         echo "    <div id=\"commentsBox\">
  128.         <div class=\"breadcrumbs\">
  129.             <a href=\"";
  130.         // line 34
  131.         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"nulltrue);
  132.         echo "\">Главная</a>
  133.             ";
  134.         // line 35
  135.         if (array_key_exists("category"$context)) {
  136.             // line 36
  137.             echo "                <i class=\"fa fa-angle-right\"></i>&nbsp; <a href=\"";
  138.             echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("commentsLive");
  139.             echo "\">Отзывы</a>
  140.                 ";
  141.             // line 37
  142.             $context['_parent'] = $context;
  143.             $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); })()));
  144.             foreach ($context['_seq'] as $context["_key"] => $context["parentCategory"]) {
  145.                 // line 38
  146.                 echo "                    <i class=\"fa fa-angle-right\"></i>&nbsp;<a href=\"/otzyvy";
  147.                 echo twig_escape_filter($this->env$this->extensions['Slivki\Twig\SlivkiTwigExtension']->getCategoryURL($context["parentCategory"]), "html"nulltrue);
  148.                 echo "\">";
  149.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["parentCategory"], "getName", [], "method"falsefalsefalse38), "html"nulltrue);
  150.                 echo "</a>
  151.                 ";
  152.             }
  153.             $_parent $context['_parent'];
  154.             unset($context['_seq'], $context['_iterated'], $context['_key'], $context['parentCategory'], $context['_parent'], $context['loop']);
  155.             $context array_intersect_key($context$_parent) + $_parent;
  156.             // line 40
  157.             echo "                <i class=\"fa fa-angle-right\"></i>&nbsp;";
  158.             echo twig_escape_filter($this->envtwig_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"falsefalsefalse40), "html"nulltrue);
  159.             echo "
  160.             ";
  161.         } else {
  162.             // line 42
  163.             echo "                <i class=\"fa fa-angle-right\"></i>&nbsp;Отзывы
  164.             ";
  165.         }
  166.         // line 44
  167.         echo "        </div>
  168.         <div class=\"clear\"></div>
  169.         <div class=\"stock-group-header\">
  170.             ";
  171.         // line 47
  172.         if (array_key_exists("title"$context)) {
  173.             // line 48
  174.             echo "                <div class=\"title\">";
  175.             echo (isset($context["title"]) || array_key_exists("title"$context) ? $context["title"] : (function () { throw new RuntimeError('Variable "title" does not exist.'48$this->source); })());
  176.             echo "</div>
  177.             ";
  178.         }
  179.         // line 50
  180.         echo "            ";
  181.         if (array_key_exists("subCategories"$context)) {
  182.             // line 51
  183.             echo "                <div class=\"subcategories-list\">
  184.                     ";
  185.             // line 52
  186.             $context['_parent'] = $context;
  187.             $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); })()));
  188.             foreach ($context['_seq'] as $context["_key"] => $context["subCategory"]) {
  189.                 // line 53
  190.                 echo "                        <a href=\"";
  191.                 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"falsefalsefalse53)), "html"nulltrue);
  192.                 echo "\">
  193.                             ";
  194.                 // line 54
  195.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["subCategory"], "getName", [], "method"falsefalsefalse54), "html"nulltrue);
  196.                 echo "
  197.                             <span class=\"green\">(";
  198.                 // line 55
  199.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["subCategory"], "getEntityCount", [], "method"falsefalsefalse55), "html"nulltrue);
  200.                 echo ")</span>
  201.                         </a>
  202.                     ";
  203.             }
  204.             $_parent $context['_parent'];
  205.             unset($context['_seq'], $context['_iterated'], $context['_key'], $context['subCategory'], $context['_parent'], $context['loop']);
  206.             $context array_intersect_key($context$_parent) + $_parent;
  207.             // line 58
  208.             echo "                </div>
  209.             ";
  210.         }
  211.         // line 60
  212.         echo "        </div>
  213.         <div class=\"clear\"></div>
  214.         ";
  215.         // line 62
  216.         if (array_key_exists("categoryID"$context)) {
  217.             // line 63
  218.             echo "            ";
  219.             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");
  220.             echo "
  221.         ";
  222.         } else {
  223.             // line 65
  224.             echo "            ";
  225.             if (array_key_exists("offerID"$context)) {
  226.                 // line 66
  227.                 echo "                ";
  228.                 $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");
  229.                 // line 67
  230.                 echo "                ";
  231.                 $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); })()));
  232.                 // line 68
  233.                 echo "                ";
  234.                 if (((!== twig_compare((isset($context["userCommentMediaBlock"]) || array_key_exists("userCommentMediaBlock"$context) ? $context["userCommentMediaBlock"] : (function () { throw new RuntimeError('Variable "userCommentMediaBlock" does not exist.'68$this->source); })()), "")) && (!== twig_compare((isset($context["offerSupplierPhotoBlock"]) || array_key_exists("offerSupplierPhotoBlock"$context) ? $context["offerSupplierPhotoBlock"] : (function () { throw new RuntimeError('Variable "offerSupplierPhotoBlock" does not exist.'68$this->source); })()), "")))) {
  235.                     // line 69
  236.                     echo "                    <ul id=\"commentPhotoTabs\" class=\"nav nav-tabs\" role=\"tablist\">
  237.                         <li class=\"active single-line\"><a href=\"#commentSupplierPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото работ</a></li>
  238.                         <li class=\"single-line\"><a href=\"#commentUserPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото из отзывов</a></li>
  239.                     </ul>
  240.                     <div class=\"tab-content\">
  241.                         <div class=\"tab-pane fade in active\" id=\"commentSupplierPhotoTab\">
  242.                             ";
  243.                     // line 75
  244.                     echo (isset($context["offerSupplierPhotoBlock"]) || array_key_exists("offerSupplierPhotoBlock"$context) ? $context["offerSupplierPhotoBlock"] : (function () { throw new RuntimeError('Variable "offerSupplierPhotoBlock" does not exist.'75$this->source); })());
  245.                     echo "
  246.                         </div>
  247.                         <div class=\"tab-pane fade\" id=\"commentUserPhotoTab\">
  248.                             ";
  249.                     // line 78
  250.                     echo (isset($context["userCommentMediaBlock"]) || array_key_exists("userCommentMediaBlock"$context) ? $context["userCommentMediaBlock"] : (function () { throw new RuntimeError('Variable "userCommentMediaBlock" does not exist.'78$this->source); })());
  251.                     echo "
  252.                         </div>
  253.                     </div>
  254.                 ";
  255.                 } elseif ((!== twig_compare(                // line 81
  256. (isset($context["userCommentMediaBlock"]) || array_key_exists("userCommentMediaBlock"$context) ? $context["userCommentMediaBlock"] : (function () { throw new RuntimeError('Variable "userCommentMediaBlock" does not exist.'81$this->source); })()), ""))) {
  257.                     // line 82
  258.                     echo "                    ";
  259.                     echo (isset($context["userCommentMediaBlock"]) || array_key_exists("userCommentMediaBlock"$context) ? $context["userCommentMediaBlock"] : (function () { throw new RuntimeError('Variable "userCommentMediaBlock" does not exist.'82$this->source); })());
  260.                     echo "
  261.                 ";
  262.                 } elseif ((!== twig_compare(                // line 83
  263. (isset($context["offerSupplierPhotoBlock"]) || array_key_exists("offerSupplierPhotoBlock"$context) ? $context["offerSupplierPhotoBlock"] : (function () { throw new RuntimeError('Variable "offerSupplierPhotoBlock" does not exist.'83$this->source); })()), ""))) {
  264.                     // line 84
  265.                     echo "                    ";
  266.                     echo (isset($context["offerSupplierPhotoBlock"]) || array_key_exists("offerSupplierPhotoBlock"$context) ? $context["offerSupplierPhotoBlock"] : (function () { throw new RuntimeError('Variable "offerSupplierPhotoBlock" does not exist.'84$this->source); })());
  267.                     echo "
  268.                 ";
  269.                 }
  270.                 // line 86
  271.                 echo "            ";
  272.             } else {
  273.                 // line 87
  274.                 echo "                ";
  275.                 echo $this->extensions['Slivki\Twig\SlivkiTwigExtension']->getUserCommentsMediaBlockByEntityID($this->envnull"all");
  276.                 echo "
  277.             ";
  278.             }
  279.             // line 89
  280.             echo "        ";
  281.         }
  282.         // line 90
  283.         echo "        <div class=\"comments-list userVotes message\">
  284.             <div><img class=\"ajaxLoader\" src=\"/images/image-preview-ajax-loader.gif\" alt=\"Загрузка...\"></div>
  285.             ";
  286.         // line 92
  287.         echo (isset($context["comments"]) || array_key_exists("comments"$context) ? $context["comments"] : (function () { throw new RuntimeError('Variable "comments" does not exist.'92$this->source); })());
  288.         echo "
  289.         </div>
  290.     </div>
  291.     ";
  292.         // line 95
  293.         if (array_key_exists("offerID"$context)) {
  294.             // line 96
  295.             echo "        <input type=\"hidden\" id=\"stock-id\" value=\"";
  296.             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"nulltrue);
  297.             echo "\">
  298.         ";
  299.             // line 97
  300.             if ( !$this->extensions['Symfony\Bridge\Twig\Extension\SecurityExtension']->isGranted(twig_constant("Slivki\\Entity\\UserGroup::COMMENTS_BANNED_ROLE_NAME"))) {
  301.                 // line 98
  302.                 echo "            <span style=\"display: none\" id=\"addVoteLink\" data-oid=\"";
  303.                 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"nulltrue);
  304.                 echo "\" data-type=\"";
  305.                 echo twig_escape_filter($this->envtwig_constant("Slivki\\Entity\\Comment::TYPE_OFFER_COMMENT"), "html"nulltrue);
  306.                 echo "\" data-action=\"comment_add\" data-toggle=\"modal\" data-target=\"";
  307.                 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"falsefalsefalse98)) ? ("#addVoteBox") : ("#onlyRegistered"));
  308.                 echo "\" >Добавить отзыв</span>
  309.         ";
  310.             }
  311.             // line 100
  312.             echo "    ";
  313.         }
  314.         // line 101
  315.         echo "    ";
  316.         if (array_key_exists("categoryID"$context)) {
  317.             // line 102
  318.             echo "        <input type=\"hidden\" id=\"category-id\" value=\"";
  319.             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"nulltrue);
  320.             echo "\">
  321.         ";
  322.             // line 103
  323.             if ((=== 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"falsefalsefalse103), twig_constant("Slivki\\Entity\\Category::SUPPLIER_CATEGORY_TYPE")))) {
  324.                 // line 104
  325.                 echo "            ";
  326.                 $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->sourcetwig_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"falsefalsefalse104), "pathInfo", [], "method"falsefalsefalse104) . "?page=")]));
  327.                 // line 105
  328.                 echo "        ";
  329.             }
  330.             // line 106
  331.             echo "    ";
  332.         }
  333.         
  334.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  335.         
  336.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  337.     }
  338.     // line 109
  339.     public function block_popups($context, array $blocks = [])
  340.     {
  341.         $macros $this->macros;
  342.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  343.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""popups"));
  344.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  345.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""popups"));
  346.         // line 110
  347.         echo "    ";
  348.         $this->displayParentBlock("popups"$context$blocks);
  349.         echo "
  350.     ";
  351.         // line 111
  352.         $this->loadTemplate("Slivki/popups/comment_media_block_popup.html.twig""Slivki/comments/comments_live.html.twig"111)->display($context);
  353.         // line 112
  354.         echo "    ";
  355.         if ( !$this->extensions['Slivki\Twig\SlivkiTwigExtension']->isMobileDevice()) {
  356.             // line 113
  357.             echo "        ";
  358.             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"falsefalsefalse113)) {
  359.                 // line 114
  360.                 echo "            ";
  361.                 $this->loadTemplate("Slivki/popups/add_comment_popup.html.twig""Slivki/comments/comments_live.html.twig"114)->display(twig_array_merge($context, ["id" => "addVoteBox"]));
  362.                 // line 115
  363.                 echo "            ";
  364.                 $this->loadTemplate("Slivki/popups/edit_comment_popup.html.twig""Slivki/comments/comments_live.html.twig"115)->display(twig_array_merge($context, ["id" => "editVoteBox"]));
  365.                 // line 116
  366.                 echo "        ";
  367.             } else {
  368.                 // line 117
  369.                 echo "            ";
  370.                 $this->loadTemplate("Slivki/popups/comment_only_registered_popup.html.twig""Slivki/comments/comments_live.html.twig"117)->display(twig_array_merge($context, ["id" => "onlyRegistered"]));
  371.                 // line 118
  372.                 echo "        ";
  373.             }
  374.             // line 119
  375.             echo "    ";
  376.         }
  377.         
  378.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  379.         
  380.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  381.     }
  382.     // line 122
  383.     public function block_javascripts($context, array $blocks = [])
  384.     {
  385.         $macros $this->macros;
  386.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  387.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""javascripts"));
  388.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  389.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""javascripts"));
  390.         // line 123
  391.         echo "    ";
  392.         $this->displayParentBlock("javascripts"$context$blocks);
  393.         echo "
  394.     <script src=\"/js/swiper-js/swiper.min.js\"></script>
  395.     <script type=\"text/javascript\">
  396.         \$(document).ready(function(){
  397.             uploadPhoto('/comment/image_upload', '/comment/image_remove');
  398.         });
  399.         ";
  400.         // line 129
  401.         if (array_key_exists("offerID"$context)) {
  402.             // line 130
  403.             echo "            initVoteBox();
  404.             initSupplierPhotoSwiper();
  405.         ";
  406.         }
  407.         // line 133
  408.         echo "    </script>
  409. ";
  410.         
  411.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  412.         
  413.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  414.     }
  415.     // line 135
  416.     public function block_assetsBottom($context, array $blocks = [])
  417.     {
  418.         $macros $this->macros;
  419.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  420.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""assetsBottom"));
  421.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  422.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""assetsBottom"));
  423.         // line 136
  424.         echo "    ";
  425.         $this->displayParentBlock("assetsBottom"$context$blocks);
  426.         echo "
  427. ";
  428.         
  429.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  430.         
  431.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  432.     }
  433.     public function getTemplateName()
  434.     {
  435.         return "Slivki/comments/comments_live.html.twig";
  436.     }
  437.     public function isTraitable()
  438.     {
  439.         return false;
  440.     }
  441.     public function getDebugInfo()
  442.     {
  443.         return array (  468 => 136,  458 => 135,  447 => 133,  442 => 130,  440 => 129,  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,);
  444.     }
  445.     public function getSourceContext()
  446.     {
  447.         return new Source("{% extends 'base.html.twig' %}
  448. {% block stylesheets %}
  449.     <link rel=\"stylesheet\" href=\"/css/swiper/swiper.min.css\" />
  450.     {{ parent() }}
  451. {% endblock %}
  452. {% block mainColumnClass %}
  453.     {{ parent() }}
  454.     one-column comments-live-content
  455. {% endblock %}
  456. {% block header %}
  457.     {% if isMobileDevice() %}
  458.         {% embed 'header_mobile.html.twig' %}
  459.             {% block menuBlock %}
  460.                 <li class=\"title\"><span>ОТЗЫВЫ</span></li>
  461.                 {% for item in topMenu %}
  462.                     <li><a href=\"{{ item.getURL() }}\">{{ item.getAlias() != null ? item.getAlias() : item.getName() }}</a></li>
  463.                 {% endfor %}
  464.             {% endblock %}
  465.         {% endembed %}
  466.     {% else %}
  467.         {% embed 'header.html.twig' %}
  468.             {% block headerTopMenu %}
  469.                 {% include 'Slivki/header_menu.html.twig' with {'menuSelected': constant('Slivki\\\\Entity\\\\MainMenu::MENU_ID_COMMENT')} %}
  470.             {% endblock %}
  471.         {% endembed %}
  472.     {% endif %}
  473. {% endblock %}
  474. {% block main_content %}
  475.     <div id=\"commentsBox\">
  476.         <div class=\"breadcrumbs\">
  477.             <a href=\"{{ base_url }}\">Главная</a>
  478.             {% if category is defined  %}
  479.                 <i class=\"fa fa-angle-right\"></i>&nbsp; <a href=\"{{ path('commentsLive') }}\">Отзывы</a>
  480.                 {% for parentCategory in parentCategories %}
  481.                     <i class=\"fa fa-angle-right\"></i>&nbsp;<a href=\"/otzyvy{{ getCategoryURL(parentCategory) }}\">{{ parentCategory.getName() }}</a>
  482.                 {% endfor %}
  483.                 <i class=\"fa fa-angle-right\"></i>&nbsp;{{ category.getName() }}
  484.             {% else %}
  485.                 <i class=\"fa fa-angle-right\"></i>&nbsp;Отзывы
  486.             {% endif %}
  487.         </div>
  488.         <div class=\"clear\"></div>
  489.         <div class=\"stock-group-header\">
  490.             {% if title is defined %}
  491.                 <div class=\"title\">{{ title|raw }}</div>
  492.             {% endif %}
  493.             {% if subCategories is defined %}
  494.                 <div class=\"subcategories-list\">
  495.                     {% for subCategory in subCategories %}
  496.                         <a href=\"{{ getURL(constant('Slivki\\\\Repository\\\\SeoRepository::RESOURCE_URL_CATEGORY_COMMENTS'), subCategory.getID()) }}\">
  497.                             {{ subCategory.getName() }}
  498.                             <span class=\"green\">({{ subCategory.getEntityCount() }})</span>
  499.                         </a>
  500.                     {% endfor %}
  501.                 </div>
  502.             {% endif %}
  503.         </div>
  504.         <div class=\"clear\"></div>
  505.         {% if categoryID is defined %}
  506.             {{ getUserCommentsMediaBlockByEntityID(categoryID, 'category') }}
  507.         {% else %}
  508.             {% if offerID is defined %}
  509.                 {% set userCommentMediaBlock = getUserCommentsMediaBlockByEntityID(offerID, 'offer') %}
  510.                 {% set offerSupplierPhotoBlock = getSupplierOfferPhotoBlockByOfferID(offerID) %}
  511.                 {% if userCommentMediaBlock != '' and offerSupplierPhotoBlock != '' %}
  512.                     <ul id=\"commentPhotoTabs\" class=\"nav nav-tabs\" role=\"tablist\">
  513.                         <li class=\"active single-line\"><a href=\"#commentSupplierPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото работ</a></li>
  514.                         <li class=\"single-line\"><a href=\"#commentUserPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото из отзывов</a></li>
  515.                     </ul>
  516.                     <div class=\"tab-content\">
  517.                         <div class=\"tab-pane fade in active\" id=\"commentSupplierPhotoTab\">
  518.                             {{ offerSupplierPhotoBlock|raw }}
  519.                         </div>
  520.                         <div class=\"tab-pane fade\" id=\"commentUserPhotoTab\">
  521.                             {{ userCommentMediaBlock|raw }}
  522.                         </div>
  523.                     </div>
  524.                 {% elseif userCommentMediaBlock != '' %}
  525.                     {{ userCommentMediaBlock|raw }}
  526.                 {% elseif offerSupplierPhotoBlock != '' %}
  527.                     {{ offerSupplierPhotoBlock|raw }}
  528.                 {% endif %}
  529.             {% else %}
  530.                 {{ getUserCommentsMediaBlockByEntityID(null, 'all') }}
  531.             {% endif %}
  532.         {% endif %}
  533.         <div class=\"comments-list userVotes message\">
  534.             <div><img class=\"ajaxLoader\" src=\"/images/image-preview-ajax-loader.gif\" alt=\"Загрузка...\"></div>
  535.             {{ comments|raw }}
  536.         </div>
  537.     </div>
  538.     {% if offerID is defined %}
  539.         <input type=\"hidden\" id=\"stock-id\" value=\"{{ offerID }}\">
  540.         {% if (not is_granted(constant('Slivki\\\\Entity\\\\UserGroup::COMMENTS_BANNED_ROLE_NAME'))) %}
  541.             <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>
  542.         {% endif %}
  543.     {% endif %}
  544.     {% if categoryID is defined %}
  545.         <input type=\"hidden\" id=\"category-id\" value=\"{{ categoryID }}\">
  546.         {% if category.getTypeID ==  constant('Slivki\\\\Entity\\\\Category::SUPPLIER_CATEGORY_TYPE') %}
  547.             {% include 'Slivki/pagination.html.twig' with {'paginationID': 'categoryCommentPagination', 'total': commentsCount//10, 'current': page, 'url': app.request.pathInfo() ~ '?page='} %}
  548.         {% endif %}
  549.     {% endif %}
  550. {% endblock %}
  551. {% block popups %}
  552.     {{ parent() }}
  553.     {% include 'Slivki/popups/comment_media_block_popup.html.twig' %}
  554.     {% if not isMobileDevice() %}
  555.         {% if app.user %}
  556.             {% include 'Slivki/popups/add_comment_popup.html.twig' with {'id': 'addVoteBox'} %}
  557.             {% include 'Slivki/popups/edit_comment_popup.html.twig' with {'id': 'editVoteBox'} %}
  558.         {% else %}
  559.             {% include 'Slivki/popups/comment_only_registered_popup.html.twig' with {'id': 'onlyRegistered'} %}
  560.         {% endif %}
  561.     {% endif %}
  562. {% endblock %}
  563. {% block javascripts %}
  564.     {{ parent() }}
  565.     <script src=\"/js/swiper-js/swiper.min.js\"></script>
  566.     <script type=\"text/javascript\">
  567.         \$(document).ready(function(){
  568.             uploadPhoto('/comment/image_upload', '/comment/image_remove');
  569.         });
  570.         {% if offerID is defined %}
  571.             initVoteBox();
  572.             initSupplierPhotoSwiper();
  573.         {% endif %}
  574.     </script>
  575. {% endblock %}
  576. {% block assetsBottom %}
  577.     {{ parent() }}
  578. {% endblock %}""Slivki/comments/comments_live.html.twig""/mnt/data/virtwww/vlad-slivki/templates/Slivki/comments/comments_live.html.twig");
  579.     }
  580. }
  581. /* Slivki/comments/comments_live.html.twig */
  582. class __TwigTemplate_c5869eaa945019e1fa57c1e5795ef0fc72c1226bd2e98ff78f08b205520e324d___962409009 extends Template
  583. {
  584.     private $source;
  585.     private $macros = [];
  586.     public function __construct(Environment $env)
  587.     {
  588.         parent::__construct($env);
  589.         $this->source $this->getSourceContext();
  590.         $this->blocks = [
  591.             'menuBlock' => [$this'block_menuBlock'],
  592.         ];
  593.     }
  594.     protected function doGetParent(array $context)
  595.     {
  596.         // line 14
  597.         return "header_mobile.html.twig";
  598.     }
  599.     protected function doDisplay(array $context, array $blocks = [])
  600.     {
  601.         $macros $this->macros;
  602.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  603.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""Slivki/comments/comments_live.html.twig"));
  604.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  605.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""Slivki/comments/comments_live.html.twig"));
  606.         $this->parent $this->loadTemplate("header_mobile.html.twig""Slivki/comments/comments_live.html.twig"14);
  607.         $this->parent->display($contextarray_merge($this->blocks$blocks));
  608.         
  609.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  610.         
  611.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  612.     }
  613.     // line 15
  614.     public function block_menuBlock($context, array $blocks = [])
  615.     {
  616.         $macros $this->macros;
  617.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  618.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""menuBlock"));
  619.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  620.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""menuBlock"));
  621.         // line 16
  622.         echo "                <li class=\"title\"><span>ОТЗЫВЫ</span></li>
  623.                 ";
  624.         // line 17
  625.         $context['_parent'] = $context;
  626.         $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); })()));
  627.         foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
  628.             // line 18
  629.             echo "                    <li><a href=\"";
  630.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["item"], "getURL", [], "method"falsefalsefalse18), "html"nulltrue);
  631.             echo "\">";
  632.             echo twig_escape_filter($this->env, (((!== twig_compare(twig_get_attribute($this->env$this->source$context["item"], "getAlias", [], "method"falsefalsefalse18), null))) ? (twig_get_attribute($this->env$this->source$context["item"], "getAlias", [], "method"falsefalsefalse18)) : (twig_get_attribute($this->env$this->source$context["item"], "getName", [], "method"falsefalsefalse18))), "html"nulltrue);
  633.             echo "</a></li>
  634.                 ";
  635.         }
  636.         $_parent $context['_parent'];
  637.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
  638.         $context array_intersect_key($context$_parent) + $_parent;
  639.         // line 20
  640.         echo "            ";
  641.         
  642.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  643.         
  644.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  645.     }
  646.     public function getTemplateName()
  647.     {
  648.         return "Slivki/comments/comments_live.html.twig";
  649.     }
  650.     public function isTraitable()
  651.     {
  652.         return false;
  653.     }
  654.     public function getDebugInfo()
  655.     {
  656.         return array (  709 => 20,  698 => 18,  694 => 17,  691 => 16,  681 => 15,  658 => 14,  468 => 136,  458 => 135,  447 => 133,  442 => 130,  440 => 129,  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,);
  657.     }
  658.     public function getSourceContext()
  659.     {
  660.         return new Source("{% extends 'base.html.twig' %}
  661. {% block stylesheets %}
  662.     <link rel=\"stylesheet\" href=\"/css/swiper/swiper.min.css\" />
  663.     {{ parent() }}
  664. {% endblock %}
  665. {% block mainColumnClass %}
  666.     {{ parent() }}
  667.     one-column comments-live-content
  668. {% endblock %}
  669. {% block header %}
  670.     {% if isMobileDevice() %}
  671.         {% embed 'header_mobile.html.twig' %}
  672.             {% block menuBlock %}
  673.                 <li class=\"title\"><span>ОТЗЫВЫ</span></li>
  674.                 {% for item in topMenu %}
  675.                     <li><a href=\"{{ item.getURL() }}\">{{ item.getAlias() != null ? item.getAlias() : item.getName() }}</a></li>
  676.                 {% endfor %}
  677.             {% endblock %}
  678.         {% endembed %}
  679.     {% else %}
  680.         {% embed 'header.html.twig' %}
  681.             {% block headerTopMenu %}
  682.                 {% include 'Slivki/header_menu.html.twig' with {'menuSelected': constant('Slivki\\\\Entity\\\\MainMenu::MENU_ID_COMMENT')} %}
  683.             {% endblock %}
  684.         {% endembed %}
  685.     {% endif %}
  686. {% endblock %}
  687. {% block main_content %}
  688.     <div id=\"commentsBox\">
  689.         <div class=\"breadcrumbs\">
  690.             <a href=\"{{ base_url }}\">Главная</a>
  691.             {% if category is defined  %}
  692.                 <i class=\"fa fa-angle-right\"></i>&nbsp; <a href=\"{{ path('commentsLive') }}\">Отзывы</a>
  693.                 {% for parentCategory in parentCategories %}
  694.                     <i class=\"fa fa-angle-right\"></i>&nbsp;<a href=\"/otzyvy{{ getCategoryURL(parentCategory) }}\">{{ parentCategory.getName() }}</a>
  695.                 {% endfor %}
  696.                 <i class=\"fa fa-angle-right\"></i>&nbsp;{{ category.getName() }}
  697.             {% else %}
  698.                 <i class=\"fa fa-angle-right\"></i>&nbsp;Отзывы
  699.             {% endif %}
  700.         </div>
  701.         <div class=\"clear\"></div>
  702.         <div class=\"stock-group-header\">
  703.             {% if title is defined %}
  704.                 <div class=\"title\">{{ title|raw }}</div>
  705.             {% endif %}
  706.             {% if subCategories is defined %}
  707.                 <div class=\"subcategories-list\">
  708.                     {% for subCategory in subCategories %}
  709.                         <a href=\"{{ getURL(constant('Slivki\\\\Repository\\\\SeoRepository::RESOURCE_URL_CATEGORY_COMMENTS'), subCategory.getID()) }}\">
  710.                             {{ subCategory.getName() }}
  711.                             <span class=\"green\">({{ subCategory.getEntityCount() }})</span>
  712.                         </a>
  713.                     {% endfor %}
  714.                 </div>
  715.             {% endif %}
  716.         </div>
  717.         <div class=\"clear\"></div>
  718.         {% if categoryID is defined %}
  719.             {{ getUserCommentsMediaBlockByEntityID(categoryID, 'category') }}
  720.         {% else %}
  721.             {% if offerID is defined %}
  722.                 {% set userCommentMediaBlock = getUserCommentsMediaBlockByEntityID(offerID, 'offer') %}
  723.                 {% set offerSupplierPhotoBlock = getSupplierOfferPhotoBlockByOfferID(offerID) %}
  724.                 {% if userCommentMediaBlock != '' and offerSupplierPhotoBlock != '' %}
  725.                     <ul id=\"commentPhotoTabs\" class=\"nav nav-tabs\" role=\"tablist\">
  726.                         <li class=\"active single-line\"><a href=\"#commentSupplierPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото работ</a></li>
  727.                         <li class=\"single-line\"><a href=\"#commentUserPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото из отзывов</a></li>
  728.                     </ul>
  729.                     <div class=\"tab-content\">
  730.                         <div class=\"tab-pane fade in active\" id=\"commentSupplierPhotoTab\">
  731.                             {{ offerSupplierPhotoBlock|raw }}
  732.                         </div>
  733.                         <div class=\"tab-pane fade\" id=\"commentUserPhotoTab\">
  734.                             {{ userCommentMediaBlock|raw }}
  735.                         </div>
  736.                     </div>
  737.                 {% elseif userCommentMediaBlock != '' %}
  738.                     {{ userCommentMediaBlock|raw }}
  739.                 {% elseif offerSupplierPhotoBlock != '' %}
  740.                     {{ offerSupplierPhotoBlock|raw }}
  741.                 {% endif %}
  742.             {% else %}
  743.                 {{ getUserCommentsMediaBlockByEntityID(null, 'all') }}
  744.             {% endif %}
  745.         {% endif %}
  746.         <div class=\"comments-list userVotes message\">
  747.             <div><img class=\"ajaxLoader\" src=\"/images/image-preview-ajax-loader.gif\" alt=\"Загрузка...\"></div>
  748.             {{ comments|raw }}
  749.         </div>
  750.     </div>
  751.     {% if offerID is defined %}
  752.         <input type=\"hidden\" id=\"stock-id\" value=\"{{ offerID }}\">
  753.         {% if (not is_granted(constant('Slivki\\\\Entity\\\\UserGroup::COMMENTS_BANNED_ROLE_NAME'))) %}
  754.             <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>
  755.         {% endif %}
  756.     {% endif %}
  757.     {% if categoryID is defined %}
  758.         <input type=\"hidden\" id=\"category-id\" value=\"{{ categoryID }}\">
  759.         {% if category.getTypeID ==  constant('Slivki\\\\Entity\\\\Category::SUPPLIER_CATEGORY_TYPE') %}
  760.             {% include 'Slivki/pagination.html.twig' with {'paginationID': 'categoryCommentPagination', 'total': commentsCount//10, 'current': page, 'url': app.request.pathInfo() ~ '?page='} %}
  761.         {% endif %}
  762.     {% endif %}
  763. {% endblock %}
  764. {% block popups %}
  765.     {{ parent() }}
  766.     {% include 'Slivki/popups/comment_media_block_popup.html.twig' %}
  767.     {% if not isMobileDevice() %}
  768.         {% if app.user %}
  769.             {% include 'Slivki/popups/add_comment_popup.html.twig' with {'id': 'addVoteBox'} %}
  770.             {% include 'Slivki/popups/edit_comment_popup.html.twig' with {'id': 'editVoteBox'} %}
  771.         {% else %}
  772.             {% include 'Slivki/popups/comment_only_registered_popup.html.twig' with {'id': 'onlyRegistered'} %}
  773.         {% endif %}
  774.     {% endif %}
  775. {% endblock %}
  776. {% block javascripts %}
  777.     {{ parent() }}
  778.     <script src=\"/js/swiper-js/swiper.min.js\"></script>
  779.     <script type=\"text/javascript\">
  780.         \$(document).ready(function(){
  781.             uploadPhoto('/comment/image_upload', '/comment/image_remove');
  782.         });
  783.         {% if offerID is defined %}
  784.             initVoteBox();
  785.             initSupplierPhotoSwiper();
  786.         {% endif %}
  787.     </script>
  788. {% endblock %}
  789. {% block assetsBottom %}
  790.     {{ parent() }}
  791. {% endblock %}""Slivki/comments/comments_live.html.twig""/mnt/data/virtwww/vlad-slivki/templates/Slivki/comments/comments_live.html.twig");
  792.     }
  793. }
  794. /* Slivki/comments/comments_live.html.twig */
  795. class __TwigTemplate_c5869eaa945019e1fa57c1e5795ef0fc72c1226bd2e98ff78f08b205520e324d___513150748 extends Template
  796. {
  797.     private $source;
  798.     private $macros = [];
  799.     public function __construct(Environment $env)
  800.     {
  801.         parent::__construct($env);
  802.         $this->source $this->getSourceContext();
  803.         $this->blocks = [
  804.             'headerTopMenu' => [$this'block_headerTopMenu'],
  805.         ];
  806.     }
  807.     protected function doGetParent(array $context)
  808.     {
  809.         // line 23
  810.         return "header.html.twig";
  811.     }
  812.     protected function doDisplay(array $context, array $blocks = [])
  813.     {
  814.         $macros $this->macros;
  815.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  816.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""Slivki/comments/comments_live.html.twig"));
  817.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  818.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""Slivki/comments/comments_live.html.twig"));
  819.         $this->parent $this->loadTemplate("header.html.twig""Slivki/comments/comments_live.html.twig"23);
  820.         $this->parent->display($contextarray_merge($this->blocks$blocks));
  821.         
  822.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  823.         
  824.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  825.     }
  826.     // line 24
  827.     public function block_headerTopMenu($context, array $blocks = [])
  828.     {
  829.         $macros $this->macros;
  830.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  831.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""headerTopMenu"));
  832.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  833.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""headerTopMenu"));
  834.         // line 25
  835.         echo "                ";
  836.         $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")]));
  837.         // line 26
  838.         echo "            ";
  839.         
  840.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  841.         
  842.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  843.     }
  844.     public function getTemplateName()
  845.     {
  846.         return "Slivki/comments/comments_live.html.twig";
  847.     }
  848.     public function isTraitable()
  849.     {
  850.         return false;
  851.     }
  852.     public function getDebugInfo()
  853.     {
  854.         return array (  932 => 26,  929 => 25,  919 => 24,  896 => 23,  709 => 20,  698 => 18,  694 => 17,  691 => 16,  681 => 15,  658 => 14,  468 => 136,  458 => 135,  447 => 133,  442 => 130,  440 => 129,  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,);
  855.     }
  856.     public function getSourceContext()
  857.     {
  858.         return new Source("{% extends 'base.html.twig' %}
  859. {% block stylesheets %}
  860.     <link rel=\"stylesheet\" href=\"/css/swiper/swiper.min.css\" />
  861.     {{ parent() }}
  862. {% endblock %}
  863. {% block mainColumnClass %}
  864.     {{ parent() }}
  865.     one-column comments-live-content
  866. {% endblock %}
  867. {% block header %}
  868.     {% if isMobileDevice() %}
  869.         {% embed 'header_mobile.html.twig' %}
  870.             {% block menuBlock %}
  871.                 <li class=\"title\"><span>ОТЗЫВЫ</span></li>
  872.                 {% for item in topMenu %}
  873.                     <li><a href=\"{{ item.getURL() }}\">{{ item.getAlias() != null ? item.getAlias() : item.getName() }}</a></li>
  874.                 {% endfor %}
  875.             {% endblock %}
  876.         {% endembed %}
  877.     {% else %}
  878.         {% embed 'header.html.twig' %}
  879.             {% block headerTopMenu %}
  880.                 {% include 'Slivki/header_menu.html.twig' with {'menuSelected': constant('Slivki\\\\Entity\\\\MainMenu::MENU_ID_COMMENT')} %}
  881.             {% endblock %}
  882.         {% endembed %}
  883.     {% endif %}
  884. {% endblock %}
  885. {% block main_content %}
  886.     <div id=\"commentsBox\">
  887.         <div class=\"breadcrumbs\">
  888.             <a href=\"{{ base_url }}\">Главная</a>
  889.             {% if category is defined  %}
  890.                 <i class=\"fa fa-angle-right\"></i>&nbsp; <a href=\"{{ path('commentsLive') }}\">Отзывы</a>
  891.                 {% for parentCategory in parentCategories %}
  892.                     <i class=\"fa fa-angle-right\"></i>&nbsp;<a href=\"/otzyvy{{ getCategoryURL(parentCategory) }}\">{{ parentCategory.getName() }}</a>
  893.                 {% endfor %}
  894.                 <i class=\"fa fa-angle-right\"></i>&nbsp;{{ category.getName() }}
  895.             {% else %}
  896.                 <i class=\"fa fa-angle-right\"></i>&nbsp;Отзывы
  897.             {% endif %}
  898.         </div>
  899.         <div class=\"clear\"></div>
  900.         <div class=\"stock-group-header\">
  901.             {% if title is defined %}
  902.                 <div class=\"title\">{{ title|raw }}</div>
  903.             {% endif %}
  904.             {% if subCategories is defined %}
  905.                 <div class=\"subcategories-list\">
  906.                     {% for subCategory in subCategories %}
  907.                         <a href=\"{{ getURL(constant('Slivki\\\\Repository\\\\SeoRepository::RESOURCE_URL_CATEGORY_COMMENTS'), subCategory.getID()) }}\">
  908.                             {{ subCategory.getName() }}
  909.                             <span class=\"green\">({{ subCategory.getEntityCount() }})</span>
  910.                         </a>
  911.                     {% endfor %}
  912.                 </div>
  913.             {% endif %}
  914.         </div>
  915.         <div class=\"clear\"></div>
  916.         {% if categoryID is defined %}
  917.             {{ getUserCommentsMediaBlockByEntityID(categoryID, 'category') }}
  918.         {% else %}
  919.             {% if offerID is defined %}
  920.                 {% set userCommentMediaBlock = getUserCommentsMediaBlockByEntityID(offerID, 'offer') %}
  921.                 {% set offerSupplierPhotoBlock = getSupplierOfferPhotoBlockByOfferID(offerID) %}
  922.                 {% if userCommentMediaBlock != '' and offerSupplierPhotoBlock != '' %}
  923.                     <ul id=\"commentPhotoTabs\" class=\"nav nav-tabs\" role=\"tablist\">
  924.                         <li class=\"active single-line\"><a href=\"#commentSupplierPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото работ</a></li>
  925.                         <li class=\"single-line\"><a href=\"#commentUserPhotoTab\" role=\"tab\" data-toggle=\"tab\">Фото из отзывов</a></li>
  926.                     </ul>
  927.                     <div class=\"tab-content\">
  928.                         <div class=\"tab-pane fade in active\" id=\"commentSupplierPhotoTab\">
  929.                             {{ offerSupplierPhotoBlock|raw }}
  930.                         </div>
  931.                         <div class=\"tab-pane fade\" id=\"commentUserPhotoTab\">
  932.                             {{ userCommentMediaBlock|raw }}
  933.                         </div>
  934.                     </div>
  935.                 {% elseif userCommentMediaBlock != '' %}
  936.                     {{ userCommentMediaBlock|raw }}
  937.                 {% elseif offerSupplierPhotoBlock != '' %}
  938.                     {{ offerSupplierPhotoBlock|raw }}
  939.                 {% endif %}
  940.             {% else %}
  941.                 {{ getUserCommentsMediaBlockByEntityID(null, 'all') }}
  942.             {% endif %}
  943.         {% endif %}
  944.         <div class=\"comments-list userVotes message\">
  945.             <div><img class=\"ajaxLoader\" src=\"/images/image-preview-ajax-loader.gif\" alt=\"Загрузка...\"></div>
  946.             {{ comments|raw }}
  947.         </div>
  948.     </div>
  949.     {% if offerID is defined %}
  950.         <input type=\"hidden\" id=\"stock-id\" value=\"{{ offerID }}\">
  951.         {% if (not is_granted(constant('Slivki\\\\Entity\\\\UserGroup::COMMENTS_BANNED_ROLE_NAME'))) %}
  952.             <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>
  953.         {% endif %}
  954.     {% endif %}
  955.     {% if categoryID is defined %}
  956.         <input type=\"hidden\" id=\"category-id\" value=\"{{ categoryID }}\">
  957.         {% if category.getTypeID ==  constant('Slivki\\\\Entity\\\\Category::SUPPLIER_CATEGORY_TYPE') %}
  958.             {% include 'Slivki/pagination.html.twig' with {'paginationID': 'categoryCommentPagination', 'total': commentsCount//10, 'current': page, 'url': app.request.pathInfo() ~ '?page='} %}
  959.         {% endif %}
  960.     {% endif %}
  961. {% endblock %}
  962. {% block popups %}
  963.     {{ parent() }}
  964.     {% include 'Slivki/popups/comment_media_block_popup.html.twig' %}
  965.     {% if not isMobileDevice() %}
  966.         {% if app.user %}
  967.             {% include 'Slivki/popups/add_comment_popup.html.twig' with {'id': 'addVoteBox'} %}
  968.             {% include 'Slivki/popups/edit_comment_popup.html.twig' with {'id': 'editVoteBox'} %}
  969.         {% else %}
  970.             {% include 'Slivki/popups/comment_only_registered_popup.html.twig' with {'id': 'onlyRegistered'} %}
  971.         {% endif %}
  972.     {% endif %}
  973. {% endblock %}
  974. {% block javascripts %}
  975.     {{ parent() }}
  976.     <script src=\"/js/swiper-js/swiper.min.js\"></script>
  977.     <script type=\"text/javascript\">
  978.         \$(document).ready(function(){
  979.             uploadPhoto('/comment/image_upload', '/comment/image_remove');
  980.         });
  981.         {% if offerID is defined %}
  982.             initVoteBox();
  983.             initSupplierPhotoSwiper();
  984.         {% endif %}
  985.     </script>
  986. {% endblock %}
  987. {% block assetsBottom %}
  988.     {{ parent() }}
  989. {% endblock %}""Slivki/comments/comments_live.html.twig""/mnt/data/virtwww/vlad-slivki/templates/Slivki/comments/comments_live.html.twig");
  990.     }
  991. }