summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2014-12-04 12:21:48 +0100
committerDaniel Friesel <derf@finalrewind.org>2014-12-04 12:21:48 +0100
commitcbbe35517e92f6cdf926a42eb167fca566881233 (patch)
tree2dea7808c7332f8bf22e98799244e7b3368ea318 /templates
parentda0d796885f04271ebca145f3dc378f5c60b5fe3 (diff)
iris+clean: show and sort by actual (estimated) arr/dep times
Diffstat (limited to 'templates')
-rw-r--r--templates/clean.html.ep13
-rw-r--r--templates/layouts/default.html.ep8
2 files changed, 20 insertions, 1 deletions
diff --git a/templates/clean.html.ep b/templates/clean.html.ep
index 21750d5..f073c2e 100644
--- a/templates/clean.html.ep
+++ b/templates/clean.html.ep
@@ -58,15 +58,26 @@
</span>
<span class="countdown">
% if ($departure->{delay} and not $departure->{is_cancelled}) {
+% if ($show_realtime) {
+<span class="delaynorm">(+<%= $departure->{delay} %>)</span>
+% }
+% else {
<span class="delay">(+<%= $departure->{delay} %>)</span>
% }
+% }
<span class="platform">
%= $departure->{platform}
</span>
</span>
-<span class="time">
+<span class="time <%= ($show_realtime and $departure->{delay} and not $departure->{is_cancelled}) ? 'delayed' : q{} %>">
+% if ($show_realtime and $departure->{delay} and not $departure->{is_cancelled}) {
+<span class="delayed">
+% }
%= $departure->{time}
</span>
+% if ($show_realtime and $departure->{delay} and not $departure->{is_cancelled}) {
+</span>
+% }
</li>
<!--
diff --git a/templates/layouts/default.html.ep b/templates/layouts/default.html.ep
index 85ef48c..a6ffaae 100644
--- a/templates/layouts/default.html.ep
+++ b/templates/layouts/default.html.ep
@@ -123,6 +123,14 @@
%= select_field admode => [['Abfahrt bevorzugen' => 'deparr'], ['Nur Abfahrt' => 'dep'], ['Nur Ankunft' => 'arr']]
</div>
</div>
+ <div class="field">
+ <div class="desc">
+ Erwartete Abfahrtzeiten statt Fahrplandaten verwenden?
+ </div>
+ <div>
+ %= check_box 'show_realtime' => 1
+ </div>
+ </div>
</div>
% end