"Fossies" - the Fresh Open Source Software Archive

Member "horizon-16.0.0/openstack_dashboard/themes/material/templates/horizon/_sidebar.html" (16 Oct 2019, 2988 Bytes) of package /linux/misc/openstack/horizon-16.0.0.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) HTML source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 {% load horizon i18n %}
    2 
    3 <div class="sidebar-wrapper">
    4   <ul id="sidebar-drawer" class="nav nav-pills nav-stacked">
    5     {% for dashboard, panel_info in components %}
    6       {% if user|has_permissions:dashboard %}
    7         <li class="openstack-dashboard">
    8           <a data-toggle="collapse"
    9              data-parent="#sidebar-drawer"
   10              data-target="#sidebar-drawer-{{ dashboard.slug }}"
   11              href="javascript:;"
   12              {% if current.slug != dashboard.slug %}
   13                class="collapsed"
   14              {% endif %}>
   15             {{ dashboard.name }}
   16             <span class="openstack-toggle pull-right fa"></span>
   17           </a>
   18           <ul id="sidebar-drawer-{{ dashboard.slug }}"
   19               class="nav collapse panel-collapse{% if current.slug == dashboard.slug %} in{% endif %}">
   20             {% for group, panels in panel_info.items %}
   21               {% with panels|has_permissions_on_list:user as filtered_panels %}
   22                 {% if filtered_panels %}
   23                   {% if group.name %}
   24                     <li class="nav-header">
   25                       <a data-toggle="collapse"
   26                          data-parent="#sidebar-drawer-{{ dashboard.slug }}"
   27                          data-target="#sidebar-drawer-{{ dashboard.slug }}-{{ group.slug }}"
   28                          href="javascript:;"
   29                          {% if current.slug == dashboard.slug and current_panel_group != group.slug %}class="collapsed"
   30                          {% elif current.slug != dashboard.slug and forloop.counter0 != 0 %}class="collapsed"{% endif %}>
   31                         <span class="nav-header-title">
   32                           {{ group.name }}
   33                           <span class="openstack-toggle fa pull-right"></span>
   34                         </span>
   35                       </a>
   36                       <ul id="sidebar-drawer-{{ dashboard.slug }}-{{ group.slug }}"
   37                           class="nav collapse panel-collapse
   38                           {% if current.slug == dashboard.slug and current_panel_group == group.slug %} in
   39                           {% elif current.slug != dashboard.slug and forloop.counter0 == 0 %} in{% endif %}">
   40                   {% endif %}
   41                   {% for panel in filtered_panels %}
   42                     <li class="openstack-panel">
   43                       <a class="openstack-spin {% if current.slug == dashboard.slug and current_panel == panel.slug %}active{% endif %}" href="{{ panel.get_absolute_url }}"
   44                          target="_self"
   45                          tabindex="{{ forloop.counter }}" >
   46                         {{ panel.name }}
   47                       </a>
   48                     </li>
   49                   {% endfor %}
   50                   {% if group.name %}
   51                       </ul>
   52                     </li>
   53                   {% endif %}
   54                 {% endif %}
   55               {% endwith %}
   56             {% endfor %}
   57           </ul>
   58         </li>
   59       {% endif %}
   60     {% endfor %}
   61   </ul>
   62 </div>