diff --git a/app/components/provider_interface/recruitment_performance_report/deferrals_table_component.html.erb b/app/components/provider_interface/recruitment_performance_report/deferrals_table_component.html.erb index d4f964f2fbb..73fb87348e5 100644 --- a/app/components/provider_interface/recruitment_performance_report/deferrals_table_component.html.erb +++ b/app/components/provider_interface/recruitment_performance_report/deferrals_table_component.html.erb @@ -6,10 +6,10 @@

<%= t('deferrals_table_component.description_one', provider_name:) %>

<%= t('deferrals_table_component.description_two') %>

+
<% if deferral_rows.empty? %>

<%= t('shared.empty_state') %>

<% else %> -
<%= govuk_table do |table| %> <%= table.with_caption(text: t('deferrals_table_component.caption'), html_attributes: { class: 'govuk-visually-hidden' }) %> diff --git a/app/components/provider_interface/recruitment_performance_report/proportion_with_inactive_applications_table_component.html.erb b/app/components/provider_interface/recruitment_performance_report/proportion_with_inactive_applications_table_component.html.erb index 3826858002c..98d01776bff 100644 --- a/app/components/provider_interface/recruitment_performance_report/proportion_with_inactive_applications_table_component.html.erb +++ b/app/components/provider_interface/recruitment_performance_report/proportion_with_inactive_applications_table_component.html.erb @@ -9,11 +9,11 @@

<%= t('proportion_with_inactive_applications_table_component.description_two') %>

<%= t('proportion_with_inactive_applications_table_component.description_three') %>

+
<% if subject_rows.empty? %>

<%= t('shared.empty_state') %>

<% else %> -
<%= govuk_table do |table| %> <%= table.with_caption(text: t('proportion_with_inactive_applications_table_component.caption'), html_attributes: { class: 'govuk-visually-hidden' }) %> diff --git a/app/components/provider_interface/recruitment_performance_report/subject_table_component.html.erb b/app/components/provider_interface/recruitment_performance_report/subject_table_component.html.erb index 70e741d9a7b..6d26b4cd1b9 100644 --- a/app/components/provider_interface/recruitment_performance_report/subject_table_component.html.erb +++ b/app/components/provider_interface/recruitment_performance_report/subject_table_component.html.erb @@ -5,47 +5,47 @@ <% end %> <%= content %> +
<% if subject_rows.empty? %>

<%= t('shared.empty_state') %>

<% else %> -
- <%= govuk_table do |table| %> - <%= table.with_caption(text: t("subject_table_component.#{table_caption}"), - html_attributes: { class: 'govuk-visually-hidden' }) %> + <%= govuk_table do |table| %> + <%= table.with_caption(text: t("subject_table_component.#{table_caption}"), + html_attributes: { class: 'govuk-visually-hidden' }) %> - <%= table.with_colgroup do |colgroup| %> - <%= colgroup.with_col(span: 1) %> - <%= colgroup.with_col(span: colspan) %> - <%= colgroup.with_col(span: colspan) %> + <%= table.with_colgroup do |colgroup| %> + <%= colgroup.with_col(span: 1) %> + <%= colgroup.with_col(span: colspan) %> + <%= colgroup.with_col(span: colspan) %> + <% end %> + + <%= table.with_head do |head| %> + <%= head.with_row do |row| %> + <%= row.with_cell(scope: false, + html_attributes: { class: 'recruitment-performance-report-table__heading--no-border' }) %> + <%= row.with_cell(text: provider_name, colspan:, scope: 'colgroup', + html_attributes: { class: 'recruitment-performance-report-table__heading' }) %> + <%= row.with_cell(text: t('shared.all_providers'), colspan:, scope: 'colgroup', + html_attributes: { class: 'recruitment-performance-report-table__heading' }) %> <% end %> - <%= table.with_head do |head| %> - <%= head.with_row do |row| %> - <%= row.with_cell(scope: false, - html_attributes: { class: 'recruitment-performance-report-table__heading--no-border' }) %> - <%= row.with_cell(text: provider_name, colspan:, scope: 'colgroup', - html_attributes: { class: 'recruitment-performance-report-table__heading' }) %> - <%= row.with_cell(text: t('shared.all_providers'), colspan:, scope: 'colgroup', - html_attributes: { class: 'recruitment-performance-report-table__heading' }) %> - <% end %> - - <%= head.with_row do |row| %> - <%= row.with_cell(text: t('shared.subject'), **subheading_html_attributes) %> - <% columns.each do |column| %> - <%= row.with_cell(text: t("subject_table_component.#{column}"), - numeric: true, - **subheading_html_attributes(column)) %> - <% end %> + <%= head.with_row do |row| %> + <%= row.with_cell(text: t('shared.subject'), **subheading_html_attributes) %> + <% columns.each do |column| %> + <%= row.with_cell(text: t("subject_table_component.#{column}"), + numeric: true, + **subheading_html_attributes(column)) %> <% end %> <% end %> + <% end %> - <% table.with_body do |body| %> - <% subject_rows.each do |subject_row| %> - <% body.with_row do |row| %> - <%= row.with_cell(header: true, text: subject_row.title, **level_html_attributes(subject_row)) %> - <%= columns.each do |column| %> - <%= row.with_cell(text: format_number(subject_row, column), numeric: true, - **numeric_html_attributes(column)) %> + <% table.with_body do |body| %> + <% subject_rows.each do |subject_row| %> + <% body.with_row do |row| %> + <%= row.with_cell(header: true, text: subject_row.title, **level_html_attributes(subject_row)) %> + <%= columns.each do |column| %> + <%= row.with_cell(text: format_number(subject_row, column), numeric: true, + **numeric_html_attributes(column)) %> <% end %> <% end %> <% end %>