diff options
author | Daniel Friesel <daniel.friesel@uos.de> | 2021-08-31 17:56:35 +0200 |
---|---|---|
committer | Daniel Friesel <daniel.friesel@uos.de> | 2021-08-31 17:56:35 +0200 |
commit | f88817d98eedc3f0c99857e842127a5f4b78fba2 (patch) | |
tree | 24fcb5fb2b621e51250d154ffb9656b3c333367f /public/static/js/collapse.js | |
parent | 39746c144b1bcfccaaae1dc9534c3017c4814bf5 (diff) |
Add past option
Diffstat (limited to 'public/static/js/collapse.js')
-rw-r--r-- | public/static/js/collapse.js | 7 |
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); |