You are here

routing.html.twig in Devel 8.3

{% block toolbar %}
    {% set icon %}
    <a href="{{ url("webprofiler.dashboard", {profile: token}, {fragment: 'routing'}) }}" title="{{ 'Routing'|t }}">
        <img width="20" height="28" alt="{{ 'Routing'|t }}"
             src="data:image/png;base64,{{ collector.icon }}">
        <span class="sf-toolbar-info-piece-additional sf-toolbar-status">{{ collector.getRoutesCount }}</span>
    </a>

    {% endset %}

    {% set text %}
    <div class="sf-toolbar-info-piece">
        <b>{{ 'Routes'|t }}</b>
        <span>{{ collector.getRoutesCount }}</span>
    </div>
    {% endset %}

    <div class="sf-toolbar-block">
        <div class="sf-toolbar-icon">{{ icon|default('') }}</div>
        <div class="sf-toolbar-info">{{ text|default('') }}</div>
    </div>
{% endblock %}

{% block panel %}
    <script id="routing" type="text/template">
        <h2 class="panel__title">{{ 'Routing'|t }}</h2>
        <div class="panel__container">
            <table class="table--duo">
                <thead>
                <tr>
                    <th>{{ 'name'|t }}</th>
                    <th>{{ 'path'|t }}</th>
                </tr>
                </thead>
                <tbody>
                <% _.each( data.routing, function( item ){ %>
                    <tr>
                        <td>
                            <%- item.name %>
                        </td>
                        <td>
                            <%- item.path %>
                        </td>
                    </tr>
                <% }); %>
                </tbody>
            </table>
        </div>
    </script>
{% endblock %}

File

webprofiler/templates/Collector/routing.html.twig
View source
  1. {% block toolbar %}
  2. {% set icon %}
  3. <a href="{{ url("webprofiler.dashboard", {profile: token}, {fragment: 'routing'}) }}" title="{{ 'Routing'|t }}">
  4. <img width="20" height="28" alt="{{ 'Routing'|t }}"
  5. src="data:image/png;base64,{{ collector.icon }}">
  6. <span class="sf-toolbar-info-piece-additional sf-toolbar-status">{{ collector.getRoutesCount }}</span>
  7. </a>
  8. {% endset %}
  9. {% set text %}
  10. <div class="sf-toolbar-info-piece">
  11. <b>{{ 'Routes'|t }}</b>
  12. <span>{{ collector.getRoutesCount }}</span>
  13. </div>
  14. {% endset %}
  15. <div class="sf-toolbar-block">
  16. <div class="sf-toolbar-icon">{{ icon|default('') }}</div>
  17. <div class="sf-toolbar-info">{{ text|default('') }}</div>
  18. </div>
  19. {% endblock %}
  20. {% block panel %}
  21. <script id="routing" type="text/template">
  22. <h2 class="panel__title">{{ 'Routing'|t }}</h2>
  23. <div class="panel__container">
  24. <table class="table--duo">
  25. <thead>
  26. <tr>
  27. <th>{{ 'name'|t }}</th>
  28. <th>{{ 'path'|t }}</th>
  29. </tr>
  30. </thead>
  31. <tbody>
  32. <% _.each( data.routing, function( item ){ %>
  33. <tr>
  34. <td>
  35. <%- item.name %>
  36. </td>
  37. <td>
  38. <%- item.path %>
  39. </td>
  40. </tr>
  41. <% }); %>
  42. </tbody>
  43. </table>
  44. </div>
  45. </script>
  46. {% endblock %}