diff --git a/app/controllers/check_records/bulk_searches_controller.rb b/app/controllers/check_records/bulk_searches_controller.rb index 0398352e..d839cebf 100644 --- a/app/controllers/check_records/bulk_searches_controller.rb +++ b/app/controllers/check_records/bulk_searches_controller.rb @@ -40,6 +40,8 @@ def show data = @bulk_search_response.body @total = @bulk_search_response.total + @total_not_found = data['not_found'].count + @total_results = data['results'].count @results ||= data.fetch("results", []).map do |teacher| QualificationsApi::Teacher.new(teacher['api_data']) end diff --git a/app/views/check_records/bulk_searches/show.html.erb b/app/views/check_records/bulk_searches/show.html.erb index 826102a2..5e8907d1 100644 --- a/app/views/check_records/bulk_searches/show.html.erb +++ b/app/views/check_records/bulk_searches/show.html.erb @@ -1,14 +1,14 @@ <% content_for :page_title, "Bulk Search Results" %> <% content_for :breadcrumbs do %> <%= govuk_breadcrumbs(breadcrumbs: { "Home" => check_records_search_path, "Find multiple records" => new_check_records_bulk_search_path, "Results" => nil }) %> + <%= render ActionAtComponent.new(action: "searched") %> <% end %>
- We found <%= pluralize(@total, 'teacher record') %> out of the <%= pluralize(@results.count + @not_found.count, 'entry') %> you uploaded. + We found <%= pluralize(@total, 'teacher record') %> out of the <%= pluralize(@total_results + @total_not_found, 'entry') %> you uploaded.
<%= govuk_tabs do |tabs| if @results.any?