From 78fb23b77ba6c6f1fe1ebbf744ec8f503d7956c5 Mon Sep 17 00:00:00 2001 From: Milan Lesichkov Date: Mon, 29 Jul 2019 06:33:12 +0100 Subject: [PATCH] Update initialize.js --- initialize.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/initialize.js b/initialize.js index 18e64b4..f819602 100644 --- a/initialize.js +++ b/initialize.js @@ -312,7 +312,15 @@ function Initialize() { } else { var url = rtrim(Config.getRootUrl(), ['/']) + '/' + ltrim(url, ['/']); } - window.location.href = url; + var queryString = Object.keys(data).map((key) => { + return encodeURIComponent(key) + '=' + encodeURIComponent(params[key]) + }).join('&'); + if(data && data.length>0) { + window.location.href = url + '?' + queryString; + } else { + window.location.href = url; + } + return false; // otherwise links will be triggered };