Browse Source

set filters_count to 0 where there are no filters

pull/1999/head
Kat 3 years ago
parent
commit
7fd7ed35d9
  1. 2
      app/views/organisation_relationships/_managing_agent_list.erb
  2. 2
      app/views/organisation_relationships/_stock_owner_list.erb

2
app/views/organisation_relationships/_managing_agent_list.erb

@ -1,7 +1,7 @@
<section class="app-table-group" tabindex="0" aria-labelledby="<%= title.dasherize %>"> <section class="app-table-group" tabindex="0" aria-labelledby="<%= title.dasherize %>">
<%= govuk_table do |table| %> <%= govuk_table do |table| %>
<%= table.caption(classes: %w[govuk-!-font-size-19 govuk-!-font-weight-regular]) do |caption| %> <%= table.caption(classes: %w[govuk-!-font-size-19 govuk-!-font-weight-regular]) do |caption| %>
<%= render(SearchResultCaptionComponent.new(searched:, count: pagy.count, item_label:, total_count:, item: "agents")) %> <%= render(SearchResultCaptionComponent.new(searched:, count: pagy.count, item_label:, total_count:, item: "agents", filters_count: 0)) %>
<% end %> <% end %>
<% @managing_agents.each do |managing_agent| %> <% @managing_agents.each do |managing_agent| %>
<%= table.body do |body| %> <%= table.body do |body| %>

2
app/views/organisation_relationships/_stock_owner_list.erb

@ -1,7 +1,7 @@
<section class="app-table-group" tabindex="0" aria-labelledby="<%= title.dasherize %>"> <section class="app-table-group" tabindex="0" aria-labelledby="<%= title.dasherize %>">
<%= govuk_table do |table| %> <%= govuk_table do |table| %>
<%= table.caption(classes: %w[govuk-!-font-size-19 govuk-!-font-weight-regular]) do |caption| %> <%= table.caption(classes: %w[govuk-!-font-size-19 govuk-!-font-weight-regular]) do |caption| %>
<%= render(SearchResultCaptionComponent.new(searched:, count: pagy.count, item_label:, total_count:, item: "stock owners")) %> <%= render(SearchResultCaptionComponent.new(searched:, count: pagy.count, item_label:, total_count:, item: "stock owners", filters_count: 0)) %>
<% end %> <% end %>
<% @stock_owners.each do |stock_owner| %> <% @stock_owners.each do |stock_owner| %>
<%= table.body do |body| %> <%= table.body do |body| %>

Loading…
Cancel
Save