<% content_for(:title, "Households") %>

<% content_for(:top_buttons) do %>
  <% if policy(Household.new(community: current_community)).create? %>
    <%= link_to(icon_tag("plus") << " Create Household", new_household_path, class: "btn btn-primary") %>
  <% end %>
<% end %>

<% if @households.empty? %>
  <div class="center-notice">
    No households found.
  </div>
<% else %>
  <table class="index">
    <tr>
      <th>Name</th>
      <% if multi_community? %>
        <th>Community</th>
      <% end %>
      <th>Unit #</th>
      <th>Users</th>
      <th></th>
    </tr>
    <% @households.each do |household| %>
      <tr class="<%= household.active? ? "" : "inactive" %>">
        <td>
          <% if policy(household).show? %>
            <%= link_to(household.name, household) %>
          <% else %>
            <%= household.name %>
          <% end %>
        </td>
        <% if multi_community? %>
          <td><%= household.community_name %></td>
        <% end %>
        <td>
          <%= household.unit_num_and_suffix %>
        </td>
        <td>
          <%= load_showable_users_and_children_in(household).map(&:link).reduce(&sep(", ")) %>
        </td>
      </tr>
    <% end %>
  </table>
  <%= paginate @households %>
<% end %>

<% content_for(:title, "Households") %>

<% content_for(:top_buttons) do %>
  <% if policy(Household.new(community: current_community)).create? %>
    <%= link_to(icon_tag("plus") << " Create Household", new_household_path, class: "btn btn-primary") %>
  <% end %>
<% end %>

<% if @households.empty? %>
  <div class="center-notice">
    No households found.
  </div>
<% else %>
  <table class="index part-width">
    <tr>
      <th>Name</th>
      <th>Unit #</th>
      <th>Users</th>
      <th></th>
    </tr>
    <% @households.each do |household| %>
      <tr class="<%= household.active? ? "" : "inactive" %>">
        <td>
          <% if policy(household).show? %>
            <%= link_to(household.name, household) %>
          <% else %>
            <%= household.name %>
          <% end %>
        </td>
        <td>
          <%= household.unit_num_and_suffix %>
        </td>
        <td>
          <%= load_showable_users_and_children_in(household).map(&:link).reduce(&sep(", ")) %>
        </td>
      </tr>
    <% end %>
  </table>
  <%= paginate @households %>
<% end %>

Remove community column from households page
229: Remove community column from households page
