]> git.parisson.com Git - mezzo.git/commitdiff
Move the descendant pages in the page_content block
authorJérémy Fabre <blackmagik88@gmail.com>
Wed, 27 Jul 2016 14:20:51 +0000 (16:20 +0200)
committerJérémy Fabre <blackmagik88@gmail.com>
Wed, 27 Jul 2016 14:20:51 +0000 (16:20 +0200)
app/templates/pages/basicpage.html
app/templates/pages/department.html
app/templates/pages/team.html

index 19735373642b99d253e84f5a03154b8f3125870b..821500880f3481bc9518b8418a296f0ff0aee3e6 100644 (file)
         {{ page.basicpage.content|richtext_filters|safe }}
     {% endeditable %}
 
+    {% if page.get_ascendants|length == 1 %}
+        {% children_pages page.id as childrens %}
+        {% if childrens %}
+            {% for children in childrens %}
+                {% with children as object %}
+                    {% include "pages/includes/page_card.html" %}
+                {% endwith %}
+            {% endfor %}
+        {% endif %}
+    {% endif %}
+
     {% comment %}
         Add the slider here
     {% endcomment %}
 {% block main %}
     {{ block.super }}
 
-    {% if page.get_ascendants|length == 1 %}
-        {% children_pages page.id as childrens %}
-        {% if childrens %}
-            <div class="container">
-                <div class="row">
-                    {% for children in childrens %}
-                        <div class="col-sm-9 col-sm-push-3 col-lg-8 col-lg-push-2">
-                            {% with children as object %}
-                                {% include "pages/includes/page_card.html" %}
-                            {% endwith %}
-                        </div>
-                    {% endfor %}
-                </div>
-            </div>
-        {% endif %}
-    {% endif %}
-
     {% if page.basicpage.pageblock_set.all %}
         <div class="white-bg">
             <div class="container">
index 96e310e81aaf425e31837eafb8da402632145b17..570ca61d5747f955044215ec433b33151cf646af 100644 (file)
         {{ page.department.content|richtext_filters|safe }}
     {% endeditable %}
 
+    {% if page.get_ascendants|length == 1 %}
+        {% children_pages page.id as childrens %}
+        {% if childrens %}
+            {% for children in childrens %}
+                {% with children as object %}
+                    {% include "pages/includes/page_card.html" %}
+                {% endwith %}
+            {% endfor %}
+        {% endif %}
+    {% endif %}
+
     {% comment %}
         Add the slider here
     {% endcomment %}
index f0f331ee797714816db136af6ee44c65051959a3..d7bf846d15adc92d6773bdf412e9037e35b95d27 100644 (file)
         {{ page.team.content|richtext_filters|safe }}
     {% endeditable %}
 
+    {% if page.get_ascendants|length == 1 %}
+        {% children_pages page.id as childrens %}
+        {% if childrens %}
+            {% for children in childrens %}
+                {% with children as object %}
+                    {% include "pages/includes/page_card.html" %}
+                {% endwith %}
+            {% endfor %}
+        {% endif %}
+    {% endif %}
+
     {% comment %}
         Add the slider here
     {% endcomment %}