This commit is contained in:
Kara Diaby 2024-03-15 16:41:30 +00:00
parent e9fab486fb
commit e824118aea
4 changed files with 107 additions and 0 deletions

View file

@ -0,0 +1,60 @@
.sub-header
.fr-container.flex
.procedure-logo{ style: "background-image: url(#{@procedure.logo_url})",
role: 'img', 'aria-label': "logo de la démarche #{@procedure.libelle}" }
.procedure-header
%h1.fr-h3= procedure_libelle @procedure
.container
%h1.fr-h3
= t('.title')
= form_for @expert_procedure, url: update_notification_settings_expert_procedure_path(@procedure), html: { class: 'form' } do |form|
= render Dsfr::AlertComponent.new(state: :info, size: :sm, extra_class_names: 'fr-mb-2w') do |c|
- c.with_body do
%p
= t('.subtitle', procedure_libelle: @procedure.libelle)
%fieldset.fr-fieldset
%legend.fr-fieldset__legend
= t(".for_each_avis_submitted.title")
%span.fr-hint-text= t('.for_each_avis_submitted.notice_1')
%span.fr-hint-text= t('.for_each_avis_submitted.notice_2')
.fr-fieldset__element.fr-fieldset__element--inline
.fr-radio-group
= form.radio_button :notify_on_new_avis, true, id: 'notify_on_new_avis_true'
%label.fr-label{ for: 'notify_on_new_avis_true' }
= t('.utils.positive')
.fr-fieldset__element.fr-fieldset__element--inline
.fr-radio-group
= form.radio_button :notify_on_new_avis, false, id: 'notify_on_new_avis_false'
%label.fr-label{ for: 'notify_on_new_avis_false' }
= t('.utils.negative')
%fieldset.fr-fieldset
%legend.fr-fieldset__legend
= t(".for_each_message_submitted.title")
%span.fr-hint-text= t('.for_each_message_submitted.notice_1')
%span.fr-hint-text= t('.for_each_message_submitted.notice_2')
.fr-fieldset__element.fr-fieldset__element--inline
.fr-radio-group
= form.radio_button :notify_on_new_message, true, id: 'notify_on_new_message_true'
%label.fr-label{ for: 'notify_on_new_message_true' }
= t('.utils.positive')
.fr-fieldset__element.fr-fieldset__element--inline
.fr-radio-group
= form.radio_button :notify_on_new_message, false, id: 'notify_on_new_message_false'
%label.fr-label{ for: 'notify_on_new_message_false' }
= t('.utils.negative')
.send-wrapper
= link_to t('.buttons.back_to_procedure', procedure_id: @procedure.id), procedure_expert_avis_index_path(@procedure), class: 'fr-btn fr-btn--secondary fr-mr-2w'
= form.submit t('.buttons.save'), class: "fr-btn"

View file

@ -10,6 +10,9 @@
.procedure-header
%h1.fr-h3= procedure_libelle @procedure
= link_to t('.management', procedure_id: @procedure.id), notification_settings_expert_procedure_path(@procedure), class: 'header-link'
%nav.fr-tabs
%ul.fr-tabs__list{ role: 'tablist' }

View file

@ -0,0 +1,22 @@
en:
experts:
avis:
procedure:
management: notification management of the procedure %{procedure_id}
notification_settings:
utils:
positive: Yes
negative: No
title: Email Notifications
subtitle: "Configure on this page the notifications you wish to receive by email for: %{procedure_libelle}"
for_each_avis_submitted:
title: Receive a notification for each avis requested from you
notice_1: This email alerts you that an avis is requested from you.
notice_2: It is sent each time an instructor asks you for an avis.
for_each_message_submitted:
title: Receive a notification for each message received
notice_1: This email notifies you that a new message is available in the messaging system.
notice_2: It is sent every time an instructor or user sends a message.
buttons:
back_to_procedure: Return to the procedure notices %{procedure_id}
save: Save

View file

@ -0,0 +1,22 @@
fr:
experts:
avis:
procedure:
management: gestion des notifications de la démarche %{procedure_id}
notification_settings:
utils:
positive: Oui
negative: Non
title: Notifications par email
subtitle: "Configurez sur cette page les notifications que vous souhaitez recevoir par email pour : %{procedure_libelle}"
for_each_avis_submitted:
title: Recevoir une notification à chaque avis qui vous est demandé
notice_1: Cet email vous signale qu'un avis vous est demandé.
notice_2: Il est envoyé à chaque fois quun instructeur vous demande un avis.
for_each_message_submitted:
title: Recevoir une notification à chaque message reçu
notice_1: Cet email vous signale qu'un nouveau message est disponible dans la messagerie.
notice_2: Il est envoyé à chaque fois quun instructeur ou usager envoie un message.
buttons:
back_to_procedure: Revenir sur les avis de la démarche %{procedure_id}
save: Enregistrer