demarches-normaliennes/app/views/new_administrateur/procedure_administrateurs/create.js.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

9 lines
358 B
Text

= render_flash(sticky: true)
- if @administrateur
= append_to_element("#procedure-#{@procedure.id}-administrateurs",
partial: 'administrateur',
locals: { administrateur: @administrateur })
= render_to_element("#procedure-#{@procedure.id}-new_administrateur",
partial: 'add_admin_form',
outer: true,
locals: { procedure: @procedure })