| 1 |
{% load static %}<html> |
| 2 |
<head> |
| 3 |
<title>Events</title> |
| 4 |
<link rel="stylesheet" type="text/css" href="{% static "css/table.css" %}" /> |
| 5 |
<style type="text/css"> |
| 6 |
body { |
| 7 |
font-family: sans-serif; |
| 8 |
font-size: 16px; |
| 9 |
margin: 50px; |
| 10 |
max-width: 1200px; |
| 11 |
} |
| 12 |
</style> |
| 13 |
|
| 14 |
|
| 15 |
</head> |
| 16 |
<body> |
| 17 |
<div id="title" style="text-align:center"> |
| 18 |
<h1>graphite events</h1> |
| 19 |
</div> |
| 20 |
<div class="graphite"> |
| 21 |
<div id="main" > |
| 22 |
{% if events %} |
| 23 |
<table class="styledtable" width=100%> |
| 24 |
<tr><th>when</th><th>what</th><th>tags</th></tr> |
| 25 |
{% for event in events %} |
| 26 |
<tr> |
| 27 |
<td>{{event.when|date:"H:i:s D d M Y" }}</td> |
| 28 |
<td><a href="{% url "events_detail" event.id %}">{{event.what}}</a></td> |
| 29 |
<td>['{{ event.tags|join:"', '"}}']</td> |
| 30 |
</tr> |
| 31 |
{% endfor %} |
| 32 |
{% else %} |
| 33 |
<br/>No events. Add events using |
| 34 |
<a href="{% url "admin:events_event_add" %}">the admin interface</a> or by posting |
| 35 |
(eg, curl -X POST {{ protocol }}://{{ site.domain }}{% url "events" %} -d |
| 36 |
'{"what": "Something Interesting", "tags" : "tag1"}') |
| 37 |
{% endif %} |
| 38 |
</table> |
| 39 |
</div> |
| 40 |
</div> |
| 41 |
</body> |
| 42 |
</html> |