summaryrefslogtreecommitdiff
path: root/public/static/js/collapse.js
diff options
context:
space:
mode:
Diffstat (limited to 'public/static/js/collapse.js')
-rw-r--r--public/static/js/collapse.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/public/static/js/collapse.js b/public/static/js/collapse.js
index faca7ca..9763f26 100644
--- a/public/static/js/collapse.js
+++ b/public/static/js/collapse.js
@@ -95,9 +95,12 @@ function dbf_reg_handlers() {
const trainElem = $(this);
const station = $('div.app').data('station');
event.preventDefault();
- var suffix = '';
+ var suffix = '?';
if (window.location.href.includes('detailed=1')) {
- suffix = '?detailed=1';
+ suffix += '&detailed=1';
+ }
+ if (window.location.href.includes('past=1')) {
+ suffix += '&past=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);