From 45c6978bc397691b22db0360b16b19979eac7dce Mon Sep 17 00:00:00 2001 From: Andrew Godwin Date: Fri, 16 Dec 2022 16:38:52 -0700 Subject: User admin and LD schema fixes --- templates/admin/user_edit.html | 36 ++++++++++++++++++++++++++++++++++++ templates/admin/users.html | 39 ++++++++++++++++++++++++++++++++++++--- 2 files changed, 72 insertions(+), 3 deletions(-) create mode 100644 templates/admin/user_edit.html (limited to 'templates/admin') diff --git a/templates/admin/user_edit.html b/templates/admin/user_edit.html new file mode 100644 index 0000000..b795848 --- /dev/null +++ b/templates/admin/user_edit.html @@ -0,0 +1,36 @@ +{% extends "settings/base.html" %} + +{% block subtitle %}{{ user.email }}{% endblock %} + +{% block content %} +

{{ editing_user.email }}

+
+ {% csrf_token %} +
+ Permissions + {% include "forms/_field.html" with field=form.status %} + {% if same_user %} + + {% endif %} +
+
+ Identities + {% for identity in editing_user.identities.all %} + {% include "activities/_identity.html" %} + {% empty %} +

This user has no identities yet.

+ {% endfor %} +
+
+ Dates +

Last seen:

+

Created:

+
+
+ Back + +
+
+{% endblock %} diff --git a/templates/admin/users.html b/templates/admin/users.html index f2dc864..1bf5b2e 100644 --- a/templates/admin/users.html +++ b/templates/admin/users.html @@ -3,7 +3,40 @@ {% block subtitle %}Users{% endblock %} {% block content %} -

- Please use the Django Admin for now. -

+ +
+ {% for user in page_obj %} + + + + {{ user.email }} + + {{ user.num_identities }} identit{{ user.num_identities|pluralize:"y,ies" }} + + + {% if user.banned %} + Banned + {% endif %} + + {% empty %} +

+ {% if query %} + No users match your query. + {% else %} + There are no users yet. + {% endif %} +

+ {% endfor %} +
+ {% if page_obj.has_previous %} + Previous Page + {% endif %} + {% if page_obj.has_next %} + Next Page + {% endif %} +
+
{% endblock %} -- cgit v1.2.3