Unverified Commit f923c6da authored by Birte Kristina Friesel's avatar Birte Kristina Friesel
Browse files

do not lose show_realtime setting in detail views

parent 2cccc8c9
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -102,6 +102,9 @@ function dbf_reg_handlers() {
		if (window.location.href.includes('past=1')) {
			suffix += '&past=1';
		}
		if (window.location.href.includes('show_realtime=1')) {
			suffix += '&show_realtime=1';
		}
		history.pushState({'page':'traindetail','station':station,'train':trainElem.data('no')}, 'test', '/z/' + trainElem.data('train') + '/' + trainElem.data('station') + suffix);
		dbf_show_moreinfo(trainElem, false);
	});
+2 −2
Original line number Diff line number Diff line
@@ -195,7 +195,7 @@
      <ul class="mroute">
%       for my $stop (@{$departure->{route_pre_diff}}) {
          <li class="<%= $stop->{isPast} ? 'past-stop' : 'future-stop' %>">
          <a href="<%= url_for('station', station => $stop->{name})->query({detailed => param('detailed'), past => param('past')}) %>#<%= ($departure->{train_type} // q{x}) . ($departure->{train_no} // q{x}) %>" class="
          <a href="<%= url_for('station', station => $stop->{name})->query({detailed => param('detailed'), past => param('past'), show_realtime => param('show_realtime')}) %>#<%= ($departure->{train_type} // q{x}) . ($departure->{train_no} // q{x}) %>" class="
%         if ($stop->{isAdditional}) {
            additional-stop
%         }
@@ -240,7 +240,7 @@
%       }
%       for my $stop (@{$departure->{route_post_diff}}) {
          <li class="<%= $stop->{isPast} ? 'past-stop' : 'future-stop' %>">
          <a href="<%= url_for('station', station => $stop->{name})->query({detailed => param('detailed'), past => param('past')}) %>#<%= ($departure->{train_type} // q{x}) . ($departure->{train_no} // q{x}) %>" class="
          <a href="<%= url_for('station', station => $stop->{name})->query({detailed => param('detailed'), past => param('past'), show_realtime => param('show_realtime')}) %>#<%= ($departure->{train_type} // q{x}) . ($departure->{train_no} // q{x}) %>" class="
%         if ($stop->{isAdditional}) {
            additional-stop
%         }