From aa56e11d850bfdc2f2972f79c0f676eb1fd9a2ff Mon Sep 17 00:00:00 2001 From: Krateng Date: Tue, 2 Apr 2019 11:55:11 +0200 Subject: [PATCH] Added trailing selector for pulse view --- htmlmodules.py | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/htmlmodules.py b/htmlmodules.py index 53364c8..2bd3b3c 100644 --- a/htmlmodules.py +++ b/htmlmodules.py @@ -343,7 +343,7 @@ def module_filterselection(keys,time=True,delimit=False): if delimit: - retainkeys = {k:keys[k] for k in keys if k not in ["step","stepn","trail"]} + retainkeys = {k:keys[k] for k in keys if k not in ["step","stepn"]} keystr = "?" + urllib.parse.urlencode(retainkeys) html += "
" @@ -363,8 +363,31 @@ def module_filterselection(keys,time=True,delimit=False): html += "Yearly" else: html += "Yearly" + + html += "
" + + + retainkeys = {k:keys[k] for k in keys if k not in ["trail"]} + keystr = "?" + urllib.parse.urlencode(retainkeys) + + html += "
" + if keys.get("trail") == "1" or keys.get("trail") is None: + html += "Standard" + else: + html += "Standard" html += " | " + if keys.get("trail") == "2": + html += "Trailing" + else: + html += "Trailing" + html += " | " + + if keys.get("trail") == "3": + html += "Long Trailing" + else: + html += "Long Trailing" + html += "
" return html