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wroot_src/src/GlobalScripts/CommonFunctions.ts"],"sourcesContent":["import { ApplicationInsights } from \"@microsoft/applicationinsights-web\";\nexport default class Ai {\n constructor(aiConnectionString) {\n Ai.ai = new ApplicationInsights({\n config: {\n connectionString: `InstrumentationKey=${aiConnectionString}`\n }\n });\n Ai.ai.loadAppInsights();\n Ai.ai.trackPageView();\n }\n}\n","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nimport Ai from \"./Ai\";\n/* eslint-disable */\nexport default class CommonFunctions {\n static setupAjaxCalls() {\n $.ajaxSetup({\n xhrFields: {\n withCredentials: true\n }\n });\n }\n static compareArrays(arr1, arr2) {\n return arr1.length === arr2.length && arr1.every((value, index) => value === arr2[index]);\n }\n static mapPopup() {\n const existingPopup = $(document).find(\"#mapPopup\");\n if (existingPopup.length === 1) {\n return existingPopup.data(\"kendoPopup\");\n }\n return $(\"
cxvgxcg
\")\n .appendTo(document.body)\n .kendoPopup()\n .data(\"kendoPopup\");\n }\n static mapOnShapeMouseEnter(e) {\n e.shape.options.set('fill.opacity', 1);\n const oe = e.originalEvent;\n const x = oe.pageX || oe.clientX;\n const y = oe.pageY || oe.clientY;\n const name = e.shape.dataItem.Title;\n const popup = CommonFunctions.mapPopup();\n popup.element.html(`
${name}
`);\n popup.open(x - 50, y - 70);\n }\n static mapOnShapeMouseLeave(e) {\n if (!$(e.originalEvent.relatedTarget).is(\".k-popup, .k-animation-container\")) {\n CommonFunctions.mapPopup().close();\n }\n else {\n CommonFunctions.mapPopup().close();\n }\n CommonFunctions.mapPopup().element.kendoStop(true, true);\n }\n static htmlEncode(value) {\n return $('
').text(value).html();\n }\n static htmlDecode(value) {\n return $('
').html(value).text();\n }\n static isEven(n) {\n return n % 2 === 0;\n }\n static isOdd(n) {\n return Math.abs(n % 2) === 1;\n }\n static formatLongText(text) {\n return `${text.substring(0, 50)}...`;\n }\n static isNullOrWhitespace(input) {\n if (typeof input === 'undefined' || input == null)\n return true;\n if (typeof (input) === 'string') {\n return input.replace(/\\s/g, '').length < 1;\n }\n return false;\n }\n static showXhrError(xhr) {\n const msg = xhr.getResponseHeader(\"message\");\n if (msg && !CommonFunctions.isNullOrWhitespace(msg)) {\n CommonFunctions.showError(TextResources.Views_Fehler, CommonFunctions.htmlDecode(msg));\n }\n else if (xhr.status !== 0 && xhr.readyState !== 0 && !CommonFunctions.isNullOrWhitespace(xhr.responseText)) {\n CommonFunctions.showError(TextResources.Views_Fehler, xhr.responseText);\n }\n else if (xhr.status !== 0 && xhr.readyState !== 0 && !CommonFunctions.isNullOrWhitespace(xhr.statusText)) {\n CommonFunctions.showError(TextResources.Views_Fehler, xhr.statusText);\n }\n else if (xhr.status !== 0 && xhr.readyState !== 0) {\n CommonFunctions.showError(TextResources.Views_Fehler, TextResources.Error_Generic);\n }\n }\n static get(url, doneFunction, failFunction) {\n $.ajax({\n type: 'GET',\n url\n }).done((item) => {\n if (doneFunction != null) {\n doneFunction(item);\n }\n }).fail((result) => {\n if (failFunction != null) {\n failFunction(result);\n }\n });\n }\n static getWithData(url, data, doneFunction, failFunction) {\n return $.ajax({\n type: 'GET',\n url,\n data\n }).done((item) => {\n if (doneFunction != null) {\n doneFunction(item);\n }\n }).fail((result) => {\n if (failFunction != null) {\n failFunction(result);\n }\n else {\n CommonFunctions.showXhrError(result);\n }\n });\n }\n static post(url, value, doneFunction, failFunction) {\n $.ajax({\n url,\n type: 'POST',\n data: JSON.stringify(value),\n contentType: 'application/json;charset=utf-8'\n })\n .done((result) => {\n if (doneFunction != null) {\n doneFunction(result);\n }\n }).fail((result) => {\n if (failFunction != null) {\n failFunction(result);\n }\n else {\n CommonFunctions.showXhrError(result);\n }\n });\n }\n static convertOdataValuesToObject(value) {\n return value.value;\n }\n static showInformation(title, message, autoHideAfter = 5000) {\n CommonFunctions.showNotification(title, message, autoHideAfter, \"info\");\n }\n static showSuccess(title, message, autoHideAfter = 5000) {\n CommonFunctions.showNotification(title, message, autoHideAfter, \"ok\");\n }\n static showError(title, message, autoHideAfter = 5000) {\n CommonFunctions.showNotification(title, message, autoHideAfter, \"error\");\n }\n static showNotification(title, message, autoHideAfter, notificationType) {\n const notification = $(\"#notification\").data().kendoNotification;\n notification.setOptions({ autoHideAfter: autoHideAfter });\n try {\n notification.show({\n title,\n message,\n }, notificationType);\n const container = $(notification.options.appendTo);\n container.scrollTop(container[0].scrollHeight);\n }\n catch (e) {\n Ai.ai.trackException(e);\n }\n }\n static showConfirm(title, message, success, abort) {\n $(\"body\").append(\"
\");\n $(\"#confirmTemplate\").kendoConfirm({ title, content: message, buttonLayout: \"normal\" })\n .data(\"kendoConfirm\").result\n .done(success).fail(() => {\n if (abort) {\n abort();\n }\n });\n }\n static showConfirmAsync(title, message) {\n return __awaiter(this, void 0, void 0, function* () {\n return new Promise(res => {\n this.showConfirm(title, message, () => res(true), () => res(false));\n });\n });\n }\n static addValidation(element) {\n if (!element.attr('data-val')) {\n element.attr('data-val', 'true');\n }\n }\n static addRequiredValidation(element, error) {\n CommonFunctions.addValidation(element);\n element.attr(\"data-val-required\", error);\n }\n static addPhoneNumberValidation(element, error) {\n CommonFunctions.addValidation(element);\n element.attr(\"data-val-phonenumber\", error);\n }\n static addRegexValidation(element, pattern, error) {\n CommonFunctions.addValidation(element);\n element.attr(\"data-val-regex\", error);\n element.attr(\"data-val-regex-pattern\", pattern);\n }\n static addEmailValidation(element, error) {\n CommonFunctions.addValidation(element);\n element.attr(\"data-val-regex\", error);\n element.attr(\"data-val-regex-pattern\", \"^[^@]+@[^@]+$\");\n }\n static addUrlValidation(element, error) {\n CommonFunctions.addValidation(element);\n element.attr(\"data-val-regex\", error);\n element.attr(\"data-val-regex-pattern\", \"^(www\\\\.[A-Za-z0-9\\\\-]+\\\\.|((https?|ftp|news|file)://))[A-Za-z0-9\\\\-]+[\\\\w/:@=\\\\.\\\\+\\\\?,#%&\\\\~]*$\");\n }\n static isEmpty(str) {\n return (!str || str.length === 0);\n }\n static stringToBool(value) {\n if (typeof (value) === \"boolean\") {\n return value;\n }\n switch (value.toString().toLowerCase()) {\n case \"false\":\n case \"no\":\n case \"0\":\n case \"\":\n return false;\n default:\n return true;\n }\n }\n static isNumeric(value) {\n return (value == Number(value));\n }\n static isLoading(selector, modal = true) {\n kendo.ui.progress(selector, true);\n if (!modal) {\n $(\".k-loading-mask\").css(\"pointer-events\", \"none\");\n }\n }\n static isLoadeded(selector) {\n kendo.ui.progress(selector, false);\n }\n static setTabStatus(status, actionUrl, tabId = \"grid\") {\n const tabstrip = $(\".k-tabstrip\").data(\"kendoTabStrip\");\n const tab = $(`.k-tabstrip [data-id=${tabId}]`);\n tab.find(\".k-link\").text(status);\n tab.append(``);\n tabstrip.tabGroup.on(\"click\", \"[data-type='showall']\", (e) => {\n e.preventDefault();\n e.stopPropagation();\n window.location.href = actionUrl;\n });\n }\n static saveInputElements(element) {\n const inputData = {};\n const inputElements = element.find('input, select');\n for (let i = 0; i < inputElements.length; i++) {\n if ($(inputElements[i]).data().kendoNumericTextBox) {\n inputData[inputElements[i].id] = $(inputElements[i]).data().kendoNumericTextBox.value();\n }\n else if ($(inputElements[i]).data().kendoDatePicker) {\n inputData[inputElements[i].id] = $(inputElements[i]).data().kendoDatePicker.value();\n }\n else if ($(inputElements[i]).data().kendoYearlessDatePicker) {\n inputData[inputElements[i].id] = $(inputElements[i]).data().kendoYearlessDatePicker.value();\n }\n else if ($(inputElements[i]).data().kendoDateTimePicker) {\n inputData[inputElements[i].id] = $(inputElements[i]).data().kendoDateTimePicker.value();\n }\n else if ($(inputElements[i]).data().kendoTimePicker) {\n inputData[inputElements[i].id] = $(inputElements[i]).data().kendoTimePicker.value();\n }\n else if ($(inputElements[i]).data().kendoDropDownList) {\n inputData[inputElements[i].id] = $(inputElements[i]).data().kendoDropDownList.value();\n }\n else if ($(inputElements[i]).data().kendoMultiSelect) {\n inputData[inputElements[i].id] = $(inputElements[i]).data().kendoMultiSelect.value();\n }\n else if ($(inputElements[i]).data().kendoMultiSelectWithInsert) {\n inputData[inputElements[i].id] = $(inputElements[i]).data().kendoMultiSelectWithInsert.value();\n }\n else {\n inputData[inputElements[i].id] = $(inputElements[i]).val();\n }\n }\n return inputData;\n }\n static restoreInputElements(element, idValueMap) {\n const inputElements = element.find('input, select');\n for (let i = 0; i < inputElements.length; i++) {\n if (idValueMap[inputElements[i].id] !== undefined) {\n if ($(inputElements[i]).data().kendoNumericTextBox) {\n $(inputElements[i]).data().kendoNumericTextBox.value(idValueMap[inputElements[i].id]);\n }\n else if ($(inputElements[i]).data().kendoDatePicker) {\n $(inputElements[i]).data().kendoDatePicker.value(idValueMap[inputElements[i].id]);\n }\n else if ($(inputElements[i]).data().kendoYearlessDatePicker) {\n $(inputElements[i]).data().kendoYearlessDatePicker.value(idValueMap[inputElements[i].id]);\n }\n else if ($(inputElements[i]).data().kendoDateTimePicker) {\n $(inputElements[i]).data().kendoDateTimePicker.value(idValueMap[inputElements[i].id]);\n }\n else if ($(inputElements[i]).data().kendoTimePicker) {\n $(inputElements[i]).data().kendoTimePicker.value(idValueMap[inputElements[i].id]);\n }\n else if ($(inputElements[i]).data().kendoDropDownList) {\n $(inputElements[i]).data().kendoDropDownList.value(idValueMap[inputElements[i].id]);\n }\n else if ($(inputElements[i]).data().kendoMultiSelect) {\n $(inputElements[i]).data().kendoMultiSelect.value(idValueMap[inputElements[i].id]);\n }\n else if ($(inputElements[i]).data().kendoMultiSelectWithInsert) {\n $(inputElements[i]).data().kendoMultiSelectWithInsert.value(idValueMap[inputElements[i].id]);\n }\n else {\n $(inputElements[i]).val(idValueMap[inputElements[i].id]);\n }\n }\n }\n }\n static loadPartialView(element, action, arg, callback) {\n let loading = $(document).data(\"partialLoading\") || 0;\n $(document).data(\"partialLoading\", ++loading);\n kendo.destroy(element);\n element.load(action, arg, () => {\n let loaded = $(document).data(\"partialLoading\") || 1;\n $(document).data(\"partialLoading\", --loaded);\n if (!loaded) {\n $(document).trigger(\"loadedPartially\");\n }\n if (callback !== undefined) {\n callback();\n }\n });\n }\n static loadPartialAndRestoreInputValues(element, restoreInputs, action) {\n let inputData = {};\n if (restoreInputs) {\n inputData = CommonFunctions.saveInputElements(element);\n }\n CommonFunctions.loadPartialView(element, action, undefined, () => {\n if (restoreInputs) {\n CommonFunctions.restoreInputElements(element, inputData);\n $(\".navigationAndCommandBarBottom\").show();\n }\n });\n }\n static onReady(handler) {\n if ($(document).data(\"partialLoading\")) {\n $(document).one(\"loadedPartially\", handler);\n }\n else {\n $(document).ready(handler);\n }\n }\n static openImageInPopup(sender) {\n let html;\n if (sender.sender) {\n html = $(sender.sender.element).find(\"img\").clone();\n }\n else {\n html = $(sender).clone();\n html = $(html).removeClass(\"gridBase64Column\");\n }\n const popup = $('#imageWindow').data(\"kendoWindow\");\n if (popup) {\n popup.destroy();\n }\n $(\"
\").appendTo(document.body).kendoWindow({ visible: true, modal: true }).data().kendoWindow.content(html).center();\n }\n static openInModalWindow(windowId, action, title, modal, width, maxWidth, maxHeight) {\n let popupWindow = $(`#${windowId}`).data(\"kendoWindow\");\n if (popupWindow) {\n popupWindow.destroy();\n }\n const popup = $(`
`).appendTo(document.body);\n popupWindow = $(popup).kendoWindow({\n maxWidth: maxWidth !== null && maxWidth !== void 0 ? maxWidth : Infinity,\n maxHeight: maxHeight !== null && maxHeight !== void 0 ? maxHeight : Infinity,\n draggable: true,\n visible: false,\n iframe: false,\n refresh: () => { CommonFunctions.isLoadeded($(\"body\")); popupWindow.center().open(); },\n deactivate: () => { popupWindow.destroy(); }\n }).data().kendoWindow;\n popupWindow.setOptions({\n modal,\n width,\n title\n });\n CommonFunctions.isLoading($(\"body\"), false);\n popupWindow.refresh({ url: action });\n return popupWindow;\n }\n static openInPopupWindowSilent(action, title, modal, width, maxWidth, maxHeight) {\n CommonFunctions.openInPopupWindow(action, title, modal, width, maxWidth, maxHeight);\n }\n static openInPopupWindow(action, title, modal, width, maxWidth, maxHeight) {\n return CommonFunctions.openInModalWindow('popupWindow', action, title, modal, width, maxWidth, maxHeight);\n }\n static openInPopupWindowHandler(action, title, modal, width, maxWidth, maxHeight) {\n return () => CommonFunctions.openInPopupWindow(action, title, modal, width, maxWidth, maxHeight);\n }\n static isPopupWindowOpen() {\n const windows = $(\".k-widget.k-window\").not(\".hideToolbarWindow\");\n return windows.length > 0;\n }\n static getPopupWindow() {\n return $(\"#popupWindow\").data(\"kendoWindow\");\n }\n static closePopupWindow() {\n CommonFunctions.getPopupWindow().close();\n }\n static closeContainingWindow(element) {\n const popupWindow = element.closest(\".k-window-content\").data(\"kendoWindow\");\n popupWindow.close();\n }\n static centerPopupWindow() {\n const popupWindow = CommonFunctions.getPopupWindow();\n if (popupWindow !== undefined) {\n popupWindow.center();\n }\n else {\n console.warn(\"called centerPopupWindow, but you are sure this is a popup window ?!\");\n }\n }\n static enableFormValidation(formSelector) {\n const selector = formSelector.kendoValidator((({\n validateInput: (e) => {\n if (!e.valid) {\n $(e.input).closest(\".inputContainer\").addClass(\"invalid\");\n }\n else {\n $(e.input).closest(\".inputContainer\").removeClass(\"invalid\");\n }\n }\n })));\n if (selector && selector.data()) {\n return selector.data().kendoValidator;\n }\n return undefined;\n }\n static datasourceError(e) {\n if (e.errors) {\n let message = `${TextResources.Views_Fehler}
`;\n $.each(e.errors, (key, value) => {\n if (typeof (value) === \"string\") {\n message += `${value}
`;\n }\n else if ('errors' in value) {\n $.each(value.errors, (item) => {\n message += `${item.toString()}
`;\n });\n }\n });\n CommonFunctions.showError(TextResources.Views_Fehler, message);\n }\n else {\n CommonFunctions.showXhrError(e.xhr);\n }\n }\n static formatDateTime(dateTime, includeDays = false, includeSeconds = false) {\n let result = \"\";\n if (includeDays) {\n const days = dateTime.getDay();\n if (days > 0) {\n result += `${days}d `;\n }\n }\n const hours = dateTime.getHours();\n if (hours > 0) {\n result += `${hours}h `;\n }\n const minutes = dateTime.getMinutes();\n const seconds = dateTime.getSeconds();\n result += `${minutes}m `;\n if (includeSeconds) {\n result += `${seconds}s`;\n }\n return result.trim();\n }\n static formatTimeSpan(durationTicks, includeDays = false, includeSeconds = false) {\n let result = \"\";\n let totalSeconds = durationTicks / 10000000;\n if (includeDays) {\n const days = Math.floor(totalSeconds / 86400);\n totalSeconds -= days * 86400;\n if (days > 0) {\n result += `${days}d `;\n }\n }\n const hours = Math.floor(totalSeconds / 3600);\n totalSeconds -= hours * 3600;\n if (hours > 0) {\n result += `${hours}h `;\n }\n const minutes = Math.floor(totalSeconds / 60);\n totalSeconds -= minutes * 60;\n result += `${minutes}m `;\n if (includeSeconds) {\n result += `${totalSeconds}s`;\n }\n return result.trim();\n }\n static jumpToField(e) {\n e.preventDefault();\n const propertyName = $(e.sender.element).attr(\"data-propertySelector\");\n const div = $(`div[data-propertyname='${propertyName}'`);\n if (div.length === 1) {\n const entityBox = div.closest(\".EntityBox\")[0].id;\n eval(`${entityBox}entityBox`).jumpToField(propertyName);\n }\n else {\n CommonFunctions.showError(TextResources.Views_Fehler, TextResources.Error_Generic);\n }\n }\n}\n"],"names":["Ai","constructor","aiConnectionString","ai","config","connectionString","loadAppInsights","trackPageView","__awaiter","thisArg","_arguments","P","generator","Promise","resolve","reject","fulfilled","value","step","next","e","rejected","result","done","then","apply","CommonFunctions","static","$","ajaxSetup","xhrFields","withCredentials","arr1","arr2","length","every","index","existingPopup","document","find","data","appendTo","body","kendoPopup","shape","options","set","oe","originalEvent","x","pageX","clientX","y","pageY","clientY","name","dataItem","Title","popup","mapPopup","element","html","open","relatedTarget","is","close","kendoStop","text","n","Math","abs","substring","input","replace","xhr","msg","getResponseHeader","isNullOrWhitespace","showError","TextResources","Views_Fehler","htmlDecode","status","readyState","responseText","statusText","Error_Generic","url","doneFunction","failFunction","ajax","type","item","fail","showXhrError","JSON","stringify","contentType","title","message","autoHideAfter","showNotification","notificationType","notification","kendoNotification","setOptions","show","container","scrollTop","scrollHeight","success","abort","append","kendoConfirm","content","buttonLayout","this","res","showConfirm","attr","error","addValidation","pattern","str","toString","toLowerCase","Number","selector","modal","kendo","ui","progress","css","actionUrl","tabId","tabstrip","tab","Views_RemoveFilterShowAll","tabGroup","on","preventDefault","stopPropagation","window","location","href","inputData","inputElements","i","kendoNumericTextBox","id","kendoDatePicker","kendoYearlessDatePicker","kendoDateTimePicker","kendoTimePicker","kendoDropDownList","kendoMultiSelect","kendoMultiSelectWithInsert","val","idValueMap","undefined","action","arg","callback","loading","destroy","load","loaded","trigger","restoreInputs","saveInputElements","loadPartialView","restoreInputElements","handler","one","ready","sender","clone","removeClass","kendoWindow","visible","center","windowId","width","maxWidth","maxHeight","popupWindow","Infinity","draggable","iframe","refresh","isLoadeded","deactivate","isLoading","openInPopupWindow","openInModalWindow","not","getPopupWindow","closest","console","warn","formSelector","kendoValidator","validateInput","valid","addClass","errors","each","key","dateTime","includeDays","includeSeconds","days","getDay","hours","getHours","minutes","getMinutes","seconds","getSeconds","trim","durationTicks","totalSeconds","floor","propertyName","div","entityBox","eval","jumpToField"],"sourceRoot":""}