diff --git a/network-api/networkapi/wagtailpages/templates/buyersguide/catalog.html b/network-api/networkapi/wagtailpages/templates/buyersguide/catalog.html index 264466041a7..615bfe0556f 100644 --- a/network-api/networkapi/wagtailpages/templates/buyersguide/catalog.html +++ b/network-api/networkapi/wagtailpages/templates/buyersguide/catalog.html @@ -68,13 +68,13 @@

{{ page.header }}

{# User is not logged in. Return cached results. 24 hour caching applied. #} {% cache 86400 pni_home_page template_cache_key_fragment %} {% for product in products %} - {% include "../fragments/buyersguide_item.html" with product=product %} + {% include "../fragments/buyersguide_item.html" with product=product.localized %} {% endfor %} {% endcache %} {% else %} {# User is logged in. Don't cache their results so they can see live and draft products here. #} {% for product in products %} - {% include "../fragments/buyersguide_item.html" with product=product %} + {% include "../fragments/buyersguide_item.html" with product=product.localized %} {% endfor %} {% endif %} diff --git a/network-api/networkapi/wagtailpages/templates/fragments/chapter_table_of_contents.html b/network-api/networkapi/wagtailpages/templates/fragments/chapter_table_of_contents.html index 0e4b563774c..a24105c747b 100644 --- a/network-api/networkapi/wagtailpages/templates/fragments/chapter_table_of_contents.html +++ b/network-api/networkapi/wagtailpages/templates/fragments/chapter_table_of_contents.html @@ -23,7 +23,7 @@

{{ page.contents_title }}

{% for child_page in child_pages %} - {% with child=child_page.child %} + {% with child=child_page.child.localized %}
 
diff --git a/network-api/networkapi/wagtailpages/templates/fragments/publication_table_of_contents.html b/network-api/networkapi/wagtailpages/templates/fragments/publication_table_of_contents.html index 236ce143ed0..8ee57fcbeed 100644 --- a/network-api/networkapi/wagtailpages/templates/fragments/publication_table_of_contents.html +++ b/network-api/networkapi/wagtailpages/templates/fragments/publication_table_of_contents.html @@ -21,7 +21,7 @@

{{ page.contents_title }}

{% for child_page in child_pages %} - {% with child=child_page.child %} + {% with child=child_page.child.localized %}
{{ grandchild.title }} + {% endwith %} {% endfor %}
{% if child_page.grandchildren %} {# Child listings on mobile. #}
- {% for grandchild in child_page.grandchildren %} + {% for ancestor in child_page.grandchildren %} + {% with grandchild=ancestor.localized %}

{{ grandchild.title }} {% if child.has_unpublished_changes %}🐣{% endif %}

+ {% endwith %} {% endfor %}
{% endif %} diff --git a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/cause_statement.html b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/cause_statement.html index e791d009cf7..7574544edc5 100644 --- a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/cause_statement.html +++ b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/cause_statement.html @@ -3,7 +3,7 @@

{{ page.cause_statement }}

{% if page.cause_statement_link_text and page.cause_statement_link_page %} - {{page.cause_statement_link_text}} + {{page.cause_statement_link_text}} {% endif %}
diff --git a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/focus_area.html b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/focus_area.html index f7b91b03673..4e3da28f459 100644 --- a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/focus_area.html +++ b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/focus_area.html @@ -8,7 +8,7 @@

{{ area.name }}

{{ area.description }}

{% if area.page %}{% endif %}
diff --git a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/news_you_can_use.html b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/news_you_can_use.html index 7889592aa3b..37834b9fa4f 100644 --- a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/news_you_can_use.html +++ b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/news_you_can_use.html @@ -23,7 +23,7 @@

{% trans "News you can use" %}

{% endcomment %} - {% with first=items.first.blog %} + {% with first=items.first.blog.localized %}
@@ -56,22 +56,24 @@

{{ first.title }}

{% with item_1_class="d-xl-none mb-5 mb-xl-0" item_2_class="mb-5 mb-xl-0" item_3_class="mb-5 mb-md-0" %} {% for item in items %} + {% with localized=item.blog.localized %}
- +
- {% if item.blog.category.count %} - {% with category=item.blog.category.first %} + {% if localized.category.count %} + {% with category=localized.category.first %} {{ category }} {% endwith %} {% else %}
 
{% endif %} -

{{ item.blog.title }}

+

{{ localized.title }}

{% include "./blog_authors.html" with blog_page=item.blog %}
+ {% endwith %} {% endfor %} {% endwith %} diff --git a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/partner.html b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/partner.html index 1e1d3c74a45..59124b998cf 100644 --- a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/partner.html +++ b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/partner.html @@ -11,7 +11,7 @@

{{ page.partner_heading }}

{{ page.partner_intro_text }}

{% endif %} - + {{ page.partner_page_text }}
diff --git a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/publication_hero.html b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/publication_hero.html index 0d08f126f6f..94343d02bf7 100644 --- a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/publication_hero.html +++ b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/publication_hero.html @@ -14,9 +14,11 @@
{% if is_publication_article or is_publication_page %}
- {% for parent_page in self.breadcrumb_list %} + {% for entry in self.breadcrumb_list %} + {% with parent_page=entry.localized %} {{ parent_page.title }} + {% endwith %} {% endfor %}
{% endif %} diff --git a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/spotlight_posts.html b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/spotlight_posts.html index 950aedf0965..82510d7043a 100644 --- a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/spotlight_posts.html +++ b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/spotlight_posts.html @@ -13,12 +13,14 @@

{{ page.spotlight_headline }}

{% for post in page.spotlight_posts.all %} + {% with localized=post.blog.localized %}

- {{post.blog.title}} + {{localized.title}}

- {% include "./blog_authors.html" with blog_page=post.blog %} + {% include "./blog_authors.html" with blog_page=localized %}
+ {% endwith %} {% endfor %}
diff --git a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/take_action.html b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/take_action.html index 930bc697b6e..4065d43b4e2 100644 --- a/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/take_action.html +++ b/network-api/networkapi/wagtailpages/templates/wagtailpages/fragments/take_action.html @@ -9,18 +9,20 @@

{{ page.take_action_title }}

{% for item in page.take_action_cards.all %} + {% with target=item.internal_link.localized %} + {% endwith %} {% endfor %}