<% content_for(:page_title, 'Leaderboard') %>

<table class="table table-striped table-bordered">
  <thead class="table-header">
    <th rowspan="2">Organisation</th>
    <th rowspan="2">Sites</th>
    <th colspan="3">Mappings
      <tr>
        <th>Total</th>
        <th>Unresolved</th>
        <th>Errors &darr;</th>
      </tr>
    </th>
  </thead>
  <tbody>
    <% Organisation.leaderboard.each do |org| %>
    <tr>
      <td><%= link_to org.title, organisation_path(org) %></td>
      <td><%= org.site_count %></td>
      <td><%= number_with_delimiter(org.mappings_across_sites) %></td>
      <td><%= number_with_delimiter(org.unresolved_mapping_count) %></td>
      <td><%= number_with_delimiter(org.error_count) %></td>
    </tr>
    <% end %>
  </tbody>
</table>

<% content_for(:page_title, 'Leaderboard') %>

<div class="page-title">
  <h1>Department leaderboard<br />
    <small>
      Which departments have the highest numbers of erroring mappings?
    </small>
  </h1>
</div>

<table class="table table-striped table-bordered">
  <thead class="table-header">
    <th rowspan="2">Organisation</th>
    <th rowspan="2">Sites</th>
    <th colspan="3">Mappings
      <tr>
        <th>Total</th>
        <th>Unresolved</th>
        <th>Errors &darr;</th>
      </tr>
    </th>
  </thead>
  <tbody>
    <% Organisation.leaderboard.each do |org| %>
    <tr>
      <td><%= link_to org.title, organisation_path(org) %></td>
      <td><%= org.site_count %></td>
      <td><%= number_with_delimiter(org.mappings_across_sites) %></td>
      <td><%= number_with_delimiter(org.unresolved_mapping_count) %></td>
      <td><%= number_with_delimiter(org.error_count) %></td>
    </tr>
    <% end %>
  </tbody>
</table>

Add a title and a description to the leaderboard page
Add a title and a description to the leaderboard page

- This needs some copy work, probably.
