Enhance filtering functionality and UI consistency across user-related views by implementing a generic search filter and updating filter display in templates.

This commit is contained in:
Ross
2025-11-03 10:47:40 +00:00
parent 2d0098b2b6
commit 83a60203f7
5 changed files with 63 additions and 39 deletions
+1 -12
View File
@@ -7,23 +7,12 @@
{% block content %}
<div id="view-filter-options">
<details class="filter">
<summary>
<h3>Filter CID Users </h3>
</summary>
<form action="" method="get">
{{ filter.form |crispy}}
<input class="btn btn-primary btn-sm mt-1 mb-1" type="submit" />
</form>
</details>
</div>
<div>
<span id="manage-span">
{% render_table table %}
</span>
</div>
{% include "generic/partials/filter_bar.html" with filter=filter app_name=app_name collapse_id="bottom-filter-body" %}
<details>
<summary>
+1 -12
View File
@@ -4,18 +4,6 @@
<h2>Supervisors</h2>
<details>
<summary>
<h4>Filter</h4>
</summary>
<div id="view-filter-options">
<form action="" method="get">
{{ filter.form }}
<input class="btn btn-primary btn-sm mt-1 mb-1" type="submit" />
</form>
</div>
</details>
{% render_table table %}
{% comment %} <ul id="supervisor-list">
@@ -25,6 +13,7 @@
</li>
{% endfor %}
</ul> {% endcomment %}
{% include "generic/partials/filter_bar.html" with filter=filter app_name=app_name collapse_id="bottom-filter-body" %}
{% endblock %}
+1
View File
@@ -71,6 +71,7 @@
{% render_table table %}
</span>
</div>
{% include "generic/partials/filter_bar.html" with filter=filter app_name=app_name collapse_id="bottom-filter-body" %}
<a href="{% url 'accounts_bulk_create' %}">Bulk create users</a>
<a href="{% url 'create_user' %}">Create single user</a>