@queue-it/connector-javascript
Advanced tools
Comparing version 4.1.0 to 4.1.1
@@ -0,0 +0,0 @@ { |
"use strict"; | ||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); | ||
var desc = Object.getOwnPropertyDescriptor(m, k); | ||
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { | ||
desc = { enumerable: true, get: function() { return m[k]; } }; | ||
} | ||
Object.defineProperty(o, k2, desc); | ||
}) : (function(o, m, k, k2) { | ||
@@ -6,0 +10,0 @@ if (k2 === undefined) k2 = k; |
"use strict"; | ||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); | ||
var desc = Object.getOwnPropertyDescriptor(m, k); | ||
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { | ||
desc = { enumerable: true, get: function() { return m[k]; } }; | ||
} | ||
Object.defineProperty(o, k2, desc); | ||
}) : (function(o, m, k, k2) { | ||
@@ -6,0 +10,0 @@ if (k2 === undefined) k2 = k; |
"use strict"; | ||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); | ||
var desc = Object.getOwnPropertyDescriptor(m, k); | ||
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { | ||
desc = { enumerable: true, get: function() { return m[k]; } }; | ||
} | ||
Object.defineProperty(o, k2, desc); | ||
}) : (function(o, m, k, k2) { | ||
@@ -36,3 +40,3 @@ if (k2 === undefined) k2 = k; | ||
if (f) throw new TypeError("Generator is already executing."); | ||
while (_) try { | ||
while (g && (g = 0, op[0] && (_ = 0)), _) try { | ||
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t; | ||
@@ -39,0 +43,0 @@ if (y = 0, t) op = [op[0] & 2, t.value]; |
@@ -24,6 +24,6 @@ "use strict"; | ||
QueueEventConfig.prototype.getString = function () { | ||
return "EventId:" + this.eventId + "&Version:" + this.version + "&ActionName:" + this.actionName + "&QueueDomain:" + this.queueDomain + | ||
("&CookieDomain:" + this.cookieDomain + "&IsCookieHttpOnly:" + this.isCookieHttpOnly + "&IsCookieSecure:" + this.isCookieSecure) + | ||
("&ExtendCookieValidity:" + this.extendCookieValidity) + | ||
("&CookieValidityMinute:" + this.cookieValidityMinute + "&LayoutName:" + this.layoutName + "&Culture:" + this.culture); | ||
return "EventId:".concat(this.eventId, "&Version:").concat(this.version, "&ActionName:").concat(this.actionName, "&QueueDomain:").concat(this.queueDomain) + | ||
"&CookieDomain:".concat(this.cookieDomain, "&IsCookieHttpOnly:").concat(this.isCookieHttpOnly, "&IsCookieSecure:").concat(this.isCookieSecure) + | ||
"&ExtendCookieValidity:".concat(this.extendCookieValidity) + | ||
"&CookieValidityMinute:".concat(this.cookieValidityMinute, "&LayoutName:").concat(this.layoutName, "&Culture:").concat(this.culture); | ||
}; | ||
@@ -45,6 +45,6 @@ return QueueEventConfig; | ||
CancelEventConfig.prototype.getString = function () { | ||
return "EventId:" + this.eventId + "&Version:" + this.version + | ||
("&QueueDomain:" + this.queueDomain) + | ||
("&CookieDomain:" + this.cookieDomain + "&IsCookieHttpOnly:" + this.isCookieHttpOnly + "&IsCookieSecure:" + this.isCookieSecure) + | ||
("&ActionName:" + this.actionName); | ||
return "EventId:".concat(this.eventId, "&Version:").concat(this.version) + | ||
"&QueueDomain:".concat(this.queueDomain) + | ||
"&CookieDomain:".concat(this.cookieDomain, "&IsCookieHttpOnly:").concat(this.isCookieHttpOnly, "&IsCookieSecure:").concat(this.isCookieSecure) + | ||
"&ActionName:".concat(this.actionName); | ||
}; | ||
@@ -51,0 +51,0 @@ return CancelEventConfig; |
@@ -131,3 +131,3 @@ "use strict"; | ||
} | ||
var hashWithPrefix = "" + QueueParameterHelper.KeyValueSeparatorGroupChar + QueueParameterHelper.HashKey + QueueParameterHelper.KeyValueSeparatorChar + result.hashCode; | ||
var hashWithPrefix = "".concat(QueueParameterHelper.KeyValueSeparatorGroupChar).concat(QueueParameterHelper.HashKey).concat(QueueParameterHelper.KeyValueSeparatorChar).concat(result.hashCode); | ||
result.queueITTokenWithoutHash = result.queueITToken.replace(hashWithPrefix, ""); | ||
@@ -171,3 +171,3 @@ return result; | ||
var keyVal = cookieValues_1[_i]; | ||
values.push(keyVal.key + "=" + keyVal.value); | ||
values.push("".concat(keyVal.key, "=").concat(keyVal.value)); | ||
} | ||
@@ -186,3 +186,3 @@ return values.join("&"); | ||
this.hasError = true; | ||
var redirectUrl = "https://" + customerId + ".api2.queue-it.net/" + customerId + "/diagnostics/connector/error/?code=" + errorCode; | ||
var redirectUrl = "https://".concat(customerId, ".api2.queue-it.net/").concat(customerId, "/diagnostics/connector/error/?code=").concat(errorCode); | ||
this.validationResult = new models_1.RequestValidationResult("ConnectorDiagnosticsRedirect", null, null, redirectUrl, null, null); | ||
@@ -228,3 +228,3 @@ }; | ||
if (value) { | ||
this.details.push(key + ":" + value); | ||
this.details.push("".concat(key, ":").concat(value)); | ||
} | ||
@@ -231,0 +231,0 @@ else { |
@@ -17,3 +17,3 @@ "use strict"; | ||
if (f) throw new TypeError("Generator is already executing."); | ||
while (_) try { | ||
while (g && (g = 0, op[0] && (_ = 0)), _) try { | ||
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t; | ||
@@ -58,8 +58,8 @@ if (y = 0, t) op = [op[0] & 2, t.value]; | ||
var errorCode = validationResult.errorCode; | ||
var queueItTokenParam = qParams ? "&queueittoken=" + qParams.queueITToken : ''; | ||
var queueItTokenParam = qParams ? "&queueittoken=".concat(qParams.queueITToken) : ''; | ||
var query = this.getQueryString(customerId, config.eventId, config.version, config.culture, config.layoutName, config.actionName, validationResult.getInvalidReason()) + | ||
queueItTokenParam + | ||
("&ts=" + queueitHelpers_1.Utils.getCurrentTime()) + | ||
(targetUrl ? "&t=" + queueitHelpers_1.Utils.encodeUrl(targetUrl) : ""); | ||
var uriPath = "error/" + errorCode + "/"; | ||
"&ts=".concat(queueitHelpers_1.Utils.getCurrentTime()) + | ||
(targetUrl ? "&t=".concat(queueitHelpers_1.Utils.encodeUrl(targetUrl)) : ""); | ||
var uriPath = "error/".concat(errorCode, "/"); | ||
var redirectUrl = this.generateRedirectUrl(config.queueDomain, uriPath, query); | ||
@@ -79,7 +79,7 @@ return new models_1.RequestValidationResult(models_1.ActionTypes.QueueAction, config.eventId, null, redirectUrl, null, config.actionName); | ||
var queryStringList = new Array(); | ||
queryStringList.push("c=" + queueitHelpers_1.Utils.encodeUrl(customerId)); | ||
queryStringList.push("e=" + queueitHelpers_1.Utils.encodeUrl(eventId)); | ||
queryStringList.push("ver=" + UserInQueueService.SDK_VERSION); | ||
queryStringList.push("cver=" + configVersion); | ||
queryStringList.push("man=" + queueitHelpers_1.Utils.encodeUrl(actionName)); | ||
queryStringList.push("c=".concat(queueitHelpers_1.Utils.encodeUrl(customerId))); | ||
queryStringList.push("e=".concat(queueitHelpers_1.Utils.encodeUrl(eventId))); | ||
queryStringList.push("ver=".concat(UserInQueueService.SDK_VERSION)); | ||
queryStringList.push("cver=".concat(configVersion)); | ||
queryStringList.push("man=".concat(queueitHelpers_1.Utils.encodeUrl(actionName))); | ||
if (culture) { | ||
@@ -95,3 +95,3 @@ queryStringList.push("cid=" + queueitHelpers_1.Utils.encodeUrl(culture)); | ||
if (enqueueToken) { | ||
queryStringList.push("enqueuetoken=" + enqueueToken); | ||
queryStringList.push("enqueuetoken=".concat(enqueueToken)); | ||
} | ||
@@ -103,3 +103,3 @@ return queryStringList.join("&"); | ||
queueDomain = queueDomain + "/"; | ||
return "https://" + queueDomain + uriPath + "?" + query; | ||
return "https://".concat(queueDomain).concat(uriPath, "?").concat(query); | ||
}; | ||
@@ -204,5 +204,5 @@ UserInQueueService.prototype.validateQueueRequest = function (targetUrl, queueitToken, config, customerId, secretKey, apiKey) { | ||
(targetUrl ? "&r=" + queueitHelpers_1.Utils.encodeUrl(targetUrl) : ""); | ||
var uriPath = "cancel/" + customerId + "/" + config.eventId; | ||
var uriPath = "cancel/".concat(customerId, "/").concat(config.eventId); | ||
if (state.queueId) { | ||
uriPath += "/" + state.queueId; | ||
uriPath += "/".concat(state.queueId); | ||
} | ||
@@ -233,3 +233,3 @@ var redirectUrl = this.generateRedirectUrl(config.queueDomain, uriPath, query); | ||
RESPONSE_BODY_VARIABLE_NAME = 'QIdUsageCount'; | ||
endpointurl = "/queueit/verifyqidusage/" + customerId + "/" + eventId + "/" + queueId + "/" + queueIdUsageLimit; | ||
endpointurl = "/queueit/verifyqidusage/".concat(customerId, "/").concat(eventId, "/").concat(queueId, "/").concat(queueIdUsageLimit); | ||
ip = this.contextProvider.getHttpRequest().getUserHostAddress(); | ||
@@ -272,3 +272,3 @@ requestUrl = this.contextProvider.getHttpRequest().getAbsoluteUri(); | ||
} | ||
responseMessage = apiCallResult.responseBody + ". StatusCode: " + apiCallResult.httpStatusCode + ". UrlPath: " + endpointurl; | ||
responseMessage = "".concat(apiCallResult.responseBody, ". StatusCode: ").concat(apiCallResult.httpStatusCode, ". UrlPath: ").concat(endpointurl); | ||
return [3 /*break*/, 5]; | ||
@@ -278,3 +278,3 @@ case 3: | ||
isAllowed = true; | ||
responseMessage = "Error calling verify action endpoint. UrlPath: " + endpointurl + ". Error: " + error_1; | ||
responseMessage = "Error calling verify action endpoint. UrlPath: ".concat(endpointurl, ". Error: ").concat(error_1); | ||
return [3 /*break*/, 5]; | ||
@@ -309,3 +309,3 @@ case 4: return [2 /*return*/, { | ||
}; | ||
UserInQueueService.SDK_VERSION = "javascript-" + "4.1.0"; | ||
UserInQueueService.SDK_VERSION = "javascript-" + "4.1.1"; | ||
return UserInQueueService; | ||
@@ -312,0 +312,0 @@ }()); |
@@ -57,3 +57,3 @@ "use strict"; | ||
UserInQueueStateCookieRepository.getCookieKey = function (eventId) { | ||
return UserInQueueStateCookieRepository._QueueITDataKey + "_" + eventId; | ||
return "".concat(UserInQueueStateCookieRepository._QueueITDataKey, "_").concat(eventId); | ||
}; | ||
@@ -60,0 +60,0 @@ UserInQueueStateCookieRepository.prototype.store = function (eventId, queueId, fixedCookieValidityMinutes, cookieDomain, isCookieHttpOnly, isCookieSecure, redirectType, hashedIp, secretKey) { |
{ | ||
"name": "@queue-it/connector-javascript", | ||
"version": "4.1.0", | ||
"version": "4.1.1", | ||
"description": "Connector to integrate Queue-it into a javascript based server side application.", | ||
@@ -30,4 +30,4 @@ "main": "dist/index.js", | ||
"ts-node": "^10.4.0", | ||
"typescript": "^4.4.4" | ||
"typescript": "^4.9.5" | ||
} | ||
} | ||
} |
# Queue-it Connector for JavaScript | ||
The package enables you to add traffic management support to your website. The documentation can be found at [Queue-it Support](https://support.queue-it.com/). In order to get access please reach out to your Queue-it representative. | ||
The package enables you to add traffic management support to your website. The Connector Implementation Guide can be found via the Queue-it GO Platform | Help | Connector Integration Documentation. In order to get access please reach out to your Queue-it representative. |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
260057
3754