Submit social housing lettings and sales data (CORE)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

95 lines
3.8 KiB

<!DOCTYPE html>
<html lang="en" class="govuk-template">
<head>
<title><%= browser_title(yield(:title), @pagy, @admin_user, @user, @organisation, @case_log, @resource) %></title>
<%= csrf_meta_tags %>
<%= csp_meta_tag %>
<%= tag.meta name: "viewport", content: "width=device-width, initial-scale=1" %>
<%= tag.meta property: "og:image", content: asset_path("images/govuk-opengraph-image.png") %>
<%= tag.meta name: "theme-color", content: "#0b0c0c" %>
<%= favicon_link_tag asset_path("images/favicon.ico") %>
<%= favicon_link_tag asset_path("images/govuk-mask-icon.svg"), rel: "mask-icon", type: "image/svg", color: "#0b0c0c" %>
<%= favicon_link_tag asset_path("images/govuk-apple-touch-icon.png"), rel: "apple-touch-icon", type: "image/png" %>
<%= favicon_link_tag asset_path("images/govuk-apple-touch-icon-152x152.png"), rel: "apple-touch-icon", type: "image/png", size: "152x152" %>
<%= favicon_link_tag asset_path("images/govuk-apple-touch-icon-167x167.png"), rel: "apple-touch-icon", type: "image/png", size: "167x167" %>
<%= favicon_link_tag asset_path("images/govuk-apple-touch-icon-180x180.png"), rel: "apple-touch-icon", type: "image/png", size: "180x180" %>
<%= stylesheet_link_tag "application" %>
<%= javascript_include_tag "vendor/html5shiv.min.js" %>
<script>
window.html5.elements = "output";
html5.shivDocument(document);
</script>
<%= javascript_include_tag "vendor/polyfill-output-value.js" %>
<%= javascript_include_tag "vendor/outerHTML.js" %>
<%= javascript_include_tag "application", defer: true %>
<% if content_for?(:head) %>
<%= yield(:head) %>
<% end %>
<%= capybara_lockstep if defined?(Capybara::Lockstep) %>
<% if Rails.env.development? %>
<script>
console.log(<%= session.to_json.html_safe %>)
</script>
<% end %>
</head>
3 years ago
<body class="govuk-template__body app-template--wide">
<script>
document.body.className = ((document.body.className) ? document.body.className + " js-enabled" : "js-enabled");
</script>
<%= govuk_skip_link %>
<%= govuk_header(
classes: "app-header",
service_url: current_user.nil? ? "/" : "/logs",
navigation_classes: "govuk-header__navigation--end",
) do |component|
component.product_name(name: t("service_name"))
if current_user.nil?
component.navigation_item(text: "Sign in", href: user_session_path)
else
component.navigation_item(text: "Your account", href: account_path)
component.navigation_item(text: "Sign out", href: destroy_user_session_path)
end
end %>
<% feedback_link = govuk_link_to "giving us your feedback (opens in a new tab)", t("feedback_form"), rel: "noreferrer noopener", target: "_blank" %>
<%= govuk_phase_banner(
classes: "govuk-width-container",
tag: { text: "Beta" },
text: "This is a new service – help us improve it by #{feedback_link}".html_safe,
) %>
<% if !current_user.nil? %>
Cldc 1102 admin organisations page (#557) * Get all organisations in controller * Display organisations data in the table * Route to logs for specific organisation * add tests * update spec * lint fixes * set up failing test for organisation logs page * fix failing test * write test for organisations support user page * Update a organisation page test and lint * added pagination test with next and previous links and total count for support user * test for pagination in organisations title * Added "Organisations" to to organisations page title * add pagination test for organisations page 2, remove second before block * Add the remaining pagination tests * Redirect when accessing organisation logs by non support user * Test for displaying logs for specific organisation * Add test for org name * Add a failing log filter test for specific org * Extract filter methods into a helper * Allow logs filtering for specific org * Fix test, support user was creating an extra org, remove orgs filter for specific org * Remove redundant test, lint * Reuse primary navigation component and add sub navigation for support users * allow support users edit or and add sub navigation to about this org * allow support users to access the edit org page * only allow to edit existing editable fields * display correct values in the organisations table * allow support user to update org * user table component for organisations table * use guard clause for organisation logs page * remove create a new lettings log from organisation logs * Move case logs filter from helpers to modules * lint erb * yarn lint * bring back if statement in logs controller * update modules import * let! * test for links first in the org cotroller spec * interpolate number of orgs * conditionally render sub navigation Co-authored-by: Kat <katrina@madetech.com> Co-authored-by: Dushan Despotovic <dushan@madetech.com> Co-authored-by: JG <moarpheus@gmail.com>
3 years ago
<%= render NavigationComponent.new(
items: primary_items(request.path, current_user),
Cldc 1102 admin organisations page (#557) * Get all organisations in controller * Display organisations data in the table * Route to logs for specific organisation * add tests * update spec * lint fixes * set up failing test for organisation logs page * fix failing test * write test for organisations support user page * Update a organisation page test and lint * added pagination test with next and previous links and total count for support user * test for pagination in organisations title * Added "Organisations" to to organisations page title * add pagination test for organisations page 2, remove second before block * Add the remaining pagination tests * Redirect when accessing organisation logs by non support user * Test for displaying logs for specific organisation * Add test for org name * Add a failing log filter test for specific org * Extract filter methods into a helper * Allow logs filtering for specific org * Fix test, support user was creating an extra org, remove orgs filter for specific org * Remove redundant test, lint * Reuse primary navigation component and add sub navigation for support users * allow support users edit or and add sub navigation to about this org * allow support users to access the edit org page * only allow to edit existing editable fields * display correct values in the organisations table * allow support user to update org * user table component for organisations table * use guard clause for organisation logs page * remove create a new lettings log from organisation logs * Move case logs filter from helpers to modules * lint erb * yarn lint * bring back if statement in logs controller * update modules import * let! * test for links first in the org cotroller spec * interpolate number of orgs * conditionally render sub navigation Co-authored-by: Kat <katrina@madetech.com> Co-authored-by: Dushan Despotovic <dushan@madetech.com> Co-authored-by: JG <moarpheus@gmail.com>
3 years ago
level: "primary",
) %>
<% end %>
<div class="govuk-width-container">
<%= content_for(:breadcrumbs) %>
<%= content_for(:before_content) %>
<main class="govuk-main-wrapper" id="main-content" role="main">
<% if flash.notice && !flash.notice.include?("translation missing") %>
<%= govuk_notification_banner(
title_text: "Success",
success: true, title_heading_level: 3,
title_id: "swanky-notifications"
) do |notification_banner|
notification_banner.heading(text: flash.notice)
end %>
<% end %>
<%= content_for?(:content) ? yield(:content) : yield %>
</main>
</div>
3 years ago
<%= render partial: "layouts/footer" %>
</body>
</html>