base.html 5.03 KB
Newer Older
1 2 3 4 5 6 7
{% load i18n %}<!DOCTYPE html>
<html lang="{{lang}}">
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="">
Kálmán Viktor committed
8
    <link rel="icon" type="image/png" href="{{ STATIC_URL}}dashboard/img/favicon.png"/>
9

10
    <title>{% block title %}{% block title-page %}{% endblock %} | {% block title-site %}CIRCLE{% endblock %}{% endblock %}</title>
11 12 13 14 15 16 17 18 19 20

    <script src="//code.jquery.com/jquery-1.10.2.min.js"></script>
    <script src="//code.jquery.com/jquery-migrate-1.2.1.min.js"></script>
    <link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css">
    <script src="//netdna.bootstrapcdn.com/bootstrap/3.0.0/js/bootstrap.min.js"></script>
    <link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap-theme.min.css">
    <link href="//netdna.bootstrapcdn.com/font-awesome/3.2.1/css/font-awesome.css" rel="stylesheet">
    <script src="{{ STATIC_URL }}dashboard/js/jquery.knob.js"></script>
    <script src="{{ STATIC_URL}}dashboard/bootstrap-slider/bootstrap-slider.js"></script>
    <link rel="stylesheet" href="{{ STATIC_URL }}dashboard/bootstrap-slider/slider.css"/>
21
    <link href="{{ STATIC_URL }}dashboard/bootstrap-tour.min.css" rel="stylesheet">
22 23
    <link href="{{ STATIC_URL }}dashboard/dashboard.css" rel="stylesheet">
    <script src="{{ STATIC_URL }}dashboard/dashboard.js"></script>
24
    <script src="{{ STATIC_URL }}jsi18n/{{ LANGUAGE_CODE }}/djangojs.js"></script>
25 26 27 28
  </head>

  <body>
    <div class="navbar navbar-inverse navbar-fixed-top">
29
        <div class="navbar-header">  
Kálmán Viktor committed
30 31 32
          <a class="navbar-brand" href="{% url "dashboard.index" %}" style="padding: 10px 15px;">
            <img src="{{ STATIC_URL}}dashboard/img/logo.png" style="height: 25px;"/>
          </a>
33 34 35 36 37 38 39 40 41 42
            <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
            </button>
        </div><!-- .navbar-header -->
        <div class="collapse navbar-collapse">
          <ul class="nav navbar-nav pull-right">
            <li class="dropdown" id="notification-button">                            
              <a href="{% url "dashboard.views.notifications" %}" style="color: white; font-size: 12px;" class="dropdown-toggle" data-toggle="dropdown">
43
                {% trans "Notifications" %}{% if NEW_NOTIFICATIONS_COUNT > 0 %} <span class="badge badge-pulse">{{ NEW_NOTIFICATIONS_COUNT }}</span>{% endif %}
44 45 46 47 48 49 50 51
              </a>                                                                    
              <ul class="dropdown-menu notification-messages">                        
                  <li>{% trans "Loading..." %}</li>                                   
              </ul>                                                                   
            </li>               
          </ul>
          {% if user.is_authenticated %}
            <a class="navbar-brand pull-right" href="{% url "logout" %}?next={% url "login" %}" style="color: white; font-size: 10px;"><i class="icon-signout icon-sign-out"></i> {% trans "Log out" %}</a>
52
            <a class="navbar-brand pull-right" href="{% url "dashboard.views.profile" pk=user.pk %}" title="{% trans "User profile" %}" style="color: white; font-size: 10px;"><i class="icon-user "></i> {{user}}</a>
53 54 55 56 57 58 59 60 61
            {% if user.is_superuser %}
              <a class="navbar-brand pull-right" href="/network/" style="color: white; font-size: 10px;"><i class="icon-globe"></i> {% trans "Network" %}</a>
              <a class="navbar-brand pull-right" href="/admin/" style="color: white; font-size: 10px;"><i class="icon-cogs"></i> {% trans "Admin" %}</a>
            {% endif %}
          {% else %}
            <a class="navbar-brand pull-right" href="{% url "login" %}?next={% url "dashboard.index" %}" style="color: white; font-size: 10px;"><i class="icon-sign-in"></i> {% trans "Log in " %}</a>
          {% endif %}
        </div><!-- .collapse .navbar-collapse -->
    </div><!-- navbar navbar-inverse navbar-fixed-top -->
62 63

    <div class="container">
64 65 66 67 68 69 70 71 72 73 74 75 76 77 78
      {% block messages %}
      <div class="messagelist">
      {% if messages %}
      {% for message in messages %}
      <div class="alert
          {% if message.tags %} alert-{% if message.tags == "error" %}danger{% else %}{{ message.tags }}{% endif %}{% endif %}">
          {{ message|safe }}
      </div>
      {% endfor %}
      {% endif %}
      </div>
      {% endblock messages %}
      {% block content %}
        <h1 class="alert alert-error">Please override "content" block.</h1>
      {% endblock %}
79
    </div> <!-- /container -->
80 81 82 83 84
    <footer>
      <a href="#">{% trans "Legal notice" %}</a> | <a href="#">{% trans "Policy" %}</a> | <a href="#">{% trans "Help" %}</a> |
      <a href="#">{% trans "Support" %}</a>
      <span class="pull-right">{{ COMPANY_NAME }}</span>
    </footer>
85 86 87 88
  </body>
{% block extra_js %}
{% endblock %}
</html>