Email roll to schools function

This commit is contained in:
John Mullins
2023-09-01 15:18:20 +10:00
parent 99530513c1
commit d051bc8beb
6 changed files with 107 additions and 10 deletions
@@ -0,0 +1,35 @@
<style>
td {
border: 2px solid #000;
padding-top: 3px
}
</style>
{% for school in schools %}
<h1>{{ school.name }}</h1>
{% for route in school.routes %}
<br>
<h2>{{ route.bus }}</h2>
<table>
<tr>
<th style="width: 60%">Traveller</th>
<th style="width: 5%">Fare</th>
<th style="width: 40%">Stop</th>
<th style="width: 12%">AM Time</th>
<th style="width: 12%">PM Time</th>
</tr>
{% for traveller in route.travellers %}
<tr>
<td style="padding-left: 2px">{{ traveller.display }}</td>
<td style="text-align: center">{{ traveller.isFared }}</td>
<td style="padding-left: 2px">{{ traveller.stop }}</td>
<td style="text-align: center">{{ traveller.am_time }}</td>
<td style="text-align: center">{{ traveller.pm_time }}</td>
</tr>
{% endfor %}
</table>
{% endfor %}
<p style="page-break-after: always">
{% endfor %}