added users page that lists all registered users.

this required more js to make the table pretty.
This commit is contained in:
2015-07-10 11:19:59 +01:00
parent 6fe43294e9
commit f1972a9738
10 changed files with 1711 additions and 5 deletions

View File

@@ -13,7 +13,7 @@
<!-- Bootstrap core CSS -->
<link href="/static/css/bootstrap.min.css" rel="stylesheet">
<link href="/static/css/jasny-bootstrap.min.css" rel="stylesheet" media="screen">
<!-- Custom styles for this template -->
<link href="/static/css/base.css" rel="stylesheet">
@@ -68,6 +68,8 @@
<!-- Placed at the end of the document so the pages load faster -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
<script src="/static/js/bootstrap.min.js"></script>
<script src="/static/js/jasny-bootstrap.min.js"></script>
{% block script %}
{% endblock %}
</body>
</html>

View File

@@ -0,0 +1,31 @@
{% extends "base.html" %}
{% block title %}CBreader - Users{% endblock %}
{% block content %}
<table class="table table-striped table-bordered table-hover">
<thead>
<tr>
<th>#</th>
<th>Username</th>
<th>Email</th>
<th>Superuser</th>
</tr>
</thead>
<tbody data-link="row" class="rowlink">
{% for user in users %}
<tr>
<td><a href="{{user.id}}/">{{user.id}}</a></td>
<td>{{user.username}}</td>
<td>{{user.email}}</td>
<td>{{user.is_superuser}}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endblock %}
{% block script %}
{% endblock %}