3be38f49c515f19fbc2326d241dd.php 7.8KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188
  1. <?php
  2. /* WebProfilerBundle:Collector:logger.html.twig */
  3. class __TwigTemplate_78b63be38f49c515f19fbc2326d241dd extends Twig_Template
  4. {
  5. protected $parent;
  6. public function __construct(Twig_Environment $env)
  7. {
  8. parent::__construct($env);
  9. $this->parent = array();
  10. $this->blocks = array(
  11. 'toolbar' => array($this, 'block_toolbar'),
  12. 'menu' => array($this, 'block_menu'),
  13. 'panel' => array($this, 'block_panel'),
  14. );
  15. }
  16. public function getParent(array $context)
  17. {
  18. $parent = "WebProfilerBundle:Profiler:layout.html.twig";
  19. if ($parent instanceof Twig_Template) {
  20. $name = $parent->getTemplateName();
  21. $this->parent[$name] = $parent;
  22. $parent = $name;
  23. } elseif (!isset($this->parent[$parent])) {
  24. $this->parent[$parent] = $this->env->loadTemplate($parent);
  25. }
  26. return $this->parent[$parent];
  27. }
  28. protected function doDisplay(array $context, array $blocks = array())
  29. {
  30. $context = array_merge($this->env->getGlobals(), $context);
  31. $this->getParent($context)->display($context, array_merge($this->blocks, $blocks));
  32. }
  33. // line 3
  34. public function block_toolbar($context, array $blocks = array())
  35. {
  36. // line 4
  37. echo " ";
  38. if ($this->getAttribute($this->getContext($context, 'collector'), "counterrors", array(), "any", false)) {
  39. // line 5
  40. echo " ";
  41. ob_start();
  42. // line 6
  43. echo " <img width=\"15\" height=\"28\" alt=\"Logs\" style=\"border-width: 0; vertical-align: middle; margin-right: 5px;\" src=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA8AAAAcCAYAAAC+lOV/AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAQVJREFUeNpi/P//PwO5gImBAjBwmlm8vLyOf/v2zYJYDVxcXCe2bdvmeu7cuS+M9vb2ZIWYoKDgUrKcvWLFipWfP38OYcEmeeDAgQtA6gMQCzg4OBigy0tISHxhYmJiYMFh+EIgBhlgAMXo4DEwffzH5ewLwAA5ADUAG/g7lBMJNkFgCO8fGJsJxTNezUTEM15nE4rnAQ4wkjVraWm9BlK/wc62tLR8fOXKFZmmpqYHhoaGT4Fif/Do/Q7Ep/bt28fz+/dvDkZgKdI4ZcqUmMOHD0t8+vSJi1gXKCgoPGQE5ixTIBuExUjwKsiSpyDNnECGOBCLAjEnkeEA8vMbxqFZ6AMEGADoe2NON2x5yQAAAABJRU5ErkJggg==\"/>
  44. ";
  45. $context['icon'] = new Twig_Markup(ob_get_clean());
  46. // line 8
  47. echo " ";
  48. ob_start();
  49. // line 9
  50. echo " <span>";
  51. echo twig_escape_filter($this->env, $this->getAttribute($this->getContext($context, 'collector'), "counterrors", array(), "any", false), "html");
  52. echo "</span>
  53. ";
  54. $context['text'] = new Twig_Markup(ob_get_clean());
  55. // line 11
  56. echo " ";
  57. $this->env->loadTemplate("WebProfilerBundle:Profiler:toolbar_item.html.twig")->display(array_merge($context, array("link" => $this->getContext($context, 'profiler_url'))));
  58. // line 12
  59. echo " ";
  60. }
  61. }
  62. // line 15
  63. public function block_menu($context, array $blocks = array())
  64. {
  65. // line 16
  66. echo "<span class=\"label\">
  67. <span class=\"icon\"><img src=\"";
  68. // line 17
  69. echo twig_escape_filter($this->env, $this->env->getExtension('assets')->getAssetUrl("bundles/webprofiler/images/profiler/logger.png"), "html");
  70. echo "\" alt=\"Logger\" /></span>
  71. <strong>Logs</strong>
  72. ";
  73. // line 19
  74. if ($this->getAttribute($this->getContext($context, 'collector'), "counterrors", array(), "any", false)) {
  75. // line 20
  76. echo " <span class=\"count\">
  77. <span>";
  78. // line 21
  79. echo twig_escape_filter($this->env, $this->getAttribute($this->getContext($context, 'collector'), "counterrors", array(), "any", false), "html");
  80. echo "</span>
  81. </span>
  82. ";
  83. }
  84. // line 24
  85. echo "</span>
  86. ";
  87. }
  88. // line 27
  89. public function block_panel($context, array $blocks = array())
  90. {
  91. // line 28
  92. echo " <h2>Logs</h2>
  93. ";
  94. // line 30
  95. if ($this->getAttribute($this->getContext($context, 'collector'), "logs", array(), "any", false)) {
  96. // line 31
  97. echo " <ul class=\"alt\">
  98. ";
  99. // line 32
  100. $context['_parent'] = (array) $context;
  101. $context['_seq'] = twig_ensure_traversable($this->getAttribute($this->getContext($context, 'collector'), "logs", array(), "any", false));
  102. $context['loop'] = array(
  103. 'parent' => $context['_parent'],
  104. 'index0' => 0,
  105. 'index' => 1,
  106. 'first' => true,
  107. );
  108. if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof Countable)) {
  109. $length = count($context['_seq']);
  110. $context['loop']['revindex0'] = $length - 1;
  111. $context['loop']['revindex'] = $length;
  112. $context['loop']['length'] = $length;
  113. $context['loop']['last'] = 1 === $length;
  114. }
  115. foreach ($context['_seq'] as $context['_key'] => $context['log']) {
  116. // line 33
  117. echo " <li class=\"";
  118. echo twig_escape_filter($this->env, twig_cycle(array(0 => "odd", 1 => "even"), $this->getAttribute($this->getContext($context, 'loop'), "index", array(), "any", false)), "html");
  119. if ((("ERR" == $this->getAttribute($this->getContext($context, 'log'), "priorityName", array(), "any", false)) || ("ERROR" == $this->getAttribute($this->getContext($context, 'log'), "priorityName", array(), "any", false)))) {
  120. echo " error";
  121. }
  122. echo "\">
  123. ";
  124. // line 34
  125. echo twig_escape_filter($this->env, $this->getAttribute($this->getContext($context, 'log'), "message", array(), "any", false), "html");
  126. echo "
  127. ";
  128. // line 35
  129. if (($this->getAttribute(((array_key_exists("log", $context)) ? (twig_default_filter($this->getContext($context, 'log'))) : ("")), "context", array(), "any", true) && (!twig_test_empty($this->getAttribute($this->getContext($context, 'log'), "context", array(), "any", false))))) {
  130. // line 36
  131. echo " <br />
  132. <small>
  133. <strong>Context</strong>: ";
  134. // line 38
  135. echo twig_escape_filter($this->env, $this->env->getExtension('yaml')->encode($this->getAttribute($this->getContext($context, 'log'), "context", array(), "any", false)), "html");
  136. echo "
  137. </small>
  138. ";
  139. }
  140. // line 41
  141. echo " </li>
  142. ";
  143. ++$context['loop']['index0'];
  144. ++$context['loop']['index'];
  145. $context['loop']['first'] = false;
  146. if (isset($context['loop']['length'])) {
  147. --$context['loop']['revindex0'];
  148. --$context['loop']['revindex'];
  149. $context['loop']['last'] = 0 === $context['loop']['revindex0'];
  150. }
  151. }
  152. $_parent = $context['_parent'];
  153. unset($context['_seq'], $context['_iterated'], $context['_key'], $context['log'], $context['_parent'], $context['loop']);
  154. $context = array_merge($_parent, array_intersect_key($context, $_parent));
  155. // line 43
  156. echo " </ul>
  157. ";
  158. } else {
  159. // line 45
  160. echo " <p>
  161. <em>No logs available.</em>
  162. </p>
  163. ";
  164. }
  165. }
  166. public function getTemplateName()
  167. {
  168. return "WebProfilerBundle:Collector:logger.html.twig";
  169. }
  170. public function isTraitable()
  171. {
  172. return false;
  173. }
  174. }