diff --git a/app/presenters/corporate_information_page_presenter.rb b/app/presenters/corporate_information_page_presenter.rb index 252146e14..b789b9466 100644 --- a/app/presenters/corporate_information_page_presenter.rb +++ b/app/presenters/corporate_information_page_presenter.rb @@ -5,6 +5,12 @@ class CorporateInformationPagePresenter < ContentItemPresenter include ContentItem::OrganisationBranding include ContentItem::CorporateInformationGroups + ORG_CHANGING_BANNER_BASE_PATHS = %w[ + /government/organisations/department-for-business-energy-and-industrial-strategy/about + /government/organisations/department-for-international-trade/about + /government/organisations/department-for-business-energy-and-industrial-strategy/about + ].freeze + def page_title page_title = super page_title += " - #{default_organisation['title']}" if default_organisation @@ -22,6 +28,10 @@ def contents_items super + extra_headings end + def show_organisation_changing_banner? + ORG_CHANGING_BANNER_BASE_PATHS.include?(base_path) + end + private def extra_headings diff --git a/app/views/content_items/corporate_information_page.html.erb b/app/views/content_items/corporate_information_page.html.erb index e3e9982cf..bdf91e4b3 100644 --- a/app/views/content_items/corporate_information_page.html.erb +++ b/app/views/content_items/corporate_information_page.html.erb @@ -4,6 +4,15 @@ ) %> <% end %> +<% if @content_item.show_organisation_changing_banner? %> +