aboutsummaryrefslogtreecommitdiffstats
path: root/templates/base.html
blob: b13428433eb25caaa815fc8c83cbc6ad160d8b96 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
{% comment %}

Error reporting tool - base template for output pages

Copyright (C) 2013 Intel Corporation
Licensed under the MIT license, see COPYING.MIT for details

{% endcomment %}
{% load i18n %}
{% load staticfiles %}
<!DOCTYPE html>
<html>
  <head>
    <link rel="stylesheet" href="{% static "css/bootstrap.min.css" %}" />
    <link rel="stylesheet" href="{% static "css/nv.d3.css" %}" />
    <link rel="stylesheet" href="{% static "css/bootstrap-responsive.css" %}" />
    <link rel="stylesheet" href="{% static "css/custom.css" %}" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <script type = "text/javascript" src = "{% static "js/jquery.js" %}"></script>
    <script type = "text/javascript" src = "{% static "js/bootstrap.min.js" %}"></script>
    <script type = "text/javascript" src = "{% static "js/d3.v2.js" %}"></script>
    <script type = "text/javascript" src = "{% static "js/nv.d3.js" %}"></script>
    <script type = "text/javascript" src = "{% static "js/jquery.cookie.js" %}"></script>
    <script type="text/javascript" src="{% static "js/main.js" %}"></script>
  </head>
  <body>
    <div class="navbar navbar-fixed-top">
      <div class="navbar-inner">
        <div class="container-fluid">
          <a class="brand logo" href="{% url "main" %}"><img src="{% static "img/logo.png" %}" /></a>
          <a class="brand" href="{% url "main" %}">Error reports</a>
          {% comment %}
          {% if  user.is_authenticated %}
          <div class="dropdown pull-right">
            <a class="btn dropdown-toggle" data-toggle="dropdown" href="#">
              <i class="icon-user"></i>{{ user.username }}
              <b class="caret pull-right"></b>
            </a>
            <ul class="dropdown-menu" role="menu" aria-labelledby="dLabel">
              <li><a tabindex="-1" href="{% url "auth_password_change" %}">{% trans "Change password" %}</a></li>
              <li><a tabindex="-1" href="{% url "auth_logout" %}">{% trans "Log out" %}</a></li>
            </ul>
          </div>
          {% endif %}
          {% if not user.is_authenticated %}
          <ul class="nav pull-right">
            <li>
              <a href="{% url "auth_login" %}">{% trans "log in" %}</a>
            </li>
          </ul>
          {% endif %}
          {% endcomment %}
          <form class="navbar-search pull-right" action="{% url "errors_search" %}" method="GET">
            <div class="input-append">
              <input type="text" name="query" class="span5" placeholder="Search all errors" value="{{request.GET.query}}">
                    <button type="submit" value="Search" class="btn btn-info">Search</button>
                  </div>
                </form>
              </div>
            </div>
          </div>
          {% url "latest_errors" as latest_errors_url %}
          {% url "latest_autobuilder_errors" as latest_special_errors_url %}
          {% url "statistics" as stats_url %}
          {% url "search" as search_url %}
          {% url "build" as build_url %}

          <div class="row-fluid">
            {# Don't show navigation on the search or build page or details page #}
            {% if mode != results_mode.BUILD and mode != results_mode.SEARCH and not details %}
            <ul class="nav nav-pills">

              {% if special_submitter %}
              <li {% if request.path  == latest_special_errors_url %}class="active"{% endif %}>
                  <a href="{{latest_special_errors_url}}" title="{{special_submitter.title}}">Latest {{special_submitter.title}} errors</a>
              </li>
              {% endif %}

              <li {% if request.path == latest_errors_url %}class="active" {%endif%}>
                <a href="{{latest_errors_url}}">Latest errors</a>
              </li>

              <li {% if request.path  == stats_url %}class="active"{% endif %}>
                <a href="{{stats_url}}">Statistics</a>
              </li>
            </ul>
       {% endif %}

            {% block content %}{% endblock %}
          </body>
        </html>