8 changed files with 103 additions and 4 deletions
@ -0,0 +1,17 @@
|
||||
<div class="govuk-grid-row"> |
||||
<p class="govuk-!-font-weight-bold"><%== I18n.t("active_notifications", count: Notification.active.count) %></p> |
||||
<% Notification.active.each do |notification| %> |
||||
<div class="govuk-grid-row"> |
||||
<div class="govuk-grid-column-three-quarters"> |
||||
<%== render_for_home(notification) %> |
||||
</div> |
||||
<div class="govuk-grid-column-one-quarter"> |
||||
<%= govuk_link_to("Delete notification", notification_delete_confirmation_path(notification)) %> |
||||
</div> |
||||
</div> |
||||
<% end %> |
||||
</div> |
||||
|
||||
<div class="govuk-grid-row"> |
||||
<%= govuk_button_link_to "Create a new notification", new_notification_path %> |
||||
</div> |
||||
@ -0,0 +1,27 @@
|
||||
<% content_for :before_content do %> |
||||
<% content_for :title, "Are you sure you want to delete this notification?" %> |
||||
<%= govuk_back_link(href: :back) %> |
||||
<% end %> |
||||
|
||||
<div class="govuk-grid-row"> |
||||
<div class="govuk-grid-column-two-thirds-from-desktop"> |
||||
<h1 class="govuk-heading-xl"> |
||||
<%= content_for(:title) %> |
||||
</h1> |
||||
|
||||
<p class="govuk-body"><%== render_for_summary("**Notification:** #{@notification.title}") %></p> |
||||
|
||||
<p class="govuk-body">Users will no longer see this notification.</p> |
||||
|
||||
<%= govuk_warning_text(text: "You will not be able to undo this action.") %> |
||||
|
||||
<div class="govuk-button-group"> |
||||
<%= govuk_button_to( |
||||
"Delete notification", |
||||
notification_delete_path(@notification), |
||||
method: :delete, |
||||
) %> |
||||
<%= govuk_button_link_to "Cancel", root_path, html: { method: :get }, secondary: true %> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
Loading…
Reference in new issue