Jacek Kowalski
2020-01-28 3d1e543a6771b8c532ae90d06f5094790d7f39f1
Put full vehicle number and link to the map in vehicles.html tpl
2 files modified
8 ■■■■ changed files
lib/Output.php 4 ●●●● patch | view | raw | blame | history
templates/vehicles.html 4 ●●● patch | view | raw | blame | history
lib/Output.php
@@ -59,6 +59,10 @@
        ksort($vehicles);
        
        $dbMapping = $this->db->getAllByNum();
        foreach($dbMapping as &$vehicle) {
            $vehicle['vehicle'] = $this->vehicleTypes->getByNumber($vehicle['num']);
        }
        unset($vehicle);
        ksort($dbMapping);
        
        if($saveConfig) {
templates/vehicles.html
@@ -91,7 +91,9 @@
{% for map in mapping %}
<tr>
<td>
{{ map.num | e }}
<a href="https://mpk.jacekk.net/map.html#!{{ map.vehicle.num }}" class="low{{ map.vehicle.low | default }}">
{{ map.vehicle.num | e }}
</a>
</td>
<td>
{{ map.line | default('?') | e }}