Commit fd950c65 authored by Mat's avatar Mat

form commande flash message

parent 91f48f55
......@@ -99,6 +99,7 @@ class MembreController extends MasterController
$em = $this->getDoctrine()->getManager();
$em->persist($commande);
$em->flush();
$this->addFlash('success', 'Votre commande a bien été enregistrée.');
}
......
......@@ -31,4 +31,12 @@
<button type="button" class="btn btn-lg btn-block btn-primary float-right">Envoyer la commande</button>
{{ form(formCommande) }}
\ No newline at end of file
{% for label, messages in app.flashes() %}
{% for message in messages %}
<div class="flash-{{ label }}">
{{ message }}
</div>
{% endfor %}
{% endfor %}
{{ form(formCommande) }}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment