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

Add notification banner to inform users of service outage #855

Merged
merged 1 commit into from
Sep 27, 2024

Conversation

richardpattinson
Copy link
Contributor

@richardpattinson richardpattinson commented Sep 26, 2024

Context

As part of the scheduled upgrade to AKS we will need to take the AYTQ/CTR down for an hour. This has been scheduled for monday 30th. A notification banner should be raised to notify users.

Changes proposed in this pull request

Screenshot 2024-09-26 at 21 26 23

Guidance to review

Link to Trello card

Checklist

  • Attach to Trello card
  • Rebased main
  • Cleaned commit history
  • Tested by running locally

@richardpattinson richardpattinson force-pushed the notification-banner-site-disruption branch from 81ca7f6 to 1e3ef2b Compare September 26, 2024 20:33
Comment on lines 37 to 39
<%= render(FlashMessageComponent.new(flash: {
"info" => ["Scheduled service downtime", "The service will be unavailable on Monday 30th September after 5pm while scheduled upgrades are performed"]
})) %>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the wrong component to use. This isn't a flash message.

Just call the govuk_notification_banner method directly. See the docs for details on how to use it.

Also, we should wrap this in a feature flag so we have better control of the visibility.

Suggested change
<%= render(FlashMessageComponent.new(flash: {
"info" => ["Scheduled service downtime", "The service will be unavailable on Monday 30th September after 5pm while scheduled upgrades are performed"]
})) %>
<% if FeatureFlags::FeatureFlag.active?(:downtime_banner)
<%= govuk_notification_banner title: "Schedule service downtime", text: "The service will be unavailable on Monday 30th September after 5pm while scheduled upgrades are performed" %>
<% end %>

Copy link
Contributor

@felixclack felixclack left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a comment about using the correct component.

@richardpattinson richardpattinson force-pushed the notification-banner-site-disruption branch 2 times, most recently from ed3abef to 7e35a9b Compare September 27, 2024 09:33
@@ -34,6 +34,8 @@
<%= govuk_back_link(href: yield(:back_link_url)) if content_for?(:back_link_url) %>
<%= yield(:breadcrumbs) if content_for?(:breadcrumbs) %>
<main class="govuk-main-wrapper" id="main-content" role="main">
<% if FeatureFlags::FeatureFlag.active?(:downtime_banner) %>
<%= govuk_notification_banner title: "Planned downtime", text: "The service will be unavailable on Monday 30th September between 6pm and 7pm while we carry out essential maintenance" %> <% end %>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: The end should be on it's own line.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@richardpattinson richardpattinson force-pushed the notification-banner-site-disruption branch from 7e35a9b to d02fca6 Compare September 27, 2024 11:52
@richardpattinson richardpattinson merged commit 4acea8c into main Sep 27, 2024
15 checks passed
@richardpattinson richardpattinson deleted the notification-banner-site-disruption branch September 27, 2024 11:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants