From a93a741238064ad624b6147d88c057e6bf85b13d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20P=C3=A9ters?= <fpeters@entrouvert.com>
Date: Tue, 26 Mar 2019 10:21:46 +0100
Subject: [PATCH] templates: do not include password registration block along
 others (#31718)

---
 templates/registration/registration_form.html                   | 2 ++
 .../grenoble-metropole-2019/registration/registration_form.html | 2 ++
 .../grenoble-metropole/registration/registration_form.html      | 2 ++
 .../variants/montpellier/registration/registration_form.html    | 2 ++
 .../strasbourg-2018/registration/registration_form.html         | 2 ++
 templates/variants/toulouse/registration/registration_form.html | 2 +-
 6 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/templates/registration/registration_form.html b/templates/registration/registration_form.html
index 73c42cf6..18f98113 100644
--- a/templates/registration/registration_form.html
+++ b/templates/registration/registration_form.html
@@ -33,6 +33,7 @@ pour ouvrir votre compte.
 
 {% block registration-other-methods %}
 {% for id, block in frontends.items %}
+  {% if id != "password" %}
   <div id="frontend-registration-{{ id }}" class="a2-block">
     <h2>{{ block.name }}</h2>
 
@@ -40,6 +41,7 @@ pour ouvrir votre compte.
       {{ block.content|safe }}
     </div>
   </div>
+  {% endif %}
 {% endfor %}
 {% endblock %}
 
diff --git a/templates/variants/grenoble-metropole-2019/registration/registration_form.html b/templates/variants/grenoble-metropole-2019/registration/registration_form.html
index 4aee6ac4..f1c6dc3b 100644
--- a/templates/variants/grenoble-metropole-2019/registration/registration_form.html
+++ b/templates/variants/grenoble-metropole-2019/registration/registration_form.html
@@ -14,6 +14,7 @@
 </div>
 
 {% for id, block in frontends.items %}
+  {% if id != "password" %}
   <div id="frontend-registration-{{ id }}" class="a2-block">
     <h2>{{ block.name }}</h2>
 
@@ -21,6 +22,7 @@
       {{ block.content|safe }}
     </div>
   </div>
+  {% endif %}
 {% endfor %}
 
 {% endblock %}
diff --git a/templates/variants/grenoble-metropole/registration/registration_form.html b/templates/variants/grenoble-metropole/registration/registration_form.html
index 4aee6ac4..f1c6dc3b 100644
--- a/templates/variants/grenoble-metropole/registration/registration_form.html
+++ b/templates/variants/grenoble-metropole/registration/registration_form.html
@@ -14,6 +14,7 @@
 </div>
 
 {% for id, block in frontends.items %}
+  {% if id != "password" %}
   <div id="frontend-registration-{{ id }}" class="a2-block">
     <h2>{{ block.name }}</h2>
 
@@ -21,6 +22,7 @@
       {{ block.content|safe }}
     </div>
   </div>
+  {% endif %}
 {% endfor %}
 
 {% endblock %}
diff --git a/templates/variants/montpellier/registration/registration_form.html b/templates/variants/montpellier/registration/registration_form.html
index f0331ce5..bde4cf02 100644
--- a/templates/variants/montpellier/registration/registration_form.html
+++ b/templates/variants/montpellier/registration/registration_form.html
@@ -19,9 +19,11 @@
    </form>
   </div>
   {% for id, block in frontends.items %}
+  {% if != "password" %}
   <div>
     {{ block.content|safe }}
   </div>
+  {% endif %}
   {% endfor %}
 </div>
 
diff --git a/templates/variants/strasbourg-2018/registration/registration_form.html b/templates/variants/strasbourg-2018/registration/registration_form.html
index 1c585aa5..0376adc0 100644
--- a/templates/variants/strasbourg-2018/registration/registration_form.html
+++ b/templates/variants/strasbourg-2018/registration/registration_form.html
@@ -19,12 +19,14 @@
 </div>
 
 {% for id, block in frontends.items %}
+  {% if id != "password" %}
   <div class="registration_frontend">
     <h3>S'inscrire avec {{ block.name }}</h3>
     <p>
       {{ block.content|safe }}
     </p>
   </div>
+  {% endif %}
 {% endfor %}
 
 {% endblock %}
diff --git a/templates/variants/toulouse/registration/registration_form.html b/templates/variants/toulouse/registration/registration_form.html
index ae2e5bec..2ef5a545 100644
--- a/templates/variants/toulouse/registration/registration_form.html
+++ b/templates/variants/toulouse/registration/registration_form.html
@@ -3,7 +3,7 @@
 
 {% block registration-pre %}
 <div class="a2-block" id="registration-title"><h2>S'inscrire</h2>
-{% if frontends.items|length %}
+{% if frontends.items|length > 1 %}
 <p>Pour accéder à ces téléservices, vous devez vous identifier en
 choisissant l'une des possibilités ci-dessous :</p>
 {% else %}
-- 
2.20.1

