Adapt configuration email view to the new UI
This commit is contained in:
parent
759298ddfa
commit
9b66c894b2
5 changed files with 35 additions and 12 deletions
|
@ -2,6 +2,10 @@ module NewAdministrateur
|
|||
class MailTemplatesController < AdministrateurController
|
||||
include ActionView::Helpers::SanitizeHelper
|
||||
|
||||
def index
|
||||
@mail_templates = mail_templates
|
||||
end
|
||||
|
||||
def preview
|
||||
mail_template = find_mail_template_by_slug(params[:id])
|
||||
dossier = Dossier.new(id: '1', procedure: procedure)
|
||||
|
|
13
app/views/new_administrateur/mail_templates/index.html.haml
Normal file
13
app/views/new_administrateur/mail_templates/index.html.haml
Normal file
|
@ -0,0 +1,13 @@
|
|||
= render partial: 'new_administrateur/breadcrumbs',
|
||||
locals: { steps: [link_to('Démarches', admin_procedures_path),
|
||||
link_to("#{@procedure.libelle}", admin_procedure_path(@procedure)), "Configuration des emails"] }
|
||||
|
||||
.container
|
||||
- @mail_templates.each do |mail_template|
|
||||
.card
|
||||
.flex.justify-between
|
||||
%div
|
||||
.card-title= mail_template.class.const_get(:DISPLAYED_NAME)
|
||||
%p.notice= mail_template.class.const_get(:DISPLAYED_NAME) === 'Accusé de réception' ? 'Personnalisé' : 'Modèle standard'
|
||||
%div
|
||||
= link_to 'Modifier', edit_admin_procedure_mail_template_path(@procedure, mail_template.class.const_get(:SLUG)), class: 'button'
|
Loading…
Add table
Add a link
Reference in a new issue