var/cache/dev/twig/e3/e384072b10784a892ddce41bcf5e2efe.php line 39

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. /* questionAnswer/show.html.twig */
  14. class __TwigTemplate_0ad41ed2b549aad57078fa9cb357e37d 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.             'title' => [$this'block_title'],
  24.             'body' => [$this'block_body'],
  25.         ];
  26.     }
  27.     protected function doGetParent(array $context)
  28.     {
  29.         // line 1
  30.         return "base.html.twig";
  31.     }
  32.     protected function doDisplay(array $context, array $blocks = [])
  33.     {
  34.         $macros $this->macros;
  35.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  36.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""questionAnswer/show.html.twig"));
  37.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  38.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""questionAnswer/show.html.twig"));
  39.         $this->parent $this->loadTemplate("base.html.twig""questionAnswer/show.html.twig"1);
  40.         $this->parent->display($contextarray_merge($this->blocks$blocks));
  41.         
  42.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  43.         
  44.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  45.     }
  46.     // line 3
  47.     public function block_title($context, array $blocks = [])
  48.     {
  49.         $macros $this->macros;
  50.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  51.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""title"));
  52.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  53.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""title"));
  54.         echo twig_escape_filter($this->envtwig_replace_filter(twig_get_attribute($this->env$this->source, (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'3$this->source); })()), "title", [], "any"falsefalsefalse3), ["<br>" => ""]), "html"nulltrue);
  55.         
  56.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  57.         
  58.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  59.     }
  60.     // line 9
  61.     public function block_body($context, array $blocks = [])
  62.     {
  63.         $macros $this->macros;
  64.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  65.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""body"));
  66.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  67.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""body"));
  68.         // line 10
  69.         echo "\t<div class=\"titre\">
  70. \t\t<h1>";
  71.         // line 11
  72.         echo twig_get_attribute($this->env$this->source, (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'11$this->source); })()), "title", [], "any"falsefalsefalse11);
  73.         echo "</h1>
  74. \t</div>
  75. \t";
  76.         // line 13
  77.         if ($this->extensions['Symfony\Bridge\Twig\Extension\SecurityExtension']->isGranted("ROLE_EDITOR")) {
  78.             // line 14
  79.             echo "\t\t";
  80.             $context["url"] = twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$this->extensions['EasyCorp\Bundle\EasyAdminBundle\Twig\EasyAdminTwigExtension']->getAdminUrlGenerator(), "setController", ["App\\Controller\\Admin\\QuestionAnswerCrudController"], "method"falsefalsefalse14), "setAction", ["edit"], "method"falsefalsefalse15), "setEntityId", [twig_get_attribute($this->env$this->source,             // line 17
  81. (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'17$this->source); })()), "id", [], "any"falsefalsefalse17)], "method"falsefalsefalse16);
  82.             // line 18
  83.             echo "\t\t<p><a class=\"adm-link\" href=\"";
  84.             echo twig_escape_filter($this->env, (isset($context["url"]) || array_key_exists("url"$context) ? $context["url"] : (function () { throw new RuntimeError('Variable "url" does not exist.'18$this->source); })()), "html"nulltrue);
  85.             echo "\" target=\"_blank\">administrer la question-réponse</a></p>
  86. \t";
  87.         }
  88.         // line 20
  89.         echo "\t";
  90.         // line 23
  91.         echo "
  92. \t";
  93.         // line 24
  94.         $this->loadTemplate("media/postMedias.html.twig""questionAnswer/show.html.twig"24)->display(twig_array_merge($context, ["medias" => twig_get_attribute($this->env$this->source, (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'24$this->source); })()), "medias", [], "any"falsefalsefalse24), "mediasType" => "slides"]));
  95.         // line 25
  96.         echo "        
  97.     ";
  98.         // line 26
  99.         if ((twig_length_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'26$this->source); })()), "chapo", [], "any"falsefalsefalse26)) > 5)) {
  100.             // line 27
  101.             echo "        <div class=\"chapo\">
  102.             ";
  103.             // line 28
  104.             echo twig_get_attribute($this->env$this->source, (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'28$this->source); })()), "chapo", [], "any"falsefalsefalse28);
  105.             echo "
  106.         </div>
  107.     ";
  108.         }
  109.         // line 31
  110.         echo "
  111.     ";
  112.         // line 32
  113.         $context["hideThumbnails"] = false;
  114.         $context['_parent'] = $context;
  115.         $context['_seq'] = twig_ensure_traversable(twig_array_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'32$this->source); })()), "medias", [], "any"falsefalsefalse32), function ($__media__) use ($context$macros) { $context["media"] = $__media__; return (twig_get_attribute($this->env$this->source$context["media"], "role", [], "any"falsefalsefalse32) == "slide"); }));
  116.         foreach ($context['_seq'] as $context["_key"] => $context["media"]) {
  117.             $context["hideThumbnails"] = true;
  118.         }
  119.         $_parent $context['_parent'];
  120.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['media'], $context['_parent'], $context['loop']);
  121.         $context array_intersect_key($context$_parent) + $_parent;
  122.         // line 33
  123.         echo "    ";
  124.         if ( !(isset($context["hideThumbnails"]) || array_key_exists("hideThumbnails"$context) ? $context["hideThumbnails"] : (function () { throw new RuntimeError('Variable "hideThumbnails" does not exist.'33$this->source); })())) {
  125.             $this->loadTemplate("media/postMedias.html.twig""questionAnswer/show.html.twig"33)->display(twig_array_merge($context, ["medias" => twig_get_attribute($this->env$this->source, (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'33$this->source); })()), "medias", [], "any"falsefalsefalse33), "mediasType" => "thumbnails"]));
  126.         }
  127.         // line 34
  128.         echo "\t
  129. \t<div class=\"contenu\">
  130. \t\t";
  131.         // line 36
  132.         echo twig_get_attribute($this->env$this->source, (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'36$this->source); })()), "content", [], "any"falsefalsefalse36);
  133.         echo "
  134. \t</div>
  135. \t";
  136.         // line 39
  137.         $this->loadTemplate("media/postMedias.html.twig""questionAnswer/show.html.twig"39)->display(twig_array_merge($context, ["medias" => twig_get_attribute($this->env$this->source, (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'39$this->source); })()), "medias", [], "any"falsefalsefalse39), "mediasType" => "documents"]));
  138.         // line 40
  139.         echo "
  140. \t";
  141.         // line 42
  142.         echo "    ";
  143.         $this->loadTemplate("common/seealso.html.twig""questionAnswer/show.html.twig"42)->display(twig_array_merge($context, ["entity" => (isset($context["questionAnswer"]) || array_key_exists("questionAnswer"$context) ? $context["questionAnswer"] : (function () { throw new RuntimeError('Variable "questionAnswer" does not exist.'42$this->source); })())]));
  144.         // line 43
  145.         echo "
  146. \t<p>
  147. \t\tUne erreur ? Un complément à ajouter ? <a href=\"";
  148.         // line 45
  149.         echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("contact");
  150.         echo "\"><strong>Signalez-le nous !</strong></a>
  151. \t</p>
  152. \t<p>
  153. \t\tVous souhaitez faire une autre recherche ? <a href=\"";
  154.         // line 48
  155.         echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("themeList");
  156.         echo "\">Faites une recherche par thème ou par mot-clé</a>
  157. \t</p>
  158. ";
  159.         
  160.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  161.         
  162.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  163.     }
  164.     public function getTemplateName()
  165.     {
  166.         return "questionAnswer/show.html.twig";
  167.     }
  168.     public function isTraitable()
  169.     {
  170.         return false;
  171.     }
  172.     public function getDebugInfo()
  173.     {
  174.         return array (  175 => 48,  169 => 45,  165 => 43,  162 => 42,  159 => 40,  157 => 39,  151 => 36,  147 => 34,  142 => 33,  132 => 32,  129 => 31,  123 => 28,  120 => 27,  118 => 26,  115 => 25,  113 => 24,  110 => 23,  108 => 20,  102 => 18,  100 => 17,  98 => 14,  96 => 13,  91 => 11,  88 => 10,  78 => 9,  59 => 3,  36 => 1,);
  175.     }
  176.     public function getSourceContext()
  177.     {
  178.         return new Source("{% extends 'base.html.twig' %}
  179. {% block title %}{{ questionAnswer.title|replace({ '<br>':'' }) }}{% endblock %}
  180. {# {% block stylesheets %}
  181. \t{{ parent() }}
  182. {% endblock %} #}
  183. {% block body %}
  184. \t<div class=\"titre\">
  185. \t\t<h1>{{ questionAnswer.title|raw }}</h1>
  186. \t</div>
  187. \t{% if is_granted('ROLE_EDITOR') %}
  188. \t\t{% set url = ea_url()
  189. \t\t\t.setController('App\\\\Controller\\\\Admin\\\\QuestionAnswerCrudController')
  190. \t\t\t.setAction('edit')
  191. \t\t\t.setEntityId(questionAnswer.id) %}
  192. \t\t<p><a class=\"adm-link\" href=\"{{ url }}\" target=\"_blank\">administrer la question-réponse</a></p>
  193. \t{% endif %}
  194. \t{# <div class=\"date\">
  195. \t\t{{questionAnswer.createdAt|date(\"d/m/Y\")}}
  196. \t</div> #}
  197. \t{% include 'media/postMedias.html.twig' with {'medias': questionAnswer.medias, 'mediasType': 'slides' } %}
  198.         
  199.     {% if questionAnswer.chapo|length > 5 %}
  200.         <div class=\"chapo\">
  201.             {{ questionAnswer.chapo|raw }}
  202.         </div>
  203.     {% endif %}
  204.     {% set hideThumbnails = false %}{% for media in questionAnswer.medias|filter(media => media.role == \"slide\") %}{% set hideThumbnails = true %}{% endfor %}{# car icig ne veut pas de thumbnail s'il y a des slides #}
  205.     {% if not hideThumbnails %}{% include 'media/postMedias.html.twig' with {'medias': questionAnswer.medias, 'mediasType': 'thumbnails' } %}{% endif %}
  206. \t
  207. \t<div class=\"contenu\">
  208. \t\t{{ questionAnswer.content|raw }}
  209. \t</div>
  210. \t{% include 'media/postMedias.html.twig' with {'medias': questionAnswer.medias, 'mediasType': 'documents' } %}
  211. \t{# {{ render(controller('App\\\\Controller\\\\QuestionAnswerController:listSame', { 'id' : questionAnswer.id })) }} #}
  212.     {% include 'common/seealso.html.twig' with {'entity': questionAnswer } %}
  213. \t<p>
  214. \t\tUne erreur ? Un complément à ajouter ? <a href=\"{{ path('contact') }}\"><strong>Signalez-le nous !</strong></a>
  215. \t</p>
  216. \t<p>
  217. \t\tVous souhaitez faire une autre recherche ? <a href=\"{{ path('themeList') }}\">Faites une recherche par thème ou par mot-clé</a>
  218. \t</p>
  219. {% endblock %}
  220. ""questionAnswer/show.html.twig""/home/ovow2306/public_html/ici-grenoble/ici-gre-back-dev/templates/questionAnswer/show.html.twig");
  221.     }
  222. }