ISSUE-2109 ui: fix decode query params bug

This commit is contained in:
tattsun 2016-10-22 00:49:06 +09:00
parent ec203a23e2
commit 68e20bd9ac
2 changed files with 38 additions and 39 deletions

File diff suppressed because one or more lines are too long

View file

@ -741,9 +741,8 @@ Prometheus.Page.QueryParamHelper.prototype.parseQueryParamsOfOneGraph = function
queryParams.forEach(function(tuple) {
var optionNameAndValue = tuple.split('=');
var optionName = optionNameAndValue[0];
var optionValue = decodeURIComponent(optionNameAndValue[1]);
optionValue = optionValue.replace(/\+/g, " "); // $.param turns spaces into pluses
var optionValue = decodeURIComponent(optionNameAndValue[1].replace(/\+/g, " "));
if (optionName == "tab") {
optionValue = parseInt(optionValue); // tab is integer