From e3e2807f0156ce5cf07138d4f4567e7f072b1913 Mon Sep 17 00:00:00 2001 From: JG Date: Mon, 6 Jun 2022 10:08:19 +0100 Subject: [PATCH] correct headings --- app/views/case_logs/index.html.erb | 11 ++++++----- app/views/layouts/organisations.html.erb | 23 ++++++++++++----------- app/views/organisations/index.html.erb | 14 +++++++++++++- app/views/organisations/logs.html.erb | 8 ++++---- app/views/organisations/show.html.erb | 13 +++++++++---- app/views/organisations/users.html.erb | 10 ++++++---- app/views/users/index.html.erb | 11 +++++++---- 7 files changed, 57 insertions(+), 33 deletions(-) diff --git a/app/views/case_logs/index.html.erb b/app/views/case_logs/index.html.erb index b18e22861..b65a0338a 100644 --- a/app/views/case_logs/index.html.erb +++ b/app/views/case_logs/index.html.erb @@ -6,11 +6,12 @@ <% title = "Your organisation (Logs)" %> <% end %> -<% content_for :title, title %> - -<% content_for :tab_title do %> - <%= "Logs" %> -<% end %> +

+ <% if !current_user.support? %> + <%= current_user.organisation.name %> + <% end %> + Logs +

diff --git a/app/views/layouts/organisations.html.erb b/app/views/layouts/organisations.html.erb index cb4d1c716..335974fa8 100644 --- a/app/views/layouts/organisations.html.erb +++ b/app/views/layouts/organisations.html.erb @@ -1,16 +1,17 @@ -<% content_for :content do %> -

- <% if current_user.support? && request.path != "/organisations" %> - <%= @organisation.name %> - <% end %> - <%= content_for(:title) %> -

+<%# <% content_for :content do %1> %> +<%#

%> +<%# <% if current_user.support? && request.path != "/organisations" %1> %> +<%# <%= @organisation.name %1> %> +<%# <% end %1> %> +<%# <%= content_for(:title) %1> %> +<%#

%> - <% items = tab_items(current_user) %> +<%# <% items = tab_items(current_user) %1> %> -

<%= content_for(:tab_title) %>

+<%#

<%= content_for(:tab_title) %1>

%> - <%= content_for?(:organisations_content) ? yield(:organisations_content) : yield %> -<% end %> +<%# <%= content_for?(:organisations_content) ? yield(:organisations_content) : yield %1> %> +<%# <% end %1> %> +<%# <%= content_for?(:organisations_content) ? yield(:organisations_content) : yield %1> %> <%= render template: "layouts/application" %> diff --git a/app/views/organisations/index.html.erb b/app/views/organisations/index.html.erb index b8560f072..ce2e4e9d6 100644 --- a/app/views/organisations/index.html.erb +++ b/app/views/organisations/index.html.erb @@ -5,7 +5,19 @@ <% title = "Organisations" %> <% end %> -<% content_for :title, title %> +

+ <% if current_user.support? && request.path == "/organisations" %> + Organisations + <% end %> + <% if current_user.support? && request.path != "/organisations" %> + <%= @organisation.name %> +

Organisations

+ <% end %> + + +<% items = tab_items(current_user) %> + +

Organisations

<%= render SearchComponent.new(current_user:, search_label: "Search by organisation name", value: @searched) %> diff --git a/app/views/organisations/logs.html.erb b/app/views/organisations/logs.html.erb index a5e62dbf8..2f8102dd3 100644 --- a/app/views/organisations/logs.html.erb +++ b/app/views/organisations/logs.html.erb @@ -5,11 +5,11 @@ <% title = "Your organisation (Logs)" %> <% end %> -<% content_for :title, title %> +

+

<%= @organisation.name %>

+ -<% content_for :tab_title do %> - <%= "Logs" %> -<% end %> +

Logs

<%= render SubNavigationComponent.new( items: secondary_items(request.path, @organisation.id), diff --git a/app/views/organisations/show.html.erb b/app/views/organisations/show.html.erb index f4760a7c9..87ed5046f 100644 --- a/app/views/organisations/show.html.erb +++ b/app/views/organisations/show.html.erb @@ -1,8 +1,13 @@ -<% content_for :title, current_user.support? ? "Details" : "Your organisation" %> +

+ <% if !current_user.support? %> + <%= current_user.organisation.name %> + About your organisation + <% else %> +

<%= @organisation.name %>

+ <% end %> + -<% content_for :tab_title do %> - <%= "Details" %> -<% end %> +

About this organisation

<% if current_user.support? %> <%= render SubNavigationComponent.new( diff --git a/app/views/organisations/users.html.erb b/app/views/organisations/users.html.erb index 67df43109..0366a3b67 100644 --- a/app/views/organisations/users.html.erb +++ b/app/views/organisations/users.html.erb @@ -5,11 +5,13 @@ <% title = "Your organisation (User)" %> <% end %> -<% content_for :title, title %> +

+ <% if current_user.support? %> +

<%= @organisation.name %>

+ <% end %> + -<% content_for :tab_title do %> - <%= "Users" %> -<% end %> +

Users

<%= render SubNavigationComponent.new( items: secondary_items(request.path, @organisation.id), diff --git a/app/views/users/index.html.erb b/app/views/users/index.html.erb index 1569a8097..f7b42d26e 100644 --- a/app/views/users/index.html.erb +++ b/app/views/users/index.html.erb @@ -5,11 +5,14 @@ <% title = "Your organisation (Users)" %> <% end %> -<% content_for :title, title %> +

+ <% unless current_user.support? %> + <%= current_user.organisation.name %> + <% end %> + Users +

-<% content_for :tab_title do %> - <%= "Users" %> -<% end %> +

Users

<% if current_user.data_coordinator? || current_user.support? %> <%= govuk_button_link_to "Invite user", new_user_path, html: { method: :get } %>