{% load static %}
{% load extra_filters %}

<!DOCTYPE html>
<html class="{% block html_class%}{% endblock %}" lang="en">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">

	<title>Kiwi TCMS {% block subtitle %}the leading open source test case management system{% endblock %}</title>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
	<meta http-equiv="Content-Language" content="utf-8" />

    <link rel="shortcut icon" href="{% static 'images/favicon.ico' %}" type='image/x-icon'>
	<link rel="stylesheet" type="text/css" href="{% static 'style/jquery/ui/cupertino/jquery-ui-1.8.20.css' %}" />
	<link rel="stylesheet" type="text/css" href="{% static 'style/base.css' %}" media="screen" />
	<link rel="stylesheet" type="text/css" href="{% static 'style/print.css' %}" media="print" />
	{% block custom_stylesheet %}{% endblock %}

        <!-- jQuery, jQuery-UI for Grappelli -->
        <script src="{% static "grappelli/jquery/jquery.min.js" %}" type="text/javascript"></script>
        <script src="{% static "grappelli/jquery/ui/jquery-ui.min.js" %}" type="text/javascript"></script>
        <!-- Grappelli Minified -->
        <script src="{% static "grappelli/js/grappelli.min.js" %}" type="text/javascript"></script>

	<script type="text/javascript" src="{% static 'js/lib/jquery-1.7.2.min.js' %}"></script>
	<script type="text/javascript" src="{% static 'js/lib/jquery-ui-1.8.20.min.js' %}"></script>
	<script type="text/javascript" src="{% static 'js/lib/handlebars-1.3.0.min.js' %}"></script>
	<script type="text/javascript" language="javascript" charset="utf-8">
		jQuery.noConflict();
		var jQ = jQuery.noConflict();
		// Top level namespace
		window.Nitrate = {};
	</script>
	<script type="text/javascript" src="{% static 'js/tcms_actions.js' %}"></script>

	{% block custom_javascript %}{% endblock %}
	<script type="text/javascript">
	{% if request.user.is_authenticated %}
	Nitrate.User = {
		pk: {{ request.user.pk }},
		username: '{{ request.user.username }}',
	};
	{% else %}
	Nitrate.User = {
		pk: null,
		username: 'anonymous',
	};
	{% endif %}
	</script>
		{% block extra_head %}{% endblock %}
</head>
<body id="body">
    <iframe src="{% url 'iframe-navigation' %}" width="100%" height="195px" scrolling="no" frameBorder="0"></iframe>

    {% for message in messages %}
        <div class="alert alert-{{ message.tags }} alert-dismissable">
            <button type="button" class="close" data-dismiss="alert" aria-label="Close">
                <span class="pficon pficon-close"></span>
            </button>
            <span class="pficon {{ message|message_icon }}"></span>
            <strong>{{ message|safe }}!</strong>
        </div>
    {% endfor %}

    {% block contents %}{% endblock %}
    <div id="dialog" style="display:none"><div class="ajax_loading"></div></div>
</body>
</html>
