Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[7571] On the BanneredCampaignPage, only show root page title if the … #7637

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions network-api/networkapi/wagtailpages/pagemodels/campaigns.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,7 @@
from .modular import MiniSiteNameSpace
from .primary import PrimaryPage
from .mixin.foundation_metadata import FoundationMetadataPageMixin
from ..utils import (
get_page_tree_information,
get_content_related_by_tag
)
from ..utils import get_content_related_by_tag


class CTA(models.Model):
Expand Down Expand Up @@ -347,7 +344,7 @@ class BanneredCampaignPage(PrimaryPage):
def get_context(self, request):
context = super().get_context(request)
context['related_posts'] = get_content_related_by_tag(self)
return get_page_tree_information(self, context)
Pomax marked this conversation as resolved.
Show resolved Hide resolved
return context

class Meta:
verbose_name = "Banner Page"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ <h1 class="h1-heading">{{ page.hero_headline }}</h1>
<div class="container">
<div class="row cutout-wrapper-row">
<div class="cutout col-12 col-lg-8 pt-4">
<h1 class="h1-heading mb-0">{% if root.title %}{{ root.title }}{% elif page.header %}{{ page.header }}{% else %}{{ page.title }}{% endif %}</h1>
<h1 class="h1-heading mb-0">{% if uses_menu and root.title %}{{ root.title }}{% else %}{{ page.title }}{% endif %}</h1>
{% if page.intro %}
<p class="body-large mt-3 mb-0">{{ page.intro }}</p>
{% endif %}
Expand Down