diff options
author | Daniel Friesel <derf@finalrewind.org> | 2019-01-12 13:56:23 +0100 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2019-01-12 13:56:23 +0100 |
commit | 70d838bb0825cf5a7fa8dcc2eb4e712001da2c1d (patch) | |
tree | be501b2a011a164e8d99f06d89abc99b19127aea /templates | |
parent | 7e4727af603cdd8bbb3746842a9603054ddca7cb (diff) |
support linking to individual trains1.15
Diffstat (limited to 'templates')
-rw-r--r-- | templates/app.html.ep | 13 | ||||
-rw-r--r-- | templates/layouts/default.html.ep | 2 |
2 files changed, 9 insertions, 6 deletions
diff --git a/templates/app.html.ep b/templates/app.html.ep index 8c7d079..5c511ce 100644 --- a/templates/app.html.ep +++ b/templates/app.html.ep @@ -71,7 +71,8 @@ % } </div> % } - <div class="moreinfo collapsed-moreinfo"> + <div class="moreinfo collapsed-moreinfo" + data-train="<%= ($departure->{train_type} // 'none') . ($departure->{train_no} // 0) %>"> <div class="mheader"> <div> % if ($departure->{train_no} or $departure->{train_line}) { @@ -164,18 +165,20 @@ % if ($first++) { <span class="separator">–</span> % } + <a href="/<%= $stop->{name} %>#<%= $departure->{train_type} . $departure->{train_no} %>" class=" % if ($stop->{isAdditional}) { - <span class="additional-stop"><%= $stop->{name} %></span> + additional-stop % } % elsif ($stop->{isCancelled}) { - <span class="cancelled-stop"><%= $stop->{name} %></span> + cancelled-stop % } % elsif ($self->is_important($stop->{name})) { - <span class="important-stop"><%= $stop->{name} %></span> + important-stop % } % else { - <span class="generic-stop"><%= $stop->{name} %></span> + generic-stop % } + "><%= $stop->{name} %></a> % } </div> <!-- mroute --> % } diff --git a/templates/layouts/default.html.ep b/templates/layouts/default.html.ep index 5b6dec8..a04331a 100644 --- a/templates/layouts/default.html.ep +++ b/templates/layouts/default.html.ep @@ -8,7 +8,7 @@ <meta http-equiv="refresh" content="<%= $self->stash('refresh_interval') %>"/> % } - % my $av = 'v2'; # asset version + % my $av = 'v3'; # asset version %= stylesheet "/static/${av}/default.css" %= stylesheet "/static/${av}/jquery-ui.min.css" % my $force_mobile = param('force_mobile') // -1; |