-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: update employee record list filters ui
- Loading branch information
1 parent
e871d52
commit 641cbb5
Showing
11 changed files
with
109 additions
and
68 deletions.
There are no files selected for viewing
12 changes: 12 additions & 0 deletions
12
itou/templates/employee_record/includes/employee_record_filters/reset.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{% load str_filters %} | ||
|
||
<div class="ms-md-auto" id="employee-record-filter-counter"{% if request.htmx %} hx-swap-oob="true"{% endif %}> | ||
{% if filters_counter > 0 %} | ||
<a href="{% url 'employee_record_views:list' %}" | ||
class="btn btn-ico btn-dropdown-filter" | ||
aria-label="Réinitialiser le{{ filters_counter|pluralizefr }} filtre{{ filters_counter|pluralizefr }} actif{{ filters_counter|pluralizefr }}"> | ||
<i class="ri-eraser-line font-weight-bold" aria-hidden="true"></i> | ||
<span>Effacer tout</span> | ||
</a> | ||
{% endif %} | ||
</div> |
24 changes: 24 additions & 0 deletions
24
itou/templates/employee_record/includes/employee_record_filters/status.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
{% load list_filters %} | ||
|
||
<div id="employee-records-list-filters" {% if request.htmx %}hx-swap-oob="true"{% endif %}> | ||
<div class="dropdown"> | ||
<button type="button" class="btn btn-dropdown-filter dropdown-toggle" data-bs-toggle="dropdown" data-bs-auto-close="outside" aria-expanded="false"> | ||
Statut | ||
</button> | ||
<ul class="dropdown-menu"> | ||
{% for choice, badge in form.status|zip:badges %} | ||
<li> | ||
<div class="dropdown-item"> | ||
<div class="form-check"> | ||
<input class="form-check-input" type="radio" name="{{ choice.data.name }}" id="{{ choice.id_for_label }}" value="{{ choice.data.value }}"{% if choice.data.selected %} checked="checked"{% endif %}> | ||
<label class="form-check-label" for="{{ choice.id_for_label }}"> | ||
{{ choice.data.label }} | ||
{% if badge.0 > 0 %}<span class="badge rounded-pill badge-xs {{ badge.1 }}">{{ badge.0 }}</span>{% endif %} | ||
</label> | ||
</div> | ||
</div> | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{% load str_filters %} | ||
|
||
{% with navigation_pages.paginator.count as counter %} | ||
<h3 class="h4 m-0 me-auto" id="employee-record-list-count"{% if request.htmx %} hx-swap-oob="true"{% endif %}> | ||
{{ counter }} résultat{{ counter|pluralizefr }} | ||
</h3> | ||
{% endwith %} |
21 changes: 0 additions & 21 deletions
21
itou/templates/employee_record/includes/list_form_fields.html
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<div> | ||
<span class="fs-sm">Trier par :</span> | ||
<button type="button" class="btn btn-sm btn-link dropdown-toggle p-0" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> | ||
{{ ordered_by_label }} | ||
</button> | ||
<div class="dropdown-menu dropdown-menu-end" id="order-form-group"> | ||
{% for order_value, order_label in form.order.field.choices %} | ||
<button class="dropdown-item {% if order_value == form.order.value %}active{% endif %}" type="button" value="{{ order_value }}"> | ||
{{ order_label }} | ||
</button> | ||
{% endfor %} | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters