Compare commits
2 Commits
23b9e5c001
...
c5f6122b63
Author | SHA1 | Date |
---|---|---|
Craig Oates | c5f6122b63 | 2 years ago |
Craig Oates | 2c4c9fa410 | 2 years ago |
12 changed files with 258 additions and 233 deletions
@ -0,0 +1,40 @@ |
|||||||
|
{% extends "layouts/app.html" %} |
||||||
|
{% block title %}{% lisp (title! "list of users") %}{% endblock %} |
||||||
|
{% block content %} |
||||||
|
<h1>{% lisp (title!) %}</h1> |
||||||
|
<form class="search" action="/user/search" accept-charset="UTF=8" method="get"> |
||||||
|
<input name="utf=8" type="hidden" value="v"/> |
||||||
|
<input type="text" name="q" id="q"/> |
||||||
|
<input type="submit" name="commit" value="search" data-disable-with="search"/> |
||||||
|
</form> |
||||||
|
<div class="toolbar"><a href="/user/new">Add a New User</a></div> |
||||||
|
{% if users %} |
||||||
|
<table class="list"> |
||||||
|
<thead> |
||||||
|
<tr> |
||||||
|
<th>Number</th> |
||||||
|
<th>Name</th> |
||||||
|
<th>Full Name</th> |
||||||
|
<th>Operation</th> |
||||||
|
</tr> |
||||||
|
</thead> |
||||||
|
<tbody> |
||||||
|
{% for user in users %} |
||||||
|
<tr> |
||||||
|
<td style="text-align: right">{{user.number}}</td> |
||||||
|
<td><a href="/users/{{user.id}}">{{user.name}}</a></td> |
||||||
|
<td>{{user.full-name}}</td> |
||||||
|
<td> |
||||||
|
<a href="/user/{{user.id}}/edit">Edit</a> | |
||||||
|
<a data-confirm="Really delete it?" |
||||||
|
rel="nofollow" data-method="delete" |
||||||
|
href="/user/{{user.id}}">Delete |
||||||
|
</a> |
||||||
|
</tr> |
||||||
|
{% endfor %} |
||||||
|
</tbody> |
||||||
|
</table> |
||||||
|
{% else %} |
||||||
|
<p>There are no accounts on this site.</p> |
||||||
|
{% endif %} |
||||||
|
{% endblock %} |
@ -0,0 +1,54 @@ |
|||||||
|
{% extends "layouts/app.html" %} |
||||||
|
{% block title %}{% lisp (title! "User detail") %}{% endblock %} |
||||||
|
{% block content %} |
||||||
|
<h1>{% lisp (title!) %}</h1> |
||||||
|
|
||||||
|
<div class="toolbar"><a href="/users/{{id}}/edit">Edit</a></div> |
||||||
|
|
||||||
|
<table class="attr"> |
||||||
|
<tr> |
||||||
|
<th width="150">Number</th> |
||||||
|
<td>{{user.number}}</td> |
||||||
|
</tr> |
||||||
|
<tr> |
||||||
|
<th>Name</th> |
||||||
|
<td>{{user.name}}</td> |
||||||
|
</tr> |
||||||
|
<tr> |
||||||
|
<th>Full name</th> |
||||||
|
<td>{{user.full-name}}</td> |
||||||
|
</tr> |
||||||
|
<tr> |
||||||
|
<th>Sex</th> |
||||||
|
<td> |
||||||
|
{% ifequal user.sex 1 %} |
||||||
|
Male |
||||||
|
{% else %} |
||||||
|
Female |
||||||
|
{% endifequal %} |
||||||
|
</td> |
||||||
|
</tr> |
||||||
|
<tr> |
||||||
|
<th>Birthday</th> |
||||||
|
<td> |
||||||
|
{{ user.birthday| |
||||||
|
lisp: local-time:timestamp-to-universal| |
||||||
|
date: ((:year 4)"/"(:month 2)"/"(:day 2)) }} |
||||||
|
</td> |
||||||
|
</tr> |
||||||
|
<tr> |
||||||
|
<th>Mail adress</th> |
||||||
|
<td>{{user.email}}</td> |
||||||
|
</tr> |
||||||
|
<tr> |
||||||
|
<th>administrator</th> |
||||||
|
<td> |
||||||
|
{% if user.administrator %} |
||||||
|
Yes |
||||||
|
{% else %} |
||||||
|
No |
||||||
|
{% endif %} |
||||||
|
</td> |
||||||
|
</tr> |
||||||
|
</table> |
||||||
|
{% endblock %} |
Loading…
Reference in new issue