indicate whether a connecting train is cancelled or not
This commit is contained in:
parent
29958c1968
commit
8e5a8fad93
1 changed files with 10 additions and 4 deletions
|
@ -29,18 +29,24 @@
|
||||||
<div class="hide-on-small-only"><table class="striped"><tbody>
|
<div class="hide-on-small-only"><table class="striped"><tbody>
|
||||||
% for my $res (@{$connections}) {
|
% for my $res (@{$connections}) {
|
||||||
% my ($train, $via) = @{$res};
|
% my ($train, $via) = @{$res};
|
||||||
|
% my $td_class = '';
|
||||||
|
% my $link_class = 'action-checkin';
|
||||||
|
% if ($train->departure_is_cancelled) {
|
||||||
|
% $td_class = 'cancelled';
|
||||||
|
% $link_class = 'action-cancelled-from';
|
||||||
|
% }
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td class="<%= $td_class %>">
|
||||||
% if ($checkin_from) {
|
% if ($checkin_from) {
|
||||||
<a class="action-checkin" data-station="<%= $checkin_from %>" data-train="<%= $train->train_id %>" data-dest="<%= $via %>"><%= $train->line %></a>
|
<a class="<%= $link_class %>" data-station="<%= $checkin_from %>" data-train="<%= $train->train_id %>" data-dest="<%= $via %>"><%= $train->line %></a>
|
||||||
% }
|
% }
|
||||||
% else {
|
% else {
|
||||||
%= $train->line
|
%= $train->line
|
||||||
% }
|
% }
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td class="<%= $td_class %>">
|
||||||
% if ($checkin_from) {
|
% if ($checkin_from) {
|
||||||
<a class="action-checkin" data-station="<%= $checkin_from %>" data-train="<%= $train->train_id %>" data-dest="<%= $via %>"><%= $via %></a>
|
<a class="<%= $link_class %>" data-station="<%= $checkin_from %>" data-train="<%= $train->train_id %>" data-dest="<%= $via %>"><%= $via %></a>
|
||||||
% }
|
% }
|
||||||
% else {
|
% else {
|
||||||
%= $via
|
%= $via
|
||||||
|
|
Loading…
Reference in a new issue