~james-w/python-oops-tools/prod-deploy

« back to all changes in this revision

Viewing changes to src/oopstools/oops/templates/report.html

  • Committer: Tarmac
  • Author(s): James Westby
  • Date: 2012-12-05 05:01:01 UTC
  • mfrom: (48.1.4 recent-oopses)
  • Revision ID: launchpad@pqm.canonical.com-20121205050101-0xdbbnecsgyrlsne
Show the (paginated) oopses for each report.

Show diffs side-by-side

added added

removed removed

Lines of Context:
13
13
      <li><a href="{{SUMMARY_URI}}/{{report.name}}-{{date|date:"Y-m-d"}}.html">{{report.title}} {{date|date:"Y-m-d"}}</a></li>
14
14
    {% endfor %}
15
15
    <ul>
 
16
    <h2>Recent Oopses</h2>
 
17
    <table>
 
18
        <th><tr>
 
19
            <td>Date/Time</td>
 
20
            <td>HTTP Method</td>
 
21
            <td>URL</td>
 
22
            <td>Duration (ms)</td>
 
23
            <td>Exception Type</td>
 
24
            <td>Oops</td>
 
25
        </tr></th>
 
26
        {% for oops in recent.object_list %}
 
27
        <tr>
 
28
            <td>{{oops.date|date:"Y-m-d H:i:s"}}</td>
 
29
            <td>{{oops.http_method}}</td>
 
30
            <td>{% if oops.url %}<a href="{{oops.url}}">{{oops.url}}</a>{% endif %}</td>
 
31
            <td>{{oops.total_time}}</td>
 
32
            <td>{{oops.exception_type}}</td>
 
33
            <td><a href="{% url oopstools.oops.views.index %}?oopsid={{oops.oopsid}}">{{oops.oopsid}}</a></td>
 
34
        </tr>
 
35
        {% endfor %}
 
36
    </table>
 
37
    <div class="pagination">
 
38
        <span class="step-links">
 
39
            {% if recent.has_previous %}
 
40
            <a href="?page={{ recent.previous_page_number }}">newer</a>
 
41
            {% endif %}
 
42
 
 
43
            <span class="current">
 
44
                Page {{ recent.number }} of {{ recent.paginator.num_pages }}.
 
45
            </span>
 
46
 
 
47
            {% if recent.has_next %}
 
48
            <a href="?page={{ recent.next_page_number }}">older</a>
 
49
            {% endif %}
 
50
        </span>
 
51
    </div>
16
52
  </body>
17
53
</html>