demarches-normaliennes/app/views/new_administrateur/procedure_administrateurs/index.html.haml
Nicolas Bouilleaud 8e04b4f0c9 Clear the “add admin” field after submit
Extract the add_admin form to its own partial and re-render it when an admin is successfully added.
2019-06-12 16:58:30 +02:00

18 lines
689 B
Text

= render partial: 'new_administrateur/breadcrumbs',
locals: { steps: [link_to('Démarches', admin_procedures_path),
link_to(@procedure.libelle, admin_procedure_path(@procedure)),
'Administrateurs'], preview: false }
.container
%h1 Administrateurs de « #{@procedure.libelle} »
%table.table
%thead
%th= 'Adresse email'
%th= 'Enregistré le'
%th= 'État'
%tbody{ id: "procedure-#{@procedure.id}-administrateurs" }
= render partial: 'administrateur', collection: @procedure.administrateurs.order(:email)
%tfoot
%tr
%th{ colspan: 4 }
= render 'add_admin_form', procedure: @procedure