]> git.ozlabs.org Git - patchwork/blob - templates/base.html
templates: Pull jquery into base.html
[patchwork] / templates / base.html
1 {% load staticfiles %}
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
3  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
4 <html xmlns="http://www.w3.org/1999/xhtml">
5  <head>
6   <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
7   <title>{% block title %}Patchwork{% endblock %} - Patchwork</title>
8   <link rel="stylesheet" type="text/css" href="{% static "css/style.css" %}"/>
9   <script type="text/javascript" src="{% static "js/common.js" %}"></script>
10   <script type="text/javascript" src="{% static "js/jquery-1.10.1.min.js" %}"></script>
11 {% block headers %}{% endblock %}
12  </head>
13  <body>
14   <div id="title">
15   <h1 style="float: left;">
16      <a
17       href="{% url 'patchwork.views.projects' %}">Patchwork</a>
18     {% block heading %}{% endblock %}</h1>
19   <div id="auth">
20 {% if user.is_authenticated %}
21    Logged in as
22     <a href="{% url 'patchwork.views.user.profile' %}"
23      ><strong>{{ user.username }}</strong></a>
24     <br/>
25      <a href="{% url 'patchwork.views.user.todo_lists' %}">todo
26       ({{ user.profile.n_todo_patches }})</a> ::
27      <a href="{% url 'patchwork.views.bundle.bundles' %}">bundles</a>
28      <br/>
29      <a href="{% url 'patchwork.views.user.profile' %}">profile</a> ::
30 {% if user.is_staff %}
31      <a href="{% url 'admin:index' %}">admin</a> ::
32 {% endif %}
33      <a href="{% url 'auth_logout' %}">logout</a>
34 {% else %}
35      <a href="{% url 'auth_login' %}">login</a>
36      <br/>
37      <a href="{% url 'patchwork.views.user.register' %}">register</a>
38      <br/>
39      <a href="{% url 'patchwork.views.mail.settings' %}">mail settings</a>
40 {% endif %}
41    </div>
42    <div style="clear: both;"></div>
43   </div>
44   <div id="nav">
45    <div id="navleft">
46    {% if project %}
47     <strong>Project</strong>: {{ project.linkname }}
48      :
49      <a href="{% url 'patchwork.views.patch.list' project_id=project.linkname %}"
50       >patches</a>
51      :
52      <a href="{% url 'patchwork.views.project.project' project_id=project.linkname %}"
53       >project info</a>
54     {% if other_projects %}
55      :
56      <a href="{% url 'patchwork.views.projects' %}"
57      >other projects</a>
58      {% endif %}
59     {% else %}
60      <a href="{% url 'patchwork.views.projects' %}"
61      >project list</a>
62     {% endif %}
63    </div>
64    <div id="navright">
65     <a href="{% url 'patchwork.views.help' path="about/" %}">about</a>
66    </div>
67    <div style="clear: both"></div>
68   </div>
69 {% if messages %}
70   <div id="messages">
71   {% for message in messages %}
72    <div class="message">{{ message }}</div>
73   {% endfor %}
74   </div>
75 {% endif %}
76   <div id="content">
77 {% block body %}
78 {% endblock %}
79   </div>
80   <div id="footer">
81    <a href="http://jk.ozlabs.org/projects/patchwork/">patchwork</a>
82    patch tracking system
83   </div>
84  </body>
85 </html>
86
87
88