-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🚸(dashboard) refactor consent management UI and remove unused features
Redesigned the consent management interface for improved clarity and usability. Removed the language switcher and English localization to focus only on French support. Added a dedicated contact email field, updated error pages with the email contact Refined consent-related views, templates and tests to reflect this changes. Added screenshots of the new UI.
- Loading branch information
Showing
25 changed files
with
431 additions
and
222 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
82 changes: 57 additions & 25 deletions
82
src/dashboard/apps/consent/templates/consent/includes/_consent_summary_awaiting.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 |
---|---|---|
@@ -1,30 +1,62 @@ | ||
{% load i18n %} | ||
|
||
{% if entities %} | ||
<strong>{% trans "Validated consent for all entities" %}</strong> | ||
<ul class="fr-links-group fr-mb-2w"> | ||
<li> | ||
<a class="fr-link fr-icon-arrow-right-line fr-link--icon-right" | ||
href="{% url "consent:manage" %}" | ||
data-fr-js-link-actionee="true"> | ||
{% trans "Validate content for all entities" %} | ||
</a> | ||
</li> | ||
</ul> | ||
<strong class="fr-mt-2w">Autoriser la DGEC à suivre vos unités d’exploitation</strong> | ||
|
||
<strong class="fr-mt-2w">{% trans "Validated consent entity by entity" %}</strong> | ||
<ul class="fr-links-group"> | ||
{% for entity in entities %} | ||
<li> | ||
<a class="fr-link fr-icon-arrow-right-line fr-link--icon-right" | ||
href="{% url "consent:manage" entity.slug %}" | ||
data-fr-js-link-actionee="true"> | ||
{{ entity.name }} : | ||
{% blocktranslate with consent_total=entity.get_consents.count entity_count=entity.count_awaiting_consents pluralize=entity.count_awaiting_consents|pluralize %} | ||
{{ entity_count }}/{{ consent_total }} consent{{ pluralize }} to validate | ||
{% endblocktranslate %} | ||
</a> | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
<div class="fr-table fr-table--no-caption fr-table--bordered"> | ||
<div class="fr-table__wrapper"> | ||
<div class="fr-table__container"> | ||
<div class="fr-table__content"> | ||
|
||
<table> | ||
<caption>Autoriser la DGEC à suivre vos unités d’exploitation</caption> | ||
<thead> | ||
<tr> | ||
<th> | ||
<div class="fr-cell__title">Unités d’exploitation</div> | ||
</th> | ||
<th> | ||
<div class="fr-cell__title fr-cell--center"> | ||
Nombre de points de livraison en attente | ||
</div> | ||
</th> | ||
<th> | ||
<div class="fr-cell__title fr-cell--center"> | ||
Action | ||
</div> | ||
</th> | ||
</tr> | ||
</thead> | ||
<tbody> | ||
{% for entity in entities %} | ||
{% if entity.count_awaiting_consents %} | ||
<tr id="undefined-row-key-{{ forloop.counter }}" data-row-key="forloop.counter"> | ||
<td> | ||
{# todo: change entity.name with the "unité fonctionnel" id#} | ||
<p>{{ entity.name }}</p> | ||
</td> | ||
<td class="fr-cell--center"> | ||
<p class="fr-badge fr-badge--new"> | ||
{% with consent_total=entity.get_consents.count entity_count=entity.count_awaiting_consents pluralize=entity.count_awaiting_consents|pluralize %} | ||
{{ entity_count }} PDL en attente sur {{ consent_total }} | ||
{% endwith %} | ||
</p> | ||
</td> | ||
<td class="fr-cell--center"> | ||
<a class="fr-link fr-icon-arrow-right-line fr-link--icon-right" | ||
href="{% url "consent:manage" entity.slug %}" | ||
data-fr-js-link-actionee="true"> | ||
Gérer les autorisations | ||
</a> | ||
</td> | ||
</tr> | ||
{% endif %} | ||
{% endfor %} | ||
</tbody> | ||
</table> | ||
|
||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
{% endif %} |
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
68 changes: 58 additions & 10 deletions
68
src/dashboard/apps/consent/templates/consent/includes/_consent_summary_validated.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 |
---|---|---|
@@ -1,14 +1,62 @@ | ||
{% load i18n %} | ||
|
||
{% if entities %} | ||
<ul class="fr-links-group"> | ||
{% for entity in entities %} | ||
<li> | ||
{{ entity.name }}: | ||
{% blocktranslate with consent_total=entity.get_consents.count consent_count=entity.count_validated_consents pluralize=entity.count_validated_consents|pluralize %} | ||
{{ consent_count }}/{{ consent_total }} consent{{ pluralize }} validated | ||
{% endblocktranslate %} | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
<div class="fr-table fr-table--no-caption fr-table--bordered"> | ||
<div class="fr-table__wrapper"> | ||
<div class="fr-table__container"> | ||
<div class="fr-table__content"> | ||
|
||
<table> | ||
<caption>Stations suivies</caption> | ||
|
||
<thead> | ||
<tr> | ||
<th scope="col"> | ||
<div class="fr-cell__title">Unités d’exploitation</div> | ||
</th> | ||
<th scope="col"> | ||
<div class="fr-cell__title fr-cell--center"> | ||
Nombre de points de livraison suivis | ||
</div> | ||
</th> | ||
<th scope="col"> | ||
<div class="fr-cell__title fr-cell--center"> | ||
Consulter la liste | ||
</div> | ||
</th> | ||
</tr> | ||
</thead> | ||
|
||
<tbody> | ||
{% for entity in entities %} | ||
{% if entity.count_validated_consents %} | ||
<tr id="undefined-row-key-{{ forloop.counter }}" data-row-key="forloop.counter"> | ||
<td> | ||
{# todo: change entity.name with the "unité fonctionnel" id#} | ||
<p>{{ entity.name }}</p> | ||
</td> | ||
<td class="fr-cell--center"> | ||
<p class="fr-badge fr-badge--success"> | ||
{% with consent_total=entity.get_consents.count consent_count=entity.count_validated_consents pluralize=entity.count_validated_consents|pluralize %} | ||
{{ consent_count }} PDL suivi{{ pluralize }} | ||
{% endwith %} | ||
</p> | ||
</td> | ||
<td class="fr-cell--center"> | ||
<a class="fr-link fr-icon-arrow-right-line fr-link--icon-right" | ||
href="{% url "consent:manage" entity.slug %}" | ||
data-fr-js-link-actionee="true"> | ||
Consulter la liste | ||
</a> | ||
</td> | ||
</tr> | ||
{% endif %} | ||
{% endfor %} | ||
</tbody> | ||
</table> | ||
|
||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
{% endif %} |
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
Oops, something went wrong.