{% extends 'base.html' %}
{% load custom_tags_and_filters %}
{% block content %}
    <div id="knowledge-base-tabs" class="clearfix">
        <h1 class="knowledge-base-title pull-left">
            {% block knowledge_base_title %}Knowledge base{% endblock %}
        </h1>
        {% if user.is_any_part_of_staff %}
            <ul class="nav nav-pills nav-pills-spacer knowledge-base-tabs-nav" id="tabs">
                <li class="{% if kind == 'user' %}active{% endif %}">
                    <a href="#knowledge-base" onclick="location.href = '{% url "knowledge_base" "user" %}'">User</a>
                </li>
                <li class="{% if kind == 'staff' %}active{% endif %}">
                    <a href="#knowledge-base" onclick="location.href = '{% url "knowledge_base" "staff" %}'">Staff</a>
                </li>
            </ul>
        {% endif %}
    </div>
    <div class="tab-content">
        <div class="tab-pane active" id="knowledge-base">
            {% block tab_content %}{% endblock %}
        </div>
    </div>
    <script>$("#tabs").find("a").click(switch_tab);</script>
{% endblock %}
