{% extends "base.html" %}

{% block content %}

<link rel="stylesheet" href="{{ url_for('static', filename='css/flags/flags.css') }}"/>
 
<div class="container">
<div class="panel panel-success" id="asdf">
<div class="panel-heading"><h3 class="panel-title">Devices</h3></div>
<div class="panel-body">
  <table class="datatable table table-striped table-bordered">
    <tr>
   	  <th>Receiver</th>
      <th>Aircrafts</th>
      <th>Beacons</th>
    </tr>
    
    {% for receiverstat in receiverstats %}
	<tr>
	  <td><img src="{{ url_for('static', filename='img/Transparent.gif') }}" class="flag flag-{{ receiverstat.receiver.country.iso2|lower }}" alt="{{ receiverstat.receiver.country.iso2 }}"/> {{ receiverstat.receiver.name }}</td>
	  <td>{{ receiverstat.aircraft_count }}</td>
	  <td>{{ receiverstat.beacon_count }}</td>
	</tr>
	{% endfor %}
  </table>
</div>
</div>

{% endblock %}