{% extends "base.html" %}
{% block title %}Logs{% endblock %}
{% block content %}
<h2>Logs</h2>
<script type="text/javascript">
$("document").ready(function() {$(".dump").hide();});
</script>
<table border="1">
<tr><th>timestamp</th><th>user</th><th>action</th><th>dump</th></tr>
{% for log in logs %}
<tr>
<td>{{ log.creation_time }}</td>
<td>{{ log.username }}</td>
<td>{{ log.action }}</td>
<td width="60%">
{% if log.dump %}
<a href='javascript:void(0)' onclick='javascript:$("#log_{{ log.id }}").toggle();'>show details</a>
<p id='log_{{ log.id }}' class='dump'>
{{ log.dump }}
</p>
{% endif %}
</td>
</tr>
{% endfor %}
</table>

{% endblock %}
