Merge pull request #11023 from demarches-simplifiees/move-tabs-explanations-in-modal-ldu
ETQ instructeur, j'ai accès à la description des onglets et les intitulés sont plus explicites
This commit is contained in:
commit
3f9b3c3d35
45 changed files with 295 additions and 230 deletions
|
@ -2,21 +2,21 @@ fr:
|
|||
archiver:
|
||||
finish:
|
||||
text_success:
|
||||
one: "%{success_count}/1 dossier a été archivé"
|
||||
other: "%{success_count}/%{count} dossiers ont été archivés"
|
||||
one: "%{success_count}/1 dossier a été placé dans « à archiver »"
|
||||
other: "%{success_count}/%{count} dossiers ont été placés dans « à archiver »"
|
||||
in_progress:
|
||||
text_success:
|
||||
one: "1 dossier est en cours d'archivage"
|
||||
other: "%{success_count}/%{count} dossiers ont été archivés"
|
||||
one: "1 dossier est en cours de déplacement dans « à archiver »"
|
||||
other: "%{success_count}/%{count} dossiers sont en cours de déplacement dans « à archiver »"
|
||||
desarchiver:
|
||||
finish:
|
||||
text_success:
|
||||
one: "%{success_count}/1 dossier a été désarchivé"
|
||||
other: "%{success_count}/%{count} dossiers ont été désarchivés"
|
||||
one: "%{success_count}/1 dossier a été retiré de « à archiver »"
|
||||
other: "%{success_count}/%{count} dossiers ont été retirés de « à archiver »"
|
||||
in_progress:
|
||||
text_success:
|
||||
one: "1 dossier est en cours d'désarchivage"
|
||||
other: "%{success_count}/%{count} dossiers ont été désarchivés"
|
||||
one: "1 dossier est en cours de retrait de « à archiver »"
|
||||
other: "%{success_count}/%{count} dossiers sont en cours de retrait de « à archiver »"
|
||||
passer_en_instruction:
|
||||
finish:
|
||||
text_success:
|
||||
|
@ -56,12 +56,12 @@ fr:
|
|||
supprimer:
|
||||
finish:
|
||||
text_success:
|
||||
one: "%{success_count}/1 dossier a été supprimé"
|
||||
other: "%{success_count}/%{count} dossiers ont été supprimés"
|
||||
one: "%{success_count}/1 dossier a été mis à la corbeille"
|
||||
other: "%{success_count}/%{count} dossiers ont été placés à la corbeille"
|
||||
in_progress:
|
||||
text_success:
|
||||
one: "1 dossier est en cours de suppression"
|
||||
other: "%{success_count}/%{count} dossiers ont été supprimés"
|
||||
other: "%{success_count}/%{count} dossiers ont été placés à la corbeille"
|
||||
restaurer:
|
||||
finish:
|
||||
text_success:
|
||||
|
|
|
@ -6,7 +6,7 @@ fr:
|
|||
instruction: Instruire les dossiers
|
||||
repousser_expiration: Conserver un mois de plus
|
||||
accepter: 'Accepter les dossiers'
|
||||
supprimer: 'Supprimer les dossiers'
|
||||
supprimer: 'Mettre les dossiers à la corbeille'
|
||||
restaurer: 'Restaurer les dossiers'
|
||||
accepter_description: Les usagers seront informés que leur dossier a été accepté
|
||||
refuser: 'Refuser les dossiers'
|
||||
|
|
|
@ -40,9 +40,7 @@ class Dossiers::ExportLinkComponent < ApplicationComponent
|
|||
end
|
||||
|
||||
def human_export_status(export)
|
||||
key = tab_i18n_key_from_status(export.statut)
|
||||
|
||||
t(key, count: export.count) || export.statut
|
||||
i18n_tab_from_status(export.statut, count: export.count) || export.statut
|
||||
end
|
||||
|
||||
def badge(export)
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
class Instructeurs::TabsExplanationsComponent < ApplicationComponent
|
||||
end
|
|
@ -0,0 +1,14 @@
|
|||
en:
|
||||
modal:
|
||||
title: What do the tabs include?
|
||||
close: Close
|
||||
tabs_en_cours_html: <strong>“in progress”</strong> tab brings together published procedures as well as closed procedures that still have files to process.
|
||||
tabs_en_test_html: <strong>“in testing”</strong> tab groups together the procedures which have not yet been published. Files submitted during the test phase will be automatically deleted when the process is modified or published.
|
||||
tabs_close_html: <strong>“finished”</strong> tab groups together closed procedures with no more files to process.
|
||||
tabs_a_suivre_html: <strong>“to follow”</strong> tab contains all the files which are not followed by any instructor. To assign the file, simply click on “Follow” the file.
|
||||
tabs_suivis_html: <strong>“followed by me“</strong> tab contains the files followed by you. When you (or another instructor) follow a folder, that folder no longer appears in the “to follow” folders. You can discuss with the applicant until you can accept, refuse and close their file without further action.
|
||||
tabs_traites_html: <strong>“processed”</strong> tab contains the files on which one or more instructors have ruled and made a decision (accepted, refused or closed without further action).
|
||||
tabs_tous_html: <strong>“total”</strong> tab contains all the files submitted for this procedure, whatever their status (“to be continued”, “follow-up”, “processed”). If the files are routed in instructor groups, you will only find in this tab the files of the group(s) of which you are a part.
|
||||
tabs_supprimes_html: "<strong>”trash”</strong> tab contains: <br>- files whose retention period has expired (the retention period of files is set by the administrator of the process).<br> - “processed” files which have been put in the trash by the instructors <br>From the date on which the files were put in the trash, you have 7 days to download them. / restore / extend their retention period by one month. After this period, these files will be permanently deleted."
|
||||
tabs_archives_html: <strong>“to archive”</strong> tab contains the files which were formerly in the “processed” tab (they were moved by an instructor to this “to be archived” tab). User messaging is automatically deactivated on the file as soon as it is archived. These files will be deleted when their retention period in Simplified Procedures has expired. To save and archive your files on your server, you must download them.
|
||||
tabs_expirant_html: <strong>“expiring”</strong> tab contains the files whose retention period will soon expire (the retention period of the files is set by the administrator of the process).
|
|
@ -0,0 +1,14 @@
|
|||
fr:
|
||||
modal:
|
||||
title: Que regroupent les onglets ?
|
||||
close: Fermer
|
||||
tabs_en_cours_html: L’onglet <strong>« en cours »</strong> regroupe les démarches publiées ainsi que les démarches closes ayant encore des dossiers à traiter.
|
||||
tabs_en_test_html: L’onglet <strong>« en test »</strong> regroupe les démarches qui ne sont pas encore publiées. Les dossiers déposés pendant la phase de test seront automatiquement supprimés lors de la modification ou de la publication de la démarche.
|
||||
tabs_close_html: L’onglet <strong>« terminée »</strong> regroupe les démarches closes n'ayant plus de dossiers à traiter.
|
||||
tabs_a_suivre_html: L’onglet <strong>« à suivre »</strong> contient l’ensemble des dossiers qui ne sont suivis par aucun instructeur. Pour s’affecter le dossier, il suffit de cliquer sur « Suivre » le dossier.
|
||||
tabs_suivis_html: L’onglet <strong>« suivis par moi»</strong> contient les dossiers que vous suivez. Lorsque vous (ou un autre instructeur) suivez un dossier, ce dossier n'apparaît plus dans les dossiers « à suivre ». Vous pouvez échanger avec le demandeur jusqu’à pouvoir accepter, refuser classer sans suite son dossier.
|
||||
tabs_traites_html: L’onglet <strong>« traité »</strong> contient les dossiers sur lesquels un ou plusieurs instructeurs ont statué et apporté une décision (accepté, refusé ou classé sans suite).
|
||||
tabs_tous_html: L’onglet <strong>« au total »</strong> contient l'ensemble des dossiers déposés sur cette démarche, quel que soit leur statut (« à suivre », « suivi », « traité »). Si les dossiers sont routés dans des groupes instructeurs, vous ne trouverez dans cet onglet que les dossiers du (des) groupe(s) dont vous faites partie.
|
||||
tabs_supprimes_html: "L’onglet <strong>« corbeille »</strong> contient : <br>- les dossiers dont le délai de conservation a expiré (la durée de conservation des dossiers est fixée par l'administrateur de la démarche).<br>- les dossiers « traités » qui ont été mis à la corbeille par les instructeurs. <br>À partir de la date à laquelle les dossiers ont été mis dans la corbeille, vous disposez d’un délai de 7 jours pour les télécharger / restaurer / étendre leur durée de conservation d’un mois. Passé ce délai, ces dossiers seront supprimés définitivement."
|
||||
tabs_archives_html: L’onglet <strong>« à archiver »</strong> contient les dossiers qui étaient anciennement dans l’onglet « traités » (ils ont été déplacés par un instructeur dans cet onglet « à archiver »). La messagerie usager est automatiquement désactivée sur le dossier dès qu’il est archivé. Ces dossiers seront supprimés lorsque leur délai de conservation dans Démarches-simplifiées sera expiré. Pour sauvegarder et archiver vos dossiers sur votre serveur, vous devez les télécharger.
|
||||
tabs_expirant_html: L’onglet <strong>« expirant »</strong> contient les dossiers dont le délai de conservation va bientôt expirer (la durée de conservation des dossiers est fixée par l'administrateur de la démarche).
|
|
@ -0,0 +1,25 @@
|
|||
|
||||
%button{ aria: {controls: 'modal-tabs-explanations' }, data: {'fr-opened': "false" }, class: 'fr-btn fr-btn--sm fr-btn--tertiary-no-outline fr-btn--icon-left fr-icon-question-line fr-ml-2v' }
|
||||
= t('.modal.title')
|
||||
|
||||
%dialog#modal-tabs-explanations.fr-modal{ "aria-labelledby" => "fr-modal-title-modal-1", role: "dialog" }
|
||||
.fr-container.fr-container--fluid.fr-container-md
|
||||
.fr-grid-row.fr-grid-row--center
|
||||
.fr-col-12.fr-col-md-10.fr-col-lg-8
|
||||
.fr-modal__body
|
||||
.fr-modal__header
|
||||
%button.fr-btn--close.fr-btn{ aria: { controls: 'modal-tabs-explanations' }, title: t('.modal.close_alt') }= t('.modal.close')
|
||||
.fr-modal__content
|
||||
%h1#fr-modal-title-modal-1.fr-modal__title
|
||||
%span.fr-icon-arrow-right-line.fr-icon--lg>
|
||||
= t('.modal.title')
|
||||
|
||||
- if action_name == "index"
|
||||
- %w(en_cours en_test close).each do |tab|
|
||||
%p
|
||||
= t(".modal.tabs_#{tab}_html")
|
||||
|
||||
- else
|
||||
- %w(a_suivre suivis traites tous supprimes expirant archives).each do |tab|
|
||||
%p
|
||||
= t(".modal.tabs_#{tab}_html")
|
|
@ -18,7 +18,7 @@ module Mutations
|
|||
|
||||
def authorized?(dossier:, instructeur:)
|
||||
if !dossier.termine?
|
||||
return false, { errors: ["Un dossier ne peut être archivé qu’une fois le traitement terminé"] }
|
||||
return false, { errors: ["Un dossier ne peut être déplacé dans « à archiver » qu’une fois le traitement terminé"] }
|
||||
end
|
||||
|
||||
dossier_authorized_for?(dossier, instructeur)
|
||||
|
|
|
@ -993,7 +993,7 @@ type Demarche {
|
|||
after: String
|
||||
|
||||
"""
|
||||
Seulement les dossiers archivés.
|
||||
Seulement les dossiers à archiver.
|
||||
"""
|
||||
archived: Boolean
|
||||
|
||||
|
@ -2864,7 +2864,7 @@ type GroupeInstructeurWithDossiers {
|
|||
after: String
|
||||
|
||||
"""
|
||||
Seulement les dossiers archivés.
|
||||
Seulement les dossiers à archiver.
|
||||
"""
|
||||
archived: Boolean
|
||||
|
||||
|
|
|
@ -41,7 +41,7 @@ module Types
|
|||
argument :created_since, GraphQL::Types::ISO8601DateTime, required: false, description: "Dossiers déposés depuis la date."
|
||||
argument :updated_since, GraphQL::Types::ISO8601DateTime, required: false, description: "Dossiers mis à jour depuis la date."
|
||||
argument :state, Types::DossierType::DossierState, required: false, description: "Dossiers avec statut."
|
||||
argument :archived, Boolean, required: false, description: "Seulement les dossiers archivés."
|
||||
argument :archived, Boolean, required: false, description: "Seulement les dossiers à archiver."
|
||||
argument :revision, ID, required: false, description: "Seulement les dossiers pour la révision donnée."
|
||||
argument :max_revision, ID, required: false, description: "Seulement les dossiers pour les révisons avant la révision donnée."
|
||||
argument :min_revision, ID, required: false, description: "Seulement les dossiers pour les révisons après la révision donnée."
|
||||
|
|
|
@ -9,7 +9,7 @@ module Types
|
|||
argument :created_since, GraphQL::Types::ISO8601DateTime, required: false, description: "Dossiers déposés depuis la date."
|
||||
argument :updated_since, GraphQL::Types::ISO8601DateTime, required: false, description: "Dossiers mis à jour depuis la date."
|
||||
argument :state, Types::DossierType::DossierState, required: false, description: "Dossiers avec statut."
|
||||
argument :archived, Boolean, required: false, description: "Seulement les dossiers archivés."
|
||||
argument :archived, Boolean, required: false, description: "Seulement les dossiers à archiver."
|
||||
argument :revision, ID, required: false, description: "Seulement les dossiers pour la révision donnée."
|
||||
argument :max_revision, ID, required: false, description: "Seulement les dossiers pour les révisons avant la révision donnée."
|
||||
argument :min_revision, ID, required: false, description: "Seulement les dossiers pour les révisons après la révision donnée."
|
||||
|
|
|
@ -1,43 +1,43 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module TabsHelper
|
||||
def tab_i18n_key_from_status(status)
|
||||
def i18n_tab_from_status(status, count: nil)
|
||||
case status
|
||||
when 'a-suivre'
|
||||
'views.instructeurs.dossiers.tab_steps.to_follow' # i18n-tasks-use t('views.instructeurs.dossiers.tab_steps.to_follow')
|
||||
t('instructeurs.dossiers.labels.to_follow', count:)
|
||||
when 'suivis'
|
||||
'pluralize.followed'
|
||||
t('pluralize.followed', count:)
|
||||
when 'traites'
|
||||
'pluralize.processed'
|
||||
t('pluralize.processed', count:)
|
||||
when 'tous'
|
||||
'views.instructeurs.dossiers.tab_steps.total' # i18n-tasks-use t('views.instructeurs.dossiers.tab_steps.total')
|
||||
t('instructeurs.dossiers.labels.total')
|
||||
when 'supprimes'
|
||||
'instructeurs.dossiers.labels.dossiers_supprimes'
|
||||
t('instructeurs.dossiers.labels.trash')
|
||||
when 'expirant'
|
||||
'pluralize.dossiers_close_to_expiration'
|
||||
t('pluralize.dossiers_close_to_expiration', count:)
|
||||
when 'archives'
|
||||
'pluralize.archived'
|
||||
t('instructeurs.dossiers.labels.to_archive')
|
||||
else
|
||||
fail ArgumentError, "Unknown tab status: #{status}"
|
||||
end
|
||||
end
|
||||
|
||||
def tab_item(label, url, active: false, badge: nil, notification: false, icon: nil)
|
||||
def tab_item(label, url, active: false, badge: nil, notification: false, html_class: nil)
|
||||
render partial: 'shared/tab_item', locals: {
|
||||
label: label,
|
||||
url: url,
|
||||
active: active,
|
||||
badge: badge,
|
||||
notification: notification,
|
||||
icon: icon
|
||||
html_class: html_class
|
||||
}
|
||||
end
|
||||
|
||||
def dynamic_tab_item(label, url_or_urls, badge: nil, notification: false, icon: nil)
|
||||
def dynamic_tab_item(label, url_or_urls, badge: nil, notification: false)
|
||||
urls = [url_or_urls].flatten
|
||||
url = urls.first
|
||||
active = urls.any? { |u| current_page?(u) }
|
||||
|
||||
tab_item(label, url, active: active, badge: badge, notification: notification, icon: icon)
|
||||
tab_item(label, url, active: active, badge: badge, notification: notification)
|
||||
end
|
||||
end
|
||||
|
|
|
@ -130,7 +130,7 @@ class Commentaire < ApplicationRecord
|
|||
def messagerie_available?
|
||||
return if sent_by_system?
|
||||
if dossier.present? && !dossier.messagerie_available?
|
||||
errors.add(:dossier, "Il n’est pas possible d’envoyer un message sur un dossier supprimé, archivé ou en brouillon")
|
||||
errors.add(:dossier, "Il n’est pas possible d’envoyer un message sur un dossier supprimé, à archiver ou en brouillon")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -104,7 +104,7 @@ module DossierExportConcern
|
|||
]
|
||||
end
|
||||
columns += [
|
||||
['Archivé', :archived],
|
||||
['À archiver', :archived],
|
||||
['État du dossier', Dossier.human_attribute_name("state.#{state}")],
|
||||
['Dernière mise à jour le', :updated_at],
|
||||
['Dernière mise à jour du dossier le', :last_champ_updated_at],
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
%li n° #{d.id} (#{d.procedure.libelle})
|
||||
|
||||
%p
|
||||
= t('.footer', count: @hidden_dossiers.size)
|
||||
= link_to("mes dossiers", dossiers_url)
|
||||
\.
|
||||
= t('.footer_html', count: @hidden_dossiers.size,
|
||||
trash_url: instructeur_procedure_url(procedure_id: @hidden_dossiers.first.procedure.id, statut: "supprimes"),
|
||||
procedures_url: instructeur_procedures_url)
|
||||
|
||||
= render partial: "layouts/mailers/signature"
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
.tab-title Archivé
|
||||
.tab-title À archiver
|
||||
%p.tab-paragraph= t(".archived", date: l(archived_at), email: archived_by)
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
|
||||
- elsif archived
|
||||
= button_to unarchive_instructeur_dossier_path(procedure_id, dossier_id), method: :patch, class: "fr-btn fr-icon-upload-2-line" do
|
||||
Désarchiver le dossier
|
||||
Replacer dans “traités”
|
||||
|
||||
= button_to instructeur_dossier_path(procedure_id, dossier_id), method: :delete, class: 'fr-btn fr-btn--secondary fr-icon-delete-line icon-only danger', title: t('views.instructeurs.dossiers.delete_dossier') do
|
||||
= ""
|
||||
|
@ -29,7 +29,7 @@
|
|||
Repasser en instruction
|
||||
|
||||
= button_to archive_instructeur_dossier_path(procedure_id, dossier_id, statut: params[:statut]), method: :patch, class: 'fr-btn fr-icon-folder-2-line' do
|
||||
Archiver le dossier
|
||||
Déplacer dans “à archiver“
|
||||
|
||||
= button_to instructeur_dossier_path(procedure_id, dossier_id, statut: params[:statut]), method: :delete, class: 'fr-btn fr-btn--secondary fr-icon-delete-line icon-only danger', title: t('views.instructeurs.dossiers.delete_dossier') do
|
||||
= ""
|
||||
|
|
|
@ -65,4 +65,4 @@
|
|||
.center.fr-text--bold.fr-text--sm
|
||||
%span.fr-icon-delete-line.fr-icon--sm
|
||||
.center.fr-text--xs
|
||||
= t('instructeurs.dossiers.labels.dossiers_supprimes')
|
||||
= t('instructeurs.dossiers.labels.trash')
|
||||
|
|
|
@ -1,39 +1,39 @@
|
|||
%nav.fr-tabs.mt-3
|
||||
%ul.fr-tabs__list.fr-pl-0{ role: 'tablist' }
|
||||
= tab_item(t(tab_i18n_key_from_status('a-suivre')),
|
||||
= tab_item(i18n_tab_from_status('a-suivre'),
|
||||
instructeur_procedure_path(procedure, statut: 'a-suivre'),
|
||||
active: statut == 'a-suivre',
|
||||
badge: number_with_html_delimiter(a_suivre_count))
|
||||
|
||||
= tab_item(t(tab_i18n_key_from_status('suivis'), count: suivis_count),
|
||||
= tab_item(i18n_tab_from_status('suivis', count: suivis_count),
|
||||
instructeur_procedure_path(procedure, statut: 'suivis'),
|
||||
active: statut == 'suivis',
|
||||
badge: number_with_html_delimiter(suivis_count),
|
||||
notification: has_en_cours_notifications)
|
||||
|
||||
= tab_item(t(tab_i18n_key_from_status('traites'), count: traites_count),
|
||||
= tab_item(i18n_tab_from_status('traites', count: traites_count),
|
||||
instructeur_procedure_path(procedure, statut: 'traites'),
|
||||
active: statut == 'traites',
|
||||
badge: number_with_html_delimiter(traites_count),
|
||||
notification: has_termine_notifications)
|
||||
|
||||
= tab_item(t(tab_i18n_key_from_status('tous')),
|
||||
= tab_item(i18n_tab_from_status('tous'),
|
||||
instructeur_procedure_path(procedure, statut: 'tous'),
|
||||
active: statut == 'tous',
|
||||
badge: number_with_html_delimiter(tous_count))
|
||||
|
||||
- if procedure.procedure_expires_when_termine_enabled
|
||||
= tab_item(t(tab_i18n_key_from_status('expirant'), count: expirant_count),
|
||||
= tab_item(i18n_tab_from_status('expirant', count: expirant_count),
|
||||
instructeur_procedure_path(procedure, statut: 'expirant'),
|
||||
active: statut == 'expirant',
|
||||
badge: number_with_html_delimiter(expirant_count))
|
||||
|
||||
= tab_item(t(tab_i18n_key_from_status('archives'), count: archives_count),
|
||||
= tab_item(i18n_tab_from_status('archives'),
|
||||
instructeur_procedure_path(procedure, statut: 'archives'),
|
||||
active: statut == 'archives',
|
||||
icon: 'fr-icon-folder-2-line')
|
||||
html_class: 'fr-icon-folder-2-line fr-tabs__tab--icon-left')
|
||||
|
||||
= tab_item(t(tab_i18n_key_from_status('supprimes'), count: supprimes_count),
|
||||
= tab_item(i18n_tab_from_status('supprimes'),
|
||||
instructeur_procedure_path(procedure, statut: 'supprimes'),
|
||||
active: statut == 'supprimes',
|
||||
icon: 'fr-icon-delete-line')
|
||||
html_class: 'fr-icon-delete-line fr-tabs__tab--icon-left')
|
||||
|
|
|
@ -2,7 +2,9 @@
|
|||
|
||||
.sub-header
|
||||
.fr-container
|
||||
.flex.fr-mb-2v
|
||||
%h1.fr-h3.fr-mb-0 Démarches
|
||||
= render Instructeurs::TabsExplanationsComponent.new
|
||||
= render partial: 'instructeurs/procedures/synthese', locals: { procedures: @procedures, all_dossiers_counts: @all_dossiers_counts }
|
||||
|
||||
%nav.fr-tabs{ role: 'navigation', 'aria-label': t('views.users.dossiers.secondary_menu') }
|
||||
|
@ -13,21 +15,13 @@
|
|||
|
||||
.fr-container
|
||||
- if @statut == "en-cours"
|
||||
= render Dsfr::CalloutComponent.new(title: nil) do |c|
|
||||
- c.with_body do
|
||||
= t(".procedure_en_cours_description")
|
||||
- collection = @procedures_en_cours
|
||||
- if @statut == "brouillons"
|
||||
= render Dsfr::CalloutComponent.new(title: nil) do |c|
|
||||
- c.with_body do
|
||||
= t(".procedure_en_test_description")
|
||||
- collection = @procedures_draft
|
||||
- if @statut == "archivees"
|
||||
= render Dsfr::CalloutComponent.new(title: nil) do |c|
|
||||
- c.with_body do
|
||||
= t(".procedure_close_description")
|
||||
- collection = @procedures_closes
|
||||
|
||||
- if @statut == "brouillons"
|
||||
- collection = @procedures_draft
|
||||
|
||||
- if @statut == "archivees"
|
||||
- collection = @procedures_closes
|
||||
|
||||
- if collection.present?
|
||||
.fr-container.flex.justify-between.fr-mb-6w
|
||||
|
|
|
@ -7,9 +7,12 @@
|
|||
locals: { steps: [[t('show_procedure', scope: [:layouts, :breadcrumb], libelle: @procedure.libelle.truncate(22)), instructeur_procedure_path(@procedure)]] }
|
||||
= render partial: 'header', locals: { procedure: @procedure, statut: @statut }
|
||||
%hr
|
||||
.flex
|
||||
%h1.fr-h5.fr-mb-0= t('.file_tracking')
|
||||
= render Instructeurs::TabsExplanationsComponent.new
|
||||
|
||||
.fr-container.flex= render partial: "tabs", locals: { procedure: @procedure,
|
||||
.fr-container
|
||||
.flex= render partial: "tabs", locals: { procedure: @procedure,
|
||||
statut: @statut,
|
||||
a_suivre_count: @counts[:a_suivre],
|
||||
suivis_count: @counts[:suivis],
|
||||
|
@ -21,40 +24,7 @@
|
|||
has_en_cours_notifications: @has_en_cours_notifications,
|
||||
has_termine_notifications: @has_termine_notifications }
|
||||
|
||||
.fr-container.fr-highlight
|
||||
- if @statut == 'a-suivre'
|
||||
%p
|
||||
= t('views.instructeurs.dossiers.tab_explainations.a_suivre')
|
||||
- if @statut == 'suivis'
|
||||
%p
|
||||
= t('views.instructeurs.dossiers.tab_explainations.suivis')
|
||||
- if @statut == 'traites'
|
||||
%p
|
||||
= t('views.instructeurs.dossiers.tab_explainations.traites_html', archives_path: list_instructeur_archives_path(@procedure))
|
||||
- if @statut == 'tous'
|
||||
%p
|
||||
- if @procedure.routing_enabled?
|
||||
= t('views.instructeurs.dossiers.tab_explainations.tous_with_routing')
|
||||
- else
|
||||
= t('views.instructeurs.dossiers.tab_explainations.tous')
|
||||
- if @statut == 'supprimes'
|
||||
%p
|
||||
= t('views.instructeurs.dossiers.tab_explainations.supprimes').html_safe
|
||||
- if @statut == 'archives'
|
||||
%p
|
||||
= t('views.instructeurs.dossiers.tab_explainations.archives')
|
||||
%br
|
||||
Ces dossiers seront supprimés lorsque leur délai de conservation dans #{APPLICATION_NAME}
|
||||
- if @procedure.duree_conservation_dossiers_dans_ds
|
||||
= "(#{@procedure.duree_conservation_dossiers_dans_ds} mois)"
|
||||
sera expiré.
|
||||
= link_to 'En savoir plus', ARCHIVAGE_DOC_URL
|
||||
- if @statut == 'expirant'
|
||||
%p
|
||||
= t('views.instructeurs.dossiers.tab_explainations.expirant')
|
||||
|
||||
.fr-container--fluid.fr-mx-4w.overflow-y-visible
|
||||
%hr
|
||||
.flex.align-center
|
||||
- if @filtered_sorted_paginated_ids.present? || @current_filters.count > 0
|
||||
= render partial: "dossiers_filter_dropdown", locals: { procedure: @procedure, statut: @statut, procedure_presentation: @procedure_presentation }
|
||||
|
@ -187,6 +157,14 @@
|
|||
= paginate @filtered_sorted_paginated_ids, views_prefix: 'shared'
|
||||
.fr-table__footer--end.flex-no-grow
|
||||
|
||||
- if @statut == "archives"
|
||||
.fr-notice.fr-notice--warning
|
||||
.fr-container--fluid.fr-px-2w
|
||||
.fr-notice__body
|
||||
%span.fr-notice__title= t('views.instructeurs.dossiers.archives_notice_title')
|
||||
%span.fr-notice__desc
|
||||
= t('views.instructeurs.dossiers.archives_notice_html', app_name: APPLICATION_NAME, duration_months: @procedure.duree_conservation_dossiers_dans_ds, doc_url: ARCHIVAGE_DOC_URL)
|
||||
|
||||
- else
|
||||
%h2.empty-text
|
||||
= t('views.instructeurs.dossiers.no_file')
|
||||
|
|
|
@ -1,9 +1,7 @@
|
|||
%li{ class: "relative #{(active ? 'active' : nil)}", role: 'presentation' }
|
||||
- if notification
|
||||
%span.notifications{ 'aria-label': 'notifications' }
|
||||
= link_to(url, 'aria-selected': active ? true : nil, class: 'fr-tabs__tab', role: 'tab' ) do
|
||||
= link_to(url, 'aria-selected': active ? true : nil, class: class_names("fr-tabs__tab", html_class), role: 'tab' ) do
|
||||
- if badge.present?
|
||||
%span.fr-badge.fr-badge--blue-ecume.fr-mr-1w= badge
|
||||
- if icon.present?
|
||||
%span.fr-icon--sm.fr-mr-1w{ class: icon, "aria-hidden": true }
|
||||
= label
|
||||
|
|
|
@ -381,8 +381,6 @@ en:
|
|||
instructeurs:
|
||||
dossiers:
|
||||
tab_steps:
|
||||
to_follow: to follow
|
||||
total: total
|
||||
request: Request
|
||||
private_annotations: Private annotations
|
||||
external_opinion: External opinion
|
||||
|
@ -390,17 +388,8 @@ en:
|
|||
involved_persons: Involved persons
|
||||
reaffectation: reassignment
|
||||
attachments: Attachments
|
||||
tab_explainations:
|
||||
a_suivre: No instructor is assigned to follow up on these files. Be the first !
|
||||
suivis: The folders that are in this tab are only those that you follow. You can exchange with the requester until you can accept them, refuse them or classify them without follow-up.
|
||||
traites_html: "The files in this tab are finished: they have been accepted, refused or closed without follow-up. You can <a href=%{archives_path}>download</a> the zip archives of finished files and their attachments."
|
||||
tous: All the files that have been submitted on this approach, included files to be follow and files followed by you or other instructors.
|
||||
tous_with_routing: All the files that have been submitted on this approach, and assigned to your instructors groups.
|
||||
supprimes: All files not <strong>archive</strong>, <strong>completed</strong> and <strong>deleted by the instructors</strong> on this approach.
|
||||
archives: "The files in this tab are archived: you can no longer reply to them, and requesters can no longer modify them."
|
||||
expirant: Records will not expire prior to the data retention period.
|
||||
archived_dossier: "This file will be kept for an additional month"
|
||||
delete_dossier: "Delete file"
|
||||
delete_dossier: "Move file to trash"
|
||||
acts_on_behalf: "acts for"
|
||||
deleted_by_administration: "File deleted by administration"
|
||||
restore: "Restore"
|
||||
|
@ -421,6 +410,12 @@ en:
|
|||
passer_en_instruction_blocked_by_pending_correction: |
|
||||
It is not possible to switch to instruction while the file is awaiting correction.
|
||||
If necessary, the instructor who requested the correction can delete the corresponding message.
|
||||
archives_notice_title: Files archiving
|
||||
archives_notice_html: |
|
||||
These files will be deleted when their retention period in %{app_name} (%{duration_months} months) expires.
|
||||
<a href="%{doc_url}" rel="external noopener" target="_blank" title="Documentation about files archiving" lang="fr">Learn more</a>
|
||||
<br/>
|
||||
To save and archive your files on your server, you must download them.
|
||||
avis:
|
||||
introduction_file_explaination: "File attached to the request for advice"
|
||||
search:
|
||||
|
@ -545,7 +540,7 @@ en:
|
|||
edit_dossier: "Edit the file"
|
||||
start_other_dossier: "Start another empty file"
|
||||
clone: "Duplicate the file"
|
||||
delete_dossier: "Delete the file"
|
||||
delete_dossier: "Move file to trash"
|
||||
delete_dossier_confirm: "If you continue, you will delete this file and the information it contains. Any deletion will result in the cancellation of the current procedure.\n\nConfirm deletion?"
|
||||
delete_dossier_with_transfer_confirm: "If you continue, you will delete this file, the information it contains and its transfer request to %{email}. Any deletion will result in the cancellation of the current procedure.\n\nConfirm deletion?"
|
||||
transfer_dossier: "Transfer the file"
|
||||
|
@ -787,14 +782,14 @@ en:
|
|||
one: guest file
|
||||
other: guest files
|
||||
dossiers_supprimes:
|
||||
one: deleted
|
||||
other: deleted
|
||||
one: trash
|
||||
other: trash
|
||||
dossiers_transferes:
|
||||
one: transfer request
|
||||
other: transfer requests
|
||||
dossiers_close_to_expiration:
|
||||
one: expiring file
|
||||
other: expiring files
|
||||
one: expiring
|
||||
other: expiring
|
||||
dossier_trouve:
|
||||
one: "%{count} file found"
|
||||
other: "%{count} files found"
|
||||
|
@ -875,8 +870,8 @@ en:
|
|||
labels:
|
||||
to_follow: to follow
|
||||
to_archive: to archive
|
||||
dossiers_supprimes: trash
|
||||
total: total
|
||||
trash: trash
|
||||
france_connect:
|
||||
particulier:
|
||||
choose_email:
|
||||
|
|
|
@ -379,8 +379,6 @@ fr:
|
|||
instructeurs:
|
||||
dossiers:
|
||||
tab_steps:
|
||||
to_follow: à suivre
|
||||
total: au total
|
||||
request: Demande
|
||||
private_annotations: Annotations privées
|
||||
external_opinion: Avis externes
|
||||
|
@ -388,17 +386,8 @@ fr:
|
|||
involved_persons: Personnes impliquées
|
||||
reaffectation: Réaffectation
|
||||
attachments: Pièces jointes
|
||||
tab_explainations:
|
||||
a_suivre: Aucun instructeur n’est affecté au suivi de ces dossiers. Soyez le premier !
|
||||
suivis: Les dossiers qui sont dans cet onglet sont uniquement ceux que vous suivez. Vous pouvez échanger avec le demandeur jusqu’à pouvoir les accepter, les refuser ou les classer sans suite.
|
||||
traites_html: "Les dossiers dans cet onglet sont terminés : ils ont été acceptés, refusés ou classés sans suite. Vous pouvez <a href=%{archives_path}>télécharger</a> les archives au format zip des dossiers terminés et leurs pièces jointes."
|
||||
tous: Tous les dossiers déposés sur cette démarche, qu’ils soient à suivre, suivis par vous ou suivis par d’autres instructeurs.
|
||||
tous_with_routing: Tous les dossiers déposés sur cette démarche et attribués aux groupes d’instructeurs dont vous faites partie.
|
||||
supprimes: Tous les dossiers <strong>non archivés</strong>, <strong>terminés</strong> et <strong>supprimés par les instructeurs</strong> sur cette démarche
|
||||
archives: "Les dossiers de cet onglet sont archivés : vous ne pouvez plus y répondre, et les demandeurs ne peuvent plus les modifier."
|
||||
expirant: Les dossiers n’expireront pas avant la période de conservation des données.
|
||||
archived_dossier: "Le dossier sera conservé 1 mois supplémentaire"
|
||||
delete_dossier: "Supprimer le dossier"
|
||||
delete_dossier: "Mettre à la corbeille"
|
||||
deleted_reason:
|
||||
user_request: supprimé par l’usager
|
||||
expired: a expiré
|
||||
|
@ -423,6 +412,12 @@ fr:
|
|||
passer_en_instruction_blocked_by_pending_correction: |
|
||||
Le passage en instruction est impossible tant que le dossier est en attente de correction.
|
||||
Si nécessaire, l’instructeur ayant demandé la correction peut supprimer le message correspondant.
|
||||
archives_notice_title: Archivage des dossiers
|
||||
archives_notice_html: |
|
||||
Ces dossiers seront supprimés lorsque leur délai de conservation dans %{app_name} (%{duration_months} mois) sera expiré.
|
||||
<a href="%{doc_url}" rel="external noopener" target="_blank" title="Documentation sur l‘archivage des dossiers">En savoir plus</a>
|
||||
<br/>
|
||||
Pour sauvegarder et archiver vos dossiers sur votre serveur, vous devez les télécharger.
|
||||
avis:
|
||||
introduction_file_explaination: "Fichier joint à la demande d’avis"
|
||||
search:
|
||||
|
@ -538,7 +533,7 @@ fr:
|
|||
edit_dossier: "Modifier le dossier"
|
||||
start_other_dossier: "Commencer un nouveau dossier"
|
||||
clone: "Dupliquer ce dossier"
|
||||
delete_dossier: "Supprimer le dossier"
|
||||
delete_dossier: "Mettre à la corbeille"
|
||||
delete_dossier_confirm: "En continuant, vous allez supprimer ce dossier ainsi que les informations qu’il contient. Toute suppression entraîne l’annulation de la démarche en cours.\n\nConfirmer la suppression ?"
|
||||
delete_dossier_with_transfer_confirm: "En continuant, vous allez supprimer ce dossier, les informations qu’il contient ainsi que sa demande de transfert à %{email}. Toute suppression entraîne l’annulation de la démarche en cours.\n\nConfirmer la suppression ?"
|
||||
transfer_dossier: "Transférer le dossier"
|
||||
|
@ -782,7 +777,9 @@ fr:
|
|||
followed:
|
||||
one: suivi par moi
|
||||
other: suivis par moi
|
||||
archived: à archiver
|
||||
archived:
|
||||
one: à archiver
|
||||
other: à archiver
|
||||
en_cours:
|
||||
one: en cours
|
||||
other: en cours
|
||||
|
@ -796,8 +793,8 @@ fr:
|
|||
one: dossier invité
|
||||
other: dossiers invités
|
||||
dossiers_supprimes:
|
||||
one: supprimé
|
||||
other: supprimés
|
||||
one: corbeille
|
||||
other: corbeille
|
||||
dossiers_historique:
|
||||
one: supprimé définitivement
|
||||
other: supprimés définitivement
|
||||
|
@ -806,7 +803,7 @@ fr:
|
|||
other: demandes de transfert
|
||||
dossiers_close_to_expiration:
|
||||
one: expirant
|
||||
other: expirants
|
||||
other: expirant
|
||||
dossier_trouve:
|
||||
one: "%{count} dossier trouvé"
|
||||
other: "%{count} dossiers trouvés"
|
||||
|
@ -877,8 +874,8 @@ fr:
|
|||
labels:
|
||||
to_follow: à suivre
|
||||
to_archive: à archiver
|
||||
dossiers_supprimes: corbeille
|
||||
total: au total
|
||||
trash: corbeille
|
||||
administrateurs:
|
||||
activate:
|
||||
new:
|
||||
|
|
|
@ -2,11 +2,22 @@ fr:
|
|||
dossier_mailer:
|
||||
notify_automatic_deletion_to_administration:
|
||||
subject:
|
||||
one: "Un dossier a été supprimé"
|
||||
other: "Des dossiers ont été supprimés"
|
||||
one: 'Un dossier a été mis à la corbeille'
|
||||
other: 'Des dossiers ont été mis à la corbeille'
|
||||
header:
|
||||
one: "Le délai maximal de conservation du dossier a été atteint, celui-ci a donc été supprimé :"
|
||||
other: "Le délai maximal de conservation des dossiers a été atteint, ceux-ci ont donc été supprimés :"
|
||||
footer:
|
||||
one: Vous pouvez retrouver ce dossier pendant encore une semaine depuis l’onglet « Supprimé » sur la page
|
||||
other: Vous pouvez retrouver ces dossiers pendant encore une semaine depuis l’onglet « Supprimés » sur la page
|
||||
one: 'Le délai maximal de conservation du dossier a été atteint, celui-ci a donc été mis à la corbeille :'
|
||||
other: 'Le délai maximal de conservation des dossiers a été atteint, ceux-ci ont donc été mis à la corbeille :'
|
||||
footer_html:
|
||||
one: |
|
||||
Vous pouvez retrouver ce dossier pendant <strong>encore 7 jours</strong> depuis l’onglet
|
||||
<a href="%{trash_url}">corbeille</a>
|
||||
du suivi des dossiers, pour les télécharger ou étendre sa durée de conservation.
|
||||
<br>
|
||||
Passé ce délai, ce dossier sera <strong>supprimé définitivement</strong>.
|
||||
other: |
|
||||
Vous pouvez retrouver ces dossiers pendant <strong>encore 7 jours</strong> depuis l’onglet « Corbeille »
|
||||
sur la page du suivi des dossiers, pour les télécharger ou étendre leur durée de conservation.
|
||||
<br>
|
||||
Passé ce délai, ces dossiers seront <strong>supprimés définitivement</strong>.
|
||||
<br>
|
||||
<a href="%{procedures_url}">Consulter la liste des démarches</a>
|
||||
|
|
|
@ -2,11 +2,11 @@ fr:
|
|||
dossier_mailer:
|
||||
notify_automatic_deletion_to_user:
|
||||
subject:
|
||||
one: "Un dossier a été supprimé de votre compte"
|
||||
other: "Des dossiers ont été supprimés de votre compte"
|
||||
one: "Un dossier de votre compte a été mis à la corbeille"
|
||||
other: "Des dossiers de votre compte ont été placés à la corbeille"
|
||||
header:
|
||||
one: "Le délai maximum pour la conservation du dossier a été atteint.\nLe dossier suivant a été supprimé :"
|
||||
other: "Le délai maximum pour la conservation des dossiers a été atteint.\nLes dossiers suivants ont été supprimés :"
|
||||
one: "Le délai maximum pour la conservation du dossier a été atteint.\nLe dossier suivant a été mis à la corbeille:"
|
||||
other: "Le délai maximum pour la conservation des dossiers a été atteint.\nLes dossiers suivants ont été placés à la corbeille :"
|
||||
footer:
|
||||
one: Vous pouvez retrouver ce dossier pendant encore une semaine depuis l’onglet « Supprimé » sur la page
|
||||
other: Vous pouvez retrouver ces dossiers pendant encore une semaine depuis l’onglet « Supprimés » sur la page
|
||||
one: Vous pouvez retrouver ce dossier pendant encore une semaine depuis l’onglet « Corbeille » sur la page
|
||||
other: Vous pouvez retrouver ces dossiers pendant encore une semaine depuis l’onglet « Corbeille » sur la page
|
||||
|
|
|
@ -25,4 +25,4 @@ fr:
|
|||
refuse: "Refusé"
|
||||
sans_suite: "Classé sans suite"
|
||||
archived_block:
|
||||
archived: "Ce dossier a été archivé le %{date} par %{email}"
|
||||
archived: "Ce dossier a été déplacé dans « à archiver » le %{date} par %{email}"
|
||||
|
|
|
@ -14,7 +14,7 @@ en:
|
|||
procedure_management: File management
|
||||
notification_management: notification management
|
||||
administrators_list: administrators list
|
||||
exports_list: exports and export templates
|
||||
exports_list: Exports and export templates
|
||||
export_templates: Export templates
|
||||
exports_notification_label: A new export is ready to download
|
||||
statistics: statistics
|
||||
|
|
|
@ -2,9 +2,6 @@ en:
|
|||
instructeurs:
|
||||
procedures:
|
||||
index:
|
||||
procedure_en_cours_description: The “in progress” tab groups published procedures as well as closed procedures that still have files to process.
|
||||
procedure_en_test_description: The “in testing” tab groups unpublished procedures. Files submitted during the test phase will be automatically deleted when the procedure is modified or published.
|
||||
procedure_close_description: The “finished” tab groups closed procedures with no more files to process.
|
||||
to_follow: to follow
|
||||
followed: followed
|
||||
processed: processed
|
||||
|
|
|
@ -2,13 +2,11 @@ fr:
|
|||
instructeurs:
|
||||
procedures:
|
||||
index:
|
||||
procedure_en_cours_description: L'onglet « en cours » regroupe les démarches publiées ainsi que les démarches closes ayant encore des dossiers à traiter.
|
||||
procedure_en_test_description: L'onglet « en test » regroupe les démarches qui ne sont pas encore publiées. Les dossiers déposés pendant la phase de test seront automatiquement supprimés lors de la modification ou de la publication de la démarche.
|
||||
procedure_close_description: L'onglet « terminée » regroupe les démarches closes n'ayant plus de dossiers à traiter.
|
||||
to_follow: à suivre
|
||||
followed: suivis
|
||||
followed: suivis par moi
|
||||
processed: traités
|
||||
all: dossiers
|
||||
archived: à archiver
|
||||
dossiers_close_to_expiration: expirant
|
||||
copy_link_button: Copier le lien de la démarche dans le presse-papiers
|
||||
show:
|
||||
|
|
|
@ -3,7 +3,7 @@ category: "instructeur"
|
|||
subcategory: "instruction"
|
||||
slug: "a-quoi-correspondent-les-differentes-categories-de-dossiers"
|
||||
locale: "fr"
|
||||
keywords: "catégories dossiers, à suivre, suivi, traités, supprimés, archivés"
|
||||
keywords: "catégories dossiers, à suivre, suivi, traités, supprimés, à archiver"
|
||||
title: "À quoi correspondent les différentes catégories de dossiers ?"
|
||||
---
|
||||
|
||||
|
@ -13,10 +13,10 @@ Pour chaque démarche, les dossiers sont répartis dans plusieurs onglets :
|
|||
|
||||
- **À suivre** : regroupe l’ensemble des dossiers qui ne sont suivis par aucun instructeur.
|
||||
- **Suivis** : n’affiche que les dossiers que *vous* suivez. Elle ne prend donc pas en compte les dossiers suivis par les autres instructeurs de la démarche.
|
||||
- **Traités** : regroupe les dossiers dont le statut est *accepté*, *refusé* ou *classé sans suite* et qui n’ont pas été archivés.
|
||||
- **Traités** : regroupe les dossiers dont le statut est *accepté*, *refusé* ou *classé sans suite* et qui n’ont pas été déplacés dans « à archiver ».
|
||||
- **Supprimés** : regroupe l’ensemble des dossiers non archivés, terminés et supprimés par les instructeurs de la démarche.
|
||||
- **Expirant** : les dossiers *en construction* ou *traités*, (archivés ou non), dont le délai d’expiration approche (moins d’un mois). À l’issue de ce délai, le dossier sera supprimé de la plateforme.
|
||||
- **Archivés** : regroupe l’ensemble des dossiers archivés. Les instructeurs ne peuvent plus y répondre, et les demandeurs ne peuvent plus les modifier. La messagerie est désactivée. Ces dossiers seront supprimés lorsque leur délai de conservation sur %{application_name} sera expiré.
|
||||
- **À archiver** : regroupe l’ensemble des dossiers à archiver. Les instructeurs ne peuvent plus y répondre, et les demandeurs ne peuvent plus les modifier. La messagerie est désactivée. Ces dossiers seront supprimés lorsque leur délai de conservation sur %{application_name} sera expiré.
|
||||
|
||||
Notez qu’**un dossier peut être suivi par plusieurs instructeurs**. Vous pourrez donc retrouver les dossiers que vous ne suivez pas dans l’onglet **au total**. La somme des onglets *à suivre*, *suivis* et *traités* n’est donc pas nécessairement égale au nombre affiché *au total*.
|
||||
|
||||
|
|
|
@ -33,7 +33,7 @@ RSpec.describe Dossiers::BatchAlertComponent, type: :component do
|
|||
|
||||
it { is_expected.to have_selector('.fr-alert--info') }
|
||||
it { is_expected.to have_text("Une action de masse est en cours") }
|
||||
it { is_expected.to have_text("1/2 dossiers ont été archivés") }
|
||||
it { is_expected.to have_text("1/2 dossiers sont en cours de déplacement dans « à archiver »") }
|
||||
it { is_expected.to have_text("Cette opération a été lancée par #{instructeur.email}, il y a moins d'une minute") }
|
||||
end
|
||||
|
||||
|
@ -46,7 +46,7 @@ RSpec.describe Dossiers::BatchAlertComponent, type: :component do
|
|||
|
||||
it { is_expected.to have_selector('.fr-alert--success') }
|
||||
it { is_expected.to have_text("L’action de masse est terminée") }
|
||||
it { is_expected.to have_text("2 dossiers ont été archivés") }
|
||||
it { is_expected.to have_text("2 dossiers ont été placés dans « à archiver »") }
|
||||
it { expect(batch_operation.seen_at).to eq(nil) }
|
||||
end
|
||||
|
||||
|
@ -59,7 +59,7 @@ RSpec.describe Dossiers::BatchAlertComponent, type: :component do
|
|||
|
||||
it { is_expected.to have_selector('.fr-alert--warning') }
|
||||
it { is_expected.to have_text("L’action de masse est terminée") }
|
||||
it { is_expected.to have_text("1/2 dossiers ont été archivés") }
|
||||
it { is_expected.to have_text("1/2 dossiers ont été placés dans « à archiver »") }
|
||||
it { expect(batch_operation.seen_at).to eq(nil) }
|
||||
|
||||
it 'on next render "seen_at" is set to avoid rendering alert' do
|
||||
|
@ -87,7 +87,7 @@ RSpec.describe Dossiers::BatchAlertComponent, type: :component do
|
|||
|
||||
it { is_expected.to have_selector('.fr-alert--info') }
|
||||
it { is_expected.to have_text("Une action de masse est en cours") }
|
||||
it { is_expected.to have_text("1/2 dossiers ont été désarchivés") }
|
||||
it { is_expected.to have_text("1/2 dossiers sont en cours de retrait de « à archiver »") }
|
||||
it { is_expected.to have_text("Cette opération a été lancée par #{instructeur.email}, il y a moins d'une minute") }
|
||||
end
|
||||
|
||||
|
@ -100,7 +100,7 @@ RSpec.describe Dossiers::BatchAlertComponent, type: :component do
|
|||
|
||||
it { is_expected.to have_selector('.fr-alert--success') }
|
||||
it { is_expected.to have_text("L’action de masse est terminée") }
|
||||
it { is_expected.to have_text("2 dossiers ont été désarchivés") }
|
||||
it { is_expected.to have_text("2 dossiers ont été retirés de « à archiver »") }
|
||||
it { expect(batch_operation.seen_at).to eq(nil) }
|
||||
end
|
||||
|
||||
|
@ -113,7 +113,7 @@ RSpec.describe Dossiers::BatchAlertComponent, type: :component do
|
|||
|
||||
it { is_expected.to have_selector('.fr-alert--warning') }
|
||||
it { is_expected.to have_text("L’action de masse est terminée") }
|
||||
it { is_expected.to have_text("1/2 dossiers ont été désarchivés") }
|
||||
it { is_expected.to have_text("1/2 dossiers ont été retirés de « à archiver »") }
|
||||
it { expect(batch_operation.seen_at).to eq(nil) }
|
||||
|
||||
it 'on next render "seen_at" is set to avoid rendering alert' do
|
||||
|
@ -592,7 +592,7 @@ RSpec.describe Dossiers::BatchAlertComponent, type: :component do
|
|||
|
||||
it { is_expected.to have_selector('.fr-alert--info') }
|
||||
it { is_expected.to have_text("Une action de masse est en cours") }
|
||||
it { is_expected.to have_text("1/2 dossiers ont été supprimés") }
|
||||
it { is_expected.to have_text("1/2 dossiers ont été placés à la corbeille") }
|
||||
end
|
||||
|
||||
context 'finished and success' do
|
||||
|
@ -604,7 +604,7 @@ RSpec.describe Dossiers::BatchAlertComponent, type: :component do
|
|||
|
||||
it { is_expected.to have_selector('.fr-alert--success') }
|
||||
it { is_expected.to have_text("L’action de masse est terminée") }
|
||||
it { is_expected.to have_text("2 dossiers ont été supprimés") }
|
||||
it { is_expected.to have_text("2 dossiers ont été placés à la corbeille") }
|
||||
it { expect(batch_operation.seen_at).to eq(nil) }
|
||||
end
|
||||
|
||||
|
@ -617,7 +617,7 @@ RSpec.describe Dossiers::BatchAlertComponent, type: :component do
|
|||
|
||||
it { is_expected.to have_selector('.fr-alert--warning') }
|
||||
it { is_expected.to have_text("L’action de masse est terminée") }
|
||||
it { is_expected.to have_text("1/2 dossiers ont été supprimés") }
|
||||
it { is_expected.to have_text("1/2 dossiers ont été placés à la corbeille") }
|
||||
it { expect(batch_operation.seen_at).to eq(nil) }
|
||||
|
||||
it 'on next render "seen_at" is set to avoid rendering alert' do
|
||||
|
|
|
@ -905,7 +905,7 @@ describe API::V2::GraphqlController do
|
|||
let(:dossier) { create(:dossier, :en_instruction, :with_individual, procedure:) }
|
||||
|
||||
it {
|
||||
expect(gql_data[:dossierArchiver][:errors].first[:message]).to eq('Un dossier ne peut être archivé qu’une fois le traitement terminé')
|
||||
expect(gql_data[:dossierArchiver][:errors].first[:message]).to eq('Un dossier ne peut être déplacé dans « à archiver » qu’une fois le traitement terminé')
|
||||
}
|
||||
end
|
||||
end
|
||||
|
|
|
@ -46,6 +46,22 @@ describe Instructeurs::ProceduresController, type: :controller do
|
|||
let(:instructeur) { create(:instructeur) }
|
||||
subject { get :index }
|
||||
|
||||
describe 'tabs explanation' do
|
||||
render_views
|
||||
|
||||
before do
|
||||
sign_in(instructeur.user)
|
||||
subject
|
||||
end
|
||||
|
||||
it 'contains tabs explanation' do
|
||||
expect(response.body).to have_text('L’onglet « en cours » regroupe')
|
||||
expect(response.body).to have_text('L’onglet « en test » regroupe')
|
||||
expect(response.body).to have_text('L’onglet « terminée » regroupe')
|
||||
expect(response.body).not_to have_text('L’onglet « expirant » contient')
|
||||
end
|
||||
end
|
||||
|
||||
context "when not logged" do
|
||||
before { subject }
|
||||
it { expect(response).to redirect_to(new_user_session_path) }
|
||||
|
@ -97,7 +113,7 @@ describe Instructeurs::ProceduresController, type: :controller do
|
|||
it { expect(assigns(:dossiers_expirant_count_per_procedure)[procedure.id]).to eq(nil) }
|
||||
|
||||
it { expect(assigns(:all_dossiers_counts)['à suivre']).to eq(0) }
|
||||
it { expect(assigns(:all_dossiers_counts)['suivis']).to eq(0) }
|
||||
it { expect(assigns(:all_dossiers_counts)['suivis par moi']).to eq(0) }
|
||||
it { expect(assigns(:all_dossiers_counts)['traités']).to eq(0) }
|
||||
it { expect(assigns(:all_dossiers_counts)['dossiers']).to eq(0) }
|
||||
it { expect(assigns(:all_dossiers_counts)['expirant']).to eq(0) }
|
||||
|
@ -158,7 +174,7 @@ describe Instructeurs::ProceduresController, type: :controller do
|
|||
it { expect(assigns(:dossiers_count_per_procedure)[procedure3.id]).to eq(2) }
|
||||
|
||||
it { expect(assigns(:all_dossiers_counts)['à suivre']).to eq(3 + 0) }
|
||||
it { expect(assigns(:all_dossiers_counts)['suivis']).to eq(0 + 1) }
|
||||
it { expect(assigns(:all_dossiers_counts)['suivis par moi']).to eq(0 + 1) }
|
||||
it { expect(assigns(:all_dossiers_counts)['traités']).to eq(2 + 1 + 1 + 1) }
|
||||
it { expect(assigns(:all_dossiers_counts)['dossiers']).to eq(5 + 3 + 2 + 1) }
|
||||
it { expect(assigns(:all_dossiers_counts)['expirant']).to eq(2 + 0) }
|
||||
|
@ -220,7 +236,7 @@ describe Instructeurs::ProceduresController, type: :controller do
|
|||
it { expect(assigns(:dossiers_count_per_procedure)[procedure.id]).to eq(4 + 6 + 10) }
|
||||
|
||||
it { expect(assigns(:all_dossiers_counts)['à suivre']).to eq(4) }
|
||||
it { expect(assigns(:all_dossiers_counts)['suivis']).to eq(6) }
|
||||
it { expect(assigns(:all_dossiers_counts)['suivis par moi']).to eq(6) }
|
||||
it { expect(assigns(:all_dossiers_counts)['traités']).to eq(10) }
|
||||
it { expect(assigns(:all_dossiers_counts)['dossiers']).to eq(4 + 6 + 10) }
|
||||
end
|
||||
|
@ -239,7 +255,7 @@ describe Instructeurs::ProceduresController, type: :controller do
|
|||
it { expect(assigns(:dossiers_count_per_procedure)[procedure.id]).to eq(2 + 3 + 5) }
|
||||
|
||||
it { expect(assigns(:all_dossiers_counts)['à suivre']).to eq(2) }
|
||||
it { expect(assigns(:all_dossiers_counts)['suivis']).to eq(3) }
|
||||
it { expect(assigns(:all_dossiers_counts)['suivis par moi']).to eq(3) }
|
||||
it { expect(assigns(:all_dossiers_counts)['traités']).to eq(5) }
|
||||
it { expect(assigns(:all_dossiers_counts)['dossiers']).to eq(2 + 3 + 5) }
|
||||
end
|
||||
|
@ -260,6 +276,26 @@ describe Instructeurs::ProceduresController, type: :controller do
|
|||
get :show, params: { procedure_id: procedure.id, statut: statut }
|
||||
end
|
||||
|
||||
describe 'tabs explanation' do
|
||||
render_views
|
||||
|
||||
before do
|
||||
sign_in(instructeur.user)
|
||||
subject
|
||||
end
|
||||
|
||||
it 'contains tabs explanation' do
|
||||
expect(response.body).to have_text('L’onglet « à suivre » contient')
|
||||
expect(response.body).to have_text('L’onglet « suivis par moi» contient')
|
||||
expect(response.body).to have_text('L’onglet « traité » contient')
|
||||
expect(response.body).to have_text('L’onglet « au total » contient')
|
||||
expect(response.body).to have_text('L’onglet « corbeille » contient')
|
||||
expect(response.body).to have_text('L’onglet « à archiver » contient')
|
||||
expect(response.body).to have_text('L’onglet « expirant » contient')
|
||||
expect(response.body).not_to have_text('L’onglet « terminée » regroupe')
|
||||
end
|
||||
end
|
||||
|
||||
describe 'access to groupes_instructeur' do
|
||||
render_views
|
||||
let(:procedure) { create(:procedure, instructeurs_self_management_enabled:, instructeurs: [instructeur]) }
|
||||
|
|
|
@ -136,7 +136,7 @@ RSpec.describe DossierMailer, type: :mailer do
|
|||
|
||||
it 'checks email subject, to, and body for correct inclusions and exclusions for en_construction status' do
|
||||
expect(subject.to).to eq([hidden_dossier.user.email])
|
||||
expect(subject.subject).to eq("Un dossier a été supprimé de votre compte")
|
||||
expect(subject.subject).to eq("Un dossier de votre compte a été mis à la corbeille")
|
||||
expect(subject.body).to include("N° #{hidden_dossier.id} ")
|
||||
expect(subject.body).to include(hidden_dossier.procedure.libelle)
|
||||
end
|
||||
|
@ -149,7 +149,7 @@ RSpec.describe DossierMailer, type: :mailer do
|
|||
|
||||
it 'checks email subject, to, and body for correct inclusions and exclusions for termine status' do
|
||||
expect(subject.to).to eq([hidden_dossier.user.email])
|
||||
expect(subject.subject).to eq("Un dossier a été supprimé de votre compte")
|
||||
expect(subject.subject).to eq("Un dossier de votre compte a été mis à la corbeille")
|
||||
expect(subject.body).to include("N° #{hidden_dossier.id} ")
|
||||
expect(subject.body).to include(hidden_dossier.procedure.libelle)
|
||||
end
|
||||
|
@ -162,7 +162,7 @@ RSpec.describe DossierMailer, type: :mailer do
|
|||
subject { described_class.notify_automatic_deletion_to_administration([hidden_dossier], hidden_dossier.user.email) }
|
||||
|
||||
it 'verifies subject and body content for automatic deletion notification' do
|
||||
expect(subject.subject).to eq("Un dossier a été supprimé")
|
||||
expect(subject.subject).to eq("Un dossier a été mis à la corbeille")
|
||||
expect(subject.body).to include("n° #{hidden_dossier.id} (#{hidden_dossier.procedure.libelle})")
|
||||
end
|
||||
end
|
||||
|
|
|
@ -28,6 +28,10 @@ class DossierMailerPreview < ActionMailer::Preview
|
|||
DossierMailer.notify_brouillon_near_deletion([dossier, dossier], usager_email)
|
||||
end
|
||||
|
||||
def notify_brouillons_near_deletion_one
|
||||
DossierMailer.notify_brouillon_near_deletion([dossier], usager_email)
|
||||
end
|
||||
|
||||
def notify_en_construction_near_deletion_to_user
|
||||
DossierMailer.notify_near_deletion_to_user([dossier_en_construction], usager_email)
|
||||
end
|
||||
|
@ -65,7 +69,11 @@ class DossierMailerPreview < ActionMailer::Preview
|
|||
DossierMailer.notify_automatic_deletion_to_user([dossier, dossier], usager_email)
|
||||
end
|
||||
|
||||
def notify_automatic_deletion_to_administration
|
||||
def notify_automatic_deletion_to_administration_one
|
||||
DossierMailer.notify_automatic_deletion_to_administration([dossier], administration_email)
|
||||
end
|
||||
|
||||
def notify_automatic_deletion_to_administration_multiple
|
||||
DossierMailer.notify_automatic_deletion_to_administration([dossier, dossier], administration_email)
|
||||
end
|
||||
|
||||
|
|
|
@ -52,7 +52,7 @@ describe ProcedureExportService do
|
|||
"Dépôt pour un tiers",
|
||||
"Nom du mandataire",
|
||||
"Prénom du mandataire",
|
||||
"Archivé",
|
||||
"À archiver",
|
||||
"État du dossier",
|
||||
"Dernière mise à jour le",
|
||||
"Dernière mise à jour du dossier le",
|
||||
|
@ -190,7 +190,7 @@ describe ProcedureExportService do
|
|||
"Email",
|
||||
"FranceConnect ?",
|
||||
"Entreprise raison sociale",
|
||||
"Archivé",
|
||||
"À archiver",
|
||||
"État du dossier",
|
||||
"Dernière mise à jour le",
|
||||
"Dernière mise à jour du dossier le",
|
||||
|
@ -246,7 +246,7 @@ describe ProcedureExportService do
|
|||
"Association date de création",
|
||||
"Association date de déclaration",
|
||||
"Association date de publication",
|
||||
"Archivé",
|
||||
"À archiver",
|
||||
"État du dossier",
|
||||
"Dernière mise à jour le",
|
||||
"Dernière mise à jour du dossier le",
|
||||
|
|
|
@ -47,7 +47,7 @@ describe 'BatchOperation a dossier:', js: true do
|
|||
|
||||
# ensure alert is present
|
||||
expect(page).to have_content("Information : Une action de masse est en cours")
|
||||
expect(page).to have_content("1 dossier est en cours d'archivage")
|
||||
expect(page).to have_content("1 dossier est en cours de déplacement dans « à archiver »")
|
||||
|
||||
# ensure jobs are queued
|
||||
perform_enqueued_jobs(only: [BatchOperationEnqueueAllJob])
|
||||
|
@ -58,7 +58,7 @@ describe 'BatchOperation a dossier:', js: true do
|
|||
# ensure alert updates when jobs are run
|
||||
click_on "Recharger la page"
|
||||
expect(page).to have_content("L’action de masse est terminée")
|
||||
expect(page).to have_content("1 dossier a été archivé")
|
||||
expect(page).to have_content("1 dossier a été placé dans « à archiver »")
|
||||
|
||||
# clean alert after reload
|
||||
visit instructeur_procedure_path(procedure, statut: 'traites')
|
||||
|
|
|
@ -74,7 +74,7 @@ describe 'Instructing a dossier:', js: true do
|
|||
end
|
||||
|
||||
expect(page).to have_text('Dossier traité avec succès.')
|
||||
expect(page).to have_button('Archiver le dossier')
|
||||
expect(page).to have_button('Déplacer dans “à archiver“')
|
||||
|
||||
dossier.reload
|
||||
expect(dossier.state).to eq(Dossier.states.fetch(:accepte))
|
||||
|
@ -85,7 +85,7 @@ describe 'Instructing a dossier:', js: true do
|
|||
click_on procedure.libelle
|
||||
click_on 'traité'
|
||||
expect(page).to have_button('Repasser en instruction')
|
||||
click_on 'Supprimer le dossier'
|
||||
click_on 'Mettre à la corbeille'
|
||||
expect(page).not_to have_button('Repasser en instruction')
|
||||
end
|
||||
|
||||
|
@ -114,7 +114,7 @@ describe 'Instructing a dossier:', js: true do
|
|||
test_statut_bar(suivi: 1, tous_les_dossiers: 1)
|
||||
expect(page).to have_text('Aucun dossier')
|
||||
|
||||
click_on 'suivi'
|
||||
click_on 'suivi par moi'
|
||||
expect(page).to have_current_path(instructeur_procedure_path(procedure, statut: 'suivis'))
|
||||
dossier_present?(dossier.id, 'en construction')
|
||||
|
||||
|
@ -334,7 +334,7 @@ describe 'Instructing a dossier:', js: true do
|
|||
def test_statut_bar(a_suivre: 0, suivi: 0, traite: 0, tous_les_dossiers: 0, archive: 0)
|
||||
texts = [
|
||||
"#{a_suivre} à suivre",
|
||||
"#{suivi} suivi",
|
||||
"#{suivi} suivi par moi",
|
||||
"#{traite} traité",
|
||||
"#{tous_les_dossiers} au total",
|
||||
"à archiver"
|
||||
|
|
|
@ -214,7 +214,7 @@ describe 'The routing with rules', js: true do
|
|||
expect(find('nav.fr-tabs')).to have_css('span.notifications')
|
||||
|
||||
## on the dossier itself
|
||||
click_on 'suivi'
|
||||
click_on 'suivi par moi'
|
||||
click_on litteraire_user.email
|
||||
expect(page).to have_current_path(instructeur_dossier_path(procedure, litteraire_user.dossiers.first, statut: :suivis))
|
||||
expect(page).to have_text('Annotations privées')
|
||||
|
|
|
@ -179,9 +179,9 @@ describe 'user access to the list of their dossiers', js: true do
|
|||
|
||||
describe 'deletion' do
|
||||
it 'should have links to delete dossiers' do
|
||||
expect(page).to have_link('Supprimer le dossier', href: dossier_path(dossier_brouillon))
|
||||
expect(page).to have_link('Supprimer le dossier', href: dossier_path(dossier_en_construction))
|
||||
expect(page).not_to have_link('Supprimer le dossier', href: dossier_path(dossier_en_instruction))
|
||||
expect(page).to have_link('Mettre à la corbeille', href: dossier_path(dossier_brouillon))
|
||||
expect(page).to have_link('Mettre à la corbeille', href: dossier_path(dossier_en_construction))
|
||||
expect(page).not_to have_link('Mettre à la corbeille', href: dossier_path(dossier_en_instruction))
|
||||
end
|
||||
|
||||
context 'when user clicks on delete button' do
|
||||
|
@ -190,7 +190,7 @@ describe 'user access to the list of their dossiers', js: true do
|
|||
within(:css, ".card", match: :first) do
|
||||
click_on 'Autres actions'
|
||||
accept_alert('Confirmer la suppression ?') do
|
||||
click_on 'Supprimer le dossier'
|
||||
click_on 'Mettre à la corbeille'
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -221,7 +221,7 @@ describe 'user access to the list of their dossiers', js: true do
|
|||
|
||||
describe 'restore' do
|
||||
it 'should have links to restore dossiers' do
|
||||
click_on "3 supprimés"
|
||||
within('.fr-tabs__list') { click_on "corbeille" }
|
||||
expect(page).to have_link('Restaurer', href: restore_dossier_path(dossier_en_construction_supprime))
|
||||
expect(page).to have_button('Restaurer et étendre la conservation')
|
||||
expect(page).to have_link('Télécharger mon dossier', href: dossier_path("#{dossier_traite_expire.id}.pdf"))
|
||||
|
@ -229,29 +229,27 @@ describe 'user access to the list of their dossiers', js: true do
|
|||
|
||||
context 'when user clicks on restore button' do
|
||||
scenario 'the dossier is restored' do
|
||||
click_on "3 supprimés"
|
||||
within('.fr-tabs__list') { click_on "corbeille" }
|
||||
expect(page).to have_content(dossier_en_construction_supprime.procedure.libelle)
|
||||
click_on 'Restaurer'
|
||||
|
||||
expect(page).to have_content('Votre dossier a bien été restauré')
|
||||
expect(page).to have_content('2 supprimés')
|
||||
end
|
||||
end
|
||||
|
||||
context 'when user clicks on restore and extend button' do
|
||||
scenario 'the dossier is restored and extended' do
|
||||
click_on "3 supprimés"
|
||||
within('.fr-tabs__list') { click_on "corbeille" }
|
||||
expect(page).to have_content(dossier_en_construction_expire.procedure.libelle)
|
||||
click_on 'Restaurer et étendre la conservation'
|
||||
|
||||
expect(page).to have_content('Votre dossier sera conservé 3 mois supplémentaire')
|
||||
expect(page).to have_content('2 supprimés')
|
||||
end
|
||||
end
|
||||
|
||||
context 'when user download PDF of expired' do
|
||||
scenario "generate PDF" do
|
||||
click_on "3 supprimés"
|
||||
within('.fr-tabs__list') { click_on "corbeille" }
|
||||
click_on 'Télécharger mon dossier', match: :first
|
||||
# Test fails when an error happens during PDF generation
|
||||
end
|
||||
|
|
|
@ -105,9 +105,9 @@ describe 'instructeurs/dossiers/show', type: :view do
|
|||
expect(subject).to have_button('Repasser en instruction')
|
||||
end
|
||||
within("form[action=\"#{archive_instructeur_dossier_path(dossier.procedure, dossier)}\"]") do
|
||||
expect(subject).to have_button('Archiver le dossier')
|
||||
expect(subject).to have_button('Replacer dans“traités“')
|
||||
end
|
||||
expect(subject).to have_selector('[title^="Supprimer le dossier"]')
|
||||
expect(subject).to have_selector('[title^="Mettre à la corbeille"]')
|
||||
expect(subject).to have_selector('.header-actions ul:first-child .fr-btn', count: 3)
|
||||
end
|
||||
end
|
||||
|
@ -148,7 +148,7 @@ describe 'instructeurs/dossiers/show', type: :view do
|
|||
within("form[action=\"#{unarchive_instructeur_dossier_path(dossier.procedure, dossier)}\"]") do
|
||||
expect(subject).to have_button('Désarchiver le dossier')
|
||||
end
|
||||
expect(subject).to have_selector('[title^="Supprimer le dossier"]')
|
||||
expect(subject).to have_selector('[title^="Mettre à la corbeille"]')
|
||||
expect(subject).to have_selector('.header-actions ul:first-child .fr-btn', count: 2)
|
||||
end
|
||||
end
|
||||
|
|
|
@ -12,19 +12,19 @@ describe 'instructeurs/procedures/_synthese', type: :view do
|
|||
render 'instructeurs/procedures/synthese',
|
||||
all_dossiers_counts: {
|
||||
'à suivre': 0,
|
||||
'suivis': 0,
|
||||
'suivis par moi': 0,
|
||||
'traités': 1,
|
||||
'dossiers': 1,
|
||||
'archivés': 0
|
||||
'à archiver': 0
|
||||
},
|
||||
procedures: [procedure, procedure2]
|
||||
}
|
||||
|
||||
it { is_expected.to have_text('Synthèse des dossiers') }
|
||||
it { is_expected.not_to have_text('suivis') }
|
||||
it { is_expected.not_to have_text('suivis par moi') }
|
||||
it { is_expected.to have_text('traités') }
|
||||
it { is_expected.to have_text('dossiers') }
|
||||
it { is_expected.not_to have_text('archivés') }
|
||||
it { is_expected.not_to have_text('à archiver') }
|
||||
end
|
||||
|
||||
context 'when instructeur has 1 procedure and 1 file, table is not shown' do
|
||||
|
@ -32,18 +32,18 @@ describe 'instructeurs/procedures/_synthese', type: :view do
|
|||
render 'instructeurs/procedures/synthese',
|
||||
all_dossiers_counts: {
|
||||
'à suivre': 0,
|
||||
'suivis': 0,
|
||||
'suivis par moi': 0,
|
||||
'traités': 1,
|
||||
'dossiers': 1,
|
||||
'archivés': 0
|
||||
'à archiver': 0
|
||||
},
|
||||
procedures: [procedure]
|
||||
}
|
||||
|
||||
it { is_expected.not_to have_text('Synthèse des dossiers') }
|
||||
it { is_expected.not_to have_text('suivis') }
|
||||
it { is_expected.not_to have_text('suivis par moi') }
|
||||
it { is_expected.not_to have_text('traités') }
|
||||
it { is_expected.not_to have_text('dossiers') }
|
||||
it { is_expected.not_to have_text('archivés') }
|
||||
it { is_expected.not_to have_text('à archiver') }
|
||||
end
|
||||
end
|
||||
|
|
|
@ -8,12 +8,12 @@ describe 'users/dossiers/dossier_actions', type: :view do
|
|||
subject { render 'users/dossiers/dossier_actions', dossier: dossier, current_user: user }
|
||||
|
||||
it { is_expected.to have_link('Commencer un nouveau dossier', href: commencer_url(path: procedure.path)) }
|
||||
it { is_expected.to have_link('Supprimer le dossier', href: dossier_path(dossier)) }
|
||||
it { is_expected.to have_link('Mettre à la corbeille', href: dossier_path(dossier)) }
|
||||
it { is_expected.to have_link('Transférer le dossier', href: transferer_dossier_path(dossier)) }
|
||||
|
||||
context 'when the dossier is termine' do
|
||||
let(:dossier) { create(:dossier, :accepte, procedure: procedure) }
|
||||
it { is_expected.to have_link('Supprimer le dossier') }
|
||||
it { is_expected.to have_link('Mettre à la corbeille') }
|
||||
end
|
||||
|
||||
context 'when the procedure is closed' do
|
||||
|
|
|
@ -107,7 +107,7 @@ describe 'users/dossiers/index', type: :view do
|
|||
let(:dossiers_traites) { create_list(:dossier, 1) }
|
||||
|
||||
it "displays the hide by user at button" do
|
||||
expect(rendered).to have_text("Supprimer le dossier")
|
||||
expect(rendered).to have_text("Mettre à la corbeille")
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue