-
Notifications
You must be signed in to change notification settings - Fork 91
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #10627 from demarches-simplifiees/simplify-tabs-su…
…pprimes-ldu [UX] Simplifier l'interface avec un onglet unique pour les dossiers supprimés
- Loading branch information
Showing
40 changed files
with
205 additions
and
204 deletions.
There are no files selected for viewing
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,11 @@ | ||
class Dossiers::DeletedDossiersComponent < ApplicationComponent | ||
include DossierHelper | ||
|
||
def initialize(deleted_dossiers:) | ||
@deleted_dossiers = deleted_dossiers | ||
end | ||
|
||
def role | ||
controller.try(:nav_bar_profile) | ||
end | ||
end |
7 changes: 7 additions & 0 deletions
7
app/components/dossiers/deleted_dossiers_component/deleted_dossiers_component.en.yml
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 @@ | ||
en: | ||
deleted_explanation: "The folders have been deleted. You can no longer recover them for the following reasons:" | ||
deleted_explanation_first_instructor: The user intentionally deleted their folder. | ||
deleted_explanation_second_instructor: The maximum retention period has expired. In accordance with GDPR regulations, the application cannot continue to host them. | ||
deleted_explanation_first_user: You have deleted your folder. | ||
deleted_explanation_second_user: The maximum retention period has expired. In accordance with GDPR regulations, the application cannot continue to host them. | ||
no_deleted_folders: You have no permanently deleted folders. |
7 changes: 7 additions & 0 deletions
7
app/components/dossiers/deleted_dossiers_component/deleted_dossiers_component.fr.yml
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 @@ | ||
fr: | ||
deleted_explanation: "Les dossiers ont été supprimés. Vous ne pouvez plus les récupérer pour les raisons suivantes :" | ||
deleted_explanation_first_instructeur: L’utilisateur a intentionnellement supprimé son dossier. | ||
deleted_explanation_second_instructeur: Le délai de conservation maximal a expiré. Conformément au règlement RGPD, l'application ne peut continuer à les héberger. | ||
deleted_explanation_first_user: Vous avez supprimé votre dossier. | ||
deleted_explanation_second_user: Le délai de conservation maximal a expiré. Conformément au règlement RGPD, l'application ne peut continuer à les héberger. | ||
no_deleted_dossiers: Vous n'avez pas de dossiers supprimés définitivement. |
47 changes: 47 additions & 0 deletions
47
app/components/dossiers/deleted_dossiers_component/deleted_dossiers_component.html.haml
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,47 @@ | ||
|
||
.fr-container | ||
%h1.fr-h2 | ||
Historique des dossiers supprimés | ||
|
||
.fr-container | ||
- if @deleted_dossiers.present? | ||
= render Dsfr::CalloutComponent.new(title: nil) do |c| | ||
- c.with_body do | ||
%p | ||
= t('.deleted_explanation') | ||
|
||
%ul | ||
%li | ||
= t(".deleted_explanation_first_#{role}") | ||
%li | ||
= t(".deleted_explanation_second_#{role}") | ||
|
||
.fr-table.fr-table--layout-fixed.fr-mt-3w | ||
%table | ||
%thead | ||
%tr | ||
%th.number-col N° dossier | ||
%th Libellé de la démarche | ||
%th Raison de suppression | ||
%th Date de suppression | ||
%tbody | ||
- @deleted_dossiers.each do |deleted_dossier| | ||
%tr | ||
%td.number-col | ||
= deleted_dossier.dossier_id | ||
|
||
%td.number-col | ||
= deleted_dossier.procedure.libelle.truncate_words(10) | ||
|
||
%td | ||
= deletion_reason_badge(deleted_dossier.reason) | ||
-# .fr-badge | ||
-# = t("activerecord.attributes.deleted_dossier.reason.#{deleted_dossier.reason}") | ||
%td.deleted-cell | ||
= l(deleted_dossier.deleted_at, format: '%d/%m/%y') | ||
|
||
= paginate @deleted_dossiers, views_prefix: 'shared' | ||
|
||
- else | ||
%p | ||
= t('.no_deleted_dossiers') |
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
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
58 changes: 7 additions & 51 deletions
58
app/views/instructeurs/procedures/deleted_dossiers.html.haml
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,55 +1,11 @@ | ||
- content_for(:title, "#{@procedure.libelle}") | ||
|
||
#procedure-show | ||
.sub-header | ||
.fr-container.flex | ||
= render partial: 'administrateurs/breadcrumbs', | ||
locals: { steps: [[@procedure.libelle.truncate_words(10), instructeur_procedure_path(@procedure)], | ||
['Historique des dossiers supprimés']] } | ||
|
||
.procedure-logo{ style: "background-image: url(#{@procedure.logo_url})", | ||
role: 'img', 'aria-label': "logo de la démarche #{@procedure.libelle}" } | ||
.fr-container | ||
.fr-mb-3w | ||
= link_to "Retour à la démarche", instructeur_procedure_path(@procedure), class: "fr-link fr-icon-arrow-left-line fr-link--icon-left" | ||
|
||
= render partial: 'header', locals: { procedure: @procedure, statut: @statut } | ||
|
||
.procedure-actions | ||
- if @can_download_dossiers | ||
= render Dossiers::ExportDropdownComponent.new(procedure: @procedure, export_templates: current_instructeur.export_templates_for(@procedure), export_url: method(:download_export_instructeur_procedure_path)) | ||
|
||
.fr-container.flex= render partial: "tabs", locals: { procedure: @procedure, | ||
statut: @statut, | ||
a_suivre_count: @a_suivre_count, | ||
suivis_count: @suivis_count, | ||
traites_count: @traites_count, | ||
tous_count: @tous_count, | ||
supprimes_recemment_count: @supprimes_recemment_count, | ||
archives_count: @archives_count, | ||
expirant_count: @expirant_count, | ||
has_en_cours_notifications: @has_en_cours_notifications, | ||
has_termine_notifications: @has_termine_notifications } | ||
|
||
.fr-container | ||
%h1.titre-dossiers Dossiers supprimés | ||
%details | ||
%summary Les dossiers ont été supprimés. Vous ne pouvez plus les récupérer depuis Démarches Simplifiées. | ||
Ceci s'explique pour les raisons suivantes : | ||
%ul | ||
%li L’utilisateur a intentionnellement supprimé son dossier. | ||
%li Le délai de conservation maximal de #{@procedure.duree_conservation_dossiers_dans_ds} mois a expiré. Conformément au règlement RGPD, DS ne peut continuer à les héberger. | ||
- if @deleted_dossiers.any? | ||
= paginate @deleted_dossiers, views_prefix: 'shared' | ||
%table.table.dossiers-table.hoverable | ||
%thead | ||
%tr | ||
%th.number-col N° dossier | ||
%th Raison de suppression | ||
%th Date de suppression | ||
%tbody | ||
- @deleted_dossiers.each do |deleted_dossier| | ||
%tr | ||
%td.number-col | ||
= deleted_dossier.dossier_id | ||
%td | ||
= deletion_reason_badge(deleted_dossier.reason) | ||
%td.deleted-cell | ||
= l(deleted_dossier.deleted_at, format: '%d/%m/%y') | ||
= paginate @deleted_dossiers, views_prefix: 'shared' | ||
- else | ||
Aucun dossier supprimé | ||
= render Dossiers::DeletedDossiersComponent.new(deleted_dossiers: @deleted_dossiers) |
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.