summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2019-12-20 14:51:50 +0100
committerDaniel Friesel <derf@finalrewind.org>2019-12-20 14:51:50 +0100
commit2831fbdfb7d2263f145d5130c8ffb972eca51a9a (patch)
tree3ab3de3e4041dd529b0417bc66c335563211d44e /templates
parent837e3a949ec57d03ed6fd5b5df1da8e3f64b5cbe (diff)
public status card: link to marudor.de for train details1.11.7
Diffstat (limited to 'templates')
-rw-r--r--templates/_public_status_card.html.ep11
1 files changed, 7 insertions, 4 deletions
diff --git a/templates/_public_status_card.html.ep b/templates/_public_status_card.html.ep
index 4a846af..2ff7ac1 100644
--- a/templates/_public_status_card.html.ep
+++ b/templates/_public_status_card.html.ep
@@ -1,5 +1,6 @@
+<div class="autorefresh">
% if ($journey->{checked_in}) {
- <div class="card autorefresh">
+ <div class="card">
<div class="card-content">
<i class="material-icons small right sync-failed-marker grey-text" style="display: none;">sync_problem</i>
<span class="card-title"><%= $name %> ist unterwegs</span>
@@ -7,11 +8,12 @@
<p>„<%= $journey->{comment} %>“</p>
% }
<p>
+ % my $url = 'https://marudor.de/details/' . $journey->{train_type} . ' ' . $journey->{train_no} . '/' . DateTime->now(time_zone => 'Europe/Berlin')->epoch . '000';
% if ($journey->{train_line}) {
- <div class="center-align"><b><%= $journey->{train_type} %> <%= $journey->{train_line} %></b> <%= $journey->{train_no} %></div>
+ <div class="center-align"><a href="<%= $url %>"><b><%= $journey->{train_type} %> <%= $journey->{train_line} %></b> <%= $journey->{train_no} %></a></div>
% }
% else {
- <div class="center-align"><b><%= $journey->{train_type} %> <%= $journey->{train_no} %></b></div>
+ <div class="center-align"><a href="<%= $url %>"><b><%= $journey->{train_type} %> <%= $journey->{train_no} %></b></a></div>
% }
<div class="center-align countdown"
data-duration="<%= $journey->{journey_duration} // 0 %>"
@@ -139,7 +141,7 @@
</div>
% }
% else {
- <div class="card autorefresh">
+ <div class="card">
<div class="card-content">
<i class="material-icons small right sync-failed-marker grey-text" style="display: none;">sync_problem</i>
<span class="card-title"><%= $name %> ist gerade nicht eingecheckt</span>
@@ -149,3 +151,4 @@
</div>
</div>
% }
+</div>