aboutsummaryrefslogtreecommitdiffstats
path: root/alphabetlearning/templates/resources
diff options
context:
space:
mode:
authorMatthew Lemon <y@yulqen.org>2024-10-21 21:25:22 +0100
committerMatthew Lemon <y@yulqen.org>2024-10-21 21:25:22 +0100
commita6a5a0ef97efd5eabdc65a7f78adb670b0350269 (patch)
tree85e4b8fdd50424ac628d85c45f45845f94876d87 /alphabetlearning/templates/resources
parent886aca24778b72edd89726c90783f8c32438db2c (diff)
wip: still working on the resource index page
Diffstat (limited to '')
-rw-r--r--alphabetlearning/templates/resources/admin_bar.html29
-rw-r--r--alphabetlearning/templates/resources/resource_list.html6
2 files changed, 10 insertions, 25 deletions
diff --git a/alphabetlearning/templates/resources/admin_bar.html b/alphabetlearning/templates/resources/admin_bar.html
index be49e65..6d7b4b6 100644
--- a/alphabetlearning/templates/resources/admin_bar.html
+++ b/alphabetlearning/templates/resources/admin_bar.html
@@ -1,21 +1,8 @@
- {# admin block #}
- {% if request.user.is_authenticated and request.user.is_staff %}
- <div>
- <h5>Admin bar</h5>
- <p>
- Only you will see this bar - normal users will not see it. It allows us to
- include buttons for adding new resources, etc.
- </p>
- <div>
- <a href="{% url 'resources:create_resource' %}">Add a new resource</a>
- <div>
- Logged in as
- <strong>{{ request.user.email }}</strong>
- </div>
- <form action="{% url 'account_logout' %}" method="post" class="my-2">
- {% csrf_token %}
- <button type="submit">Log out</button>
- </form>
- </div>
- </div>
- {% endif %}
+{# admin block #}
+{% if request.user.is_authenticated and request.user.is_staff %}
+<h1>Admin</h1>
+<p> (this is not visible to customers!)</p>
+<div>
+ <a href="{% url 'resources:create_resource' %}">Add a new resource</a>
+</div>
+{% endif %}
diff --git a/alphabetlearning/templates/resources/resource_list.html b/alphabetlearning/templates/resources/resource_list.html
index bb32d90..a6e2a5d 100644
--- a/alphabetlearning/templates/resources/resource_list.html
+++ b/alphabetlearning/templates/resources/resource_list.html
@@ -6,7 +6,7 @@ Alphabet Learning - Resource List
{% endblock title %}
{% block content %}
<div class="container">
- <div>
+ <div class="admin-box">
{% include "resources/admin_bar.html" %}
</div>
@@ -35,9 +35,7 @@ Alphabet Learning - Resource List
{# standard resources #}
<div>
- <div>
- <h1>Standard resources</h1>
- </div>
+ <h1>Standard resources</h1>
</div>
<!-- Tabbed navigation bar for filtering -->