
{% block submenu_dashboard %}

  <h1>{{ rstate|capitalize }} {{ table_title }}</h1>

    <div class="row">
             <div class="container" id="dashboard-nav">
                 <div class="col-md-6">
                     <ul class="nav nav-pills">
                         {% for key, item in dashboard.items() %}
                            <li class="nav-item">
                                <a class="nav-link {{ css_classes[key] }}" href="{{ url_for('dashboard.index', rtype=key, rstate=rstate) }}" >
                                {{ item.name }} 
                                {% if count_match %}
                                    ({{ count_match[key] }})
                                {% endif %}
                                </a>
                            </li>
                        {% endfor %} 
                     </ul>
                 </div>
                 <div class="col-md-6">
                     <ul class="nav nav-pills pull-right">
                         <li>
                             <form class="navbar-form pull-right" role="search" action="{{ url_for('dashboard.index', rtype=rtype, rstate=rstate) }}">
                                <div class="input-group">
                                    <input
                                        class="form-control"
                                        type="text"
                                        name="squery"
                                        {% if search_query %}
                                            value="{{search_query}}"
                                        {% else %}
                                            placeholder="Search..."
                                        {% endif %}
                                    />
                                    <input
                                        type="hidden"
                                        name="sort"
                                        value={{ sort_key }}
                                    />
                                    <input
                                        type="hidden"
                                        name="order"
                                        value={{ sort_order }}
                                    />
                                    <div class="input-group-btn">
                                        <button class="btn btn-default"><i class="glyphicon glyphicon-search"></i></button>
                                    </div>
                                </div>
                            </form>
                         </li>
                     </ul>
                 </div>
    </div>
    <hr />

{% endblock %}