templates/base.html.twig line 13

Open in your IDE?
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1.0"/>
  6. <title>STV ADMIN {% block title %}Welcome!{% endblock %}</title>
  7. <link rel="icon" href="/images/favicon.png">
  8. {% block stylesheets %}
  9. {{ encore_entry_link_tags('index') }}
  10. {% endblock %}
  11. <script>
  12. var sspmgr = {
  13. roles: {% if app.user %}{{ app.user.roles | json_encode | raw}}{% else %}[]{% endif %}
  14. }
  15. </script>
  16. {% block javascripts %}
  17. {{ encore_entry_script_tags('index') }}
  18. {% endblock %}
  19. </head>
  20. <body>
  21. <nav class="stv-grey" role="navigation">
  22. <div class="nav-wrapper">
  23. <a id="logo-container" href="/" class="brand-logo">
  24. <img src="/images/logo.png" /><span>SSP</span>
  25. </a>
  26. <a class="user right tooltipped {{ app.user ? : 'empty' }}" href="/logout" data-position="bottom" data-margin="20" data-tooltip="Logout {{ app.user }}">
  27. <svg style="width:24px;height:24px" viewBox="0 0 24 24">
  28. <path fill="currentColor" d="M12,19.2C9.5,19.2 7.29,17.92 6,16C6.03,14 10,12.9 12,12.9C14,12.9 17.97,14 18,16C16.71,17.92 14.5,19.2 12,19.2M12,5A3,3 0 0,1 15,8A3,3 0 0,1 12,11A3,3 0 0,1 9,8A3,3 0 0,1 12,5M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12C22,6.47 17.5,2 12,2Z" />
  29. </svg>
  30. </a>
  31. <ul class="right hide-on-med-and-down">
  32. {% if is_granted('ROLE_USER') %}
  33. <li><a href="/publisher" {% if app.request.get('_route') starts with 'app_publisher' or app.request.get('_route') starts with 'app_inventory'%}class="stv-pink-text"{%endif%}>Inventory</a></li>
  34. <li><a class="dropdown-trigger {% if app.request.get('_route') starts with 'app_demand' %}stv-pink-text{%endif%}" href="#!" data-target="dsp-dropdown">
  35. Demand
  36. <span class="white-text">
  37. <svg style="width:15px;height:15px;" viewBox="5 4 12 12">
  38. <path fill="currentColor" d="M7,10L12,15L17,10H7Z" />
  39. </svg>
  40. </span>
  41. </a></li>
  42. {% endif %}
  43. </ul>
  44. <ul id="nav-mobile" class="sidenav stv-grey">
  45. {% if is_granted('ROLE_USER') %}
  46. {# <li><a href="/dashboard" class="{% if app.request.get('_route') starts with 'app_dashboard' %}stv-pink-text{%else%}white-text{%endif%}">Dashboard</a></li>#}
  47. <li><a href="/publisher" {% if app.request.get('_route') starts with 'app_publisher' or app.request.get('_route') starts with 'app_inventory'%}class="stv-pink-text"{%endif%}>Inventory</a></li>
  48. {% for item in dsp.getList %}
  49. <li><a href="/demand/{{ item.id }}/general" class="{% if app.request.attributes.get('_route_params')['slug'] is defined and app.request.attributes.get('_route_params')['slug'] is same as(item.id) %}stv-pink-text{%else%}white-text{%endif%}">{{ item.name }}</a></li>
  50. {% endfor %}
  51. {% endif %}
  52. </ul>
  53. <a href="#" data-target="nav-mobile" class="sidenav-trigger">
  54. <svg style="" viewBox="0 0 24 24">
  55. <path fill="currentColor" d="M3,6H21V8H3V6M3,11H21V13H3V11M3,16H21V18H3V16Z" />
  56. </svg>
  57. </a>
  58. </div>
  59. </nav>
  60. <ul id="dsp-dropdown" class="dropdown-content stv-grey">
  61. {% if dsps is defined %}
  62. {% for dsp in dsps%}
  63. {% if is_granted('ROLE_ADMIN') %}
  64. <li><a href="/demand/{{ dsp.id }}/general" class=" white-text" style="font-size:15px">{{ dsp.name }}</a></li>
  65. {% else %}
  66. <li><a href="/demand/{{ dsp.id }}/deals" class=" white-text" style="font-size:15px">{{ dsp.name }}</a></li>
  67. {% endif %}
  68. {% endfor %}
  69. {% endif %}
  70. </ul>
  71. <section id="stv-content">
  72. {% if app.request.get('_route') starts with 'app_publisher' or app.request.get('_route') starts with 'app_inventory'%}
  73. <div class="subnavigation" style="box-shadow: 0 4px 5px 0 rgba(0, 0, 0, 0.14)">
  74. <div class="items" ref="items">
  75. <a href="/publisher">Publisher</a>
  76. <a href="/inventory">Inventory Groups</a>
  77. </div>
  78. <div class="indicator" style="left: {{ app.request.get('_route') starts with 'app_publisher' ? 0 : 50 }}%; width: 50%;"></div>
  79. </div>
  80. {% endif %}
  81. {% block content %}{% endblock %}
  82. </section>
  83. <div class="stv-separator"></div>
  84. <footer class="stv-grey right-align">
  85. &copy; {{ "now"|date("Y") }} <a class="stv-pink-text" href="https://smartstream.tv" target="_blank">SMARTSTREAM.TV</a>
  86. </footer>
  87. </body>
  88. </html>