@progress/telerik-jquery-report-viewer 22.24.514 → 22.24.709

Sign up to get free protection for your applications and to get access to all the features.
Files changed (62) hide show
  1. package/README.md +1 -1
  2. package/dist/cjs/accessibility.js +28 -38
  3. package/dist/cjs/base-component.js +26 -0
  4. package/dist/cjs/binder.js +45 -138
  5. package/dist/cjs/controller.js +22 -25
  6. package/dist/cjs/documentMapArea.js +4 -13
  7. package/dist/cjs/event-emitter.js +124 -10
  8. package/dist/cjs/mainMenu.js +22 -31
  9. package/dist/cjs/pagesArea.js +8 -27
  10. package/dist/cjs/parameterValidators.js +4 -7
  11. package/dist/cjs/parameters.js +13 -13
  12. package/dist/cjs/parametersArea.js +31 -47
  13. package/dist/cjs/print.js +3 -4
  14. package/dist/cjs/reportViewer.js +38 -27
  15. package/dist/cjs/scroll.js +4 -6
  16. package/dist/cjs/search.js +327 -377
  17. package/dist/cjs/sendEmail.js +52 -95
  18. package/dist/cjs/serviceClient.js +163 -257
  19. package/dist/cjs/sideMenu.js +15 -24
  20. package/dist/cjs/sr.js +4 -4
  21. package/dist/cjs/template-cache.js +6 -6
  22. package/dist/cjs/toolbar/link-button.js +42 -0
  23. package/dist/cjs/toolbar/page-count-label.js +18 -0
  24. package/dist/cjs/toolbar/page-number-input.js +64 -0
  25. package/dist/cjs/uiFreezeCoordinator.js +17 -16
  26. package/dist/cjs/utils.js +11 -14
  27. package/dist/es/accessibility.js +29 -39
  28. package/dist/es/base-component.js +22 -0
  29. package/dist/es/binder.js +45 -138
  30. package/dist/es/controller.js +23 -26
  31. package/dist/es/documentMapArea.js +4 -13
  32. package/dist/es/event-emitter.js +124 -10
  33. package/dist/es/mainMenu.js +23 -32
  34. package/dist/es/pagesArea.js +9 -28
  35. package/dist/es/parameterValidators.js +5 -8
  36. package/dist/es/parameters.js +14 -14
  37. package/dist/es/parametersArea.js +32 -48
  38. package/dist/es/print.js +4 -5
  39. package/dist/es/reportViewer.js +39 -28
  40. package/dist/es/scroll.js +4 -6
  41. package/dist/es/search.js +328 -378
  42. package/dist/es/sendEmail.js +52 -95
  43. package/dist/es/serviceClient.js +164 -258
  44. package/dist/es/sideMenu.js +16 -25
  45. package/dist/es/sr.js +4 -4
  46. package/dist/es/template-cache.js +7 -7
  47. package/dist/es/toolbar/link-button.js +38 -0
  48. package/dist/es/toolbar/page-count-label.js +14 -0
  49. package/dist/es/toolbar/page-number-input.js +60 -0
  50. package/dist/es/uiFreezeCoordinator.js +17 -16
  51. package/dist/es/utils.js +11 -14
  52. package/dist/font/font-icons.css +4 -4
  53. package/dist/font/font-icons.min.css +3 -3
  54. package/dist/js/telerikReportViewer.js +1071 -1188
  55. package/dist/js/telerikReportViewer.min.js +1 -1
  56. package/dist/js/telerikReportViewer.stringResources.js +4 -4
  57. package/dist/styles/telerikReportViewer.css +3 -3
  58. package/dist/styles/telerikReportViewer.min.css +3 -3
  59. package/dist/templates/telerikReportViewerTemplate-FA.html +4 -4
  60. package/dist/templates/telerikReportViewerTemplate.html +6 -6
  61. package/package.json +3 -2
  62. /package/dist/font/{ReportingIcons-18.1.24.514.ttf → ReportingIcons-18.1.24.709.ttf} +0 -0
@@ -1 +1 @@
1
- var telerikReportViewer=function(e){"use strict";var t=/{(\w+?)}/g,n={DELETE:46,BACKSPACE:8,TAB:9,ESC:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,END:35,HOME:36};function r(){if(window.navigator.userAgent.toLowerCase().indexOf("firefox")>-1){var e=Object.keys(n),t=e.length;return function(r){for(var a=0;a<t;a++)if(n[e[a]]==r)return!0}}return function(e){return!1}}function a(e,t,n,r){return{left:e,top:t,width:n,height:r,right:function(){return e+n},bottom:function(){return t+r},union:function(n){var r=Math.min(e,n.left),i=Math.min(t,n.top);return a(r,i,Math.max(this.right(),n.right())-r,Math.max(this.bottom(),n.bottom())-i)}}}function i(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"==e?t:3&t|8).toString(16)}))}function o(e,t){return c(s(e,t),t)}function l(e,t,n){return e.replace(new RegExp(t,"g"),n)}function s(e,t){return void 0===t&&(t="s"),e.replace(new RegExp("^["+t+"]+"),"")}function c(e,t){return void 0===t&&(t="s"),e.replace(new RegExp("["+t+"]+$"),"")}function u(e,n){var r=Array.isArray(n);return e.replace(t,(function(e,t){return n[r?parseInt(t):t]}))}function d(e){return $("<div>").text(e).html()}function f(e){return/^(\-|\+)?([0-9]+)$/.test(e)?Number(e):NaN}function p(e){return/^(\-|\+)?([0-9]+(\.[0-9]+)?)$/.test(e)?Number(e):NaN}function g(e){return e instanceof Date?e:(/Z|[\+\-]\d\d:?\d\d/i.test(e)||(e+="Z"),new Date(e))}function v(e){return new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()))}function h(e){return new Date(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds())}function m(e,t){if(e instanceof Date&&t instanceof Date){if(e.getTime()!==t.getTime())return!1}else if(e!==t)return!1;return!0}function E(e,t){if(e&&t&&e.report===t.report){var n="";e.parameters&&(n=JSON.stringify(e.parameters));var r="";return t.parameters&&(r=JSON.stringify(t.parameters)),n===r}return!1}function b(e,t){if(null===e)return null===t;if(null===t)return!1;if(e.length!==t.length)return!1;for(var n=e.length-1;n>=0;n--)if(!m(e[n],t[n]))return!1;return!0}function T(){var e=/Version\/(\d+.\d+.\d+) Safari/.exec(navigator.userAgent);return!(e&&e.length>1)||parseFloat(e[1])>=6}function P(e){return!!e&&"internalservererror"===l(e," ","").toLowerCase()}function I(e){var t="ArgumentException";return w(D(e),t,"System."+t)}function _(e){var t="InvalidClientException";return w(D(e),t,"Telerik.Reporting.Services.Engine."+t)}function C(e){return S(D(e))}function S(e){var t="DrawingFactoryUnavailableException";return w(e,t,"Telerik.Drawing.Contract."+t)}function w(e,t,n){return e&&e.exceptionType&&R(e.exceptionType,t,n)}function R(e,t,n){return e&&(e===n||e.endsWith(t))}function A(e){try{return JSON.parse(e,(function(e,t){if(e&&t){var n=e.charAt(0);if(n===n.toUpperCase())this[n.toLowerCase()+e.slice(1)]=t}return t}))}catch(e){return null}}function D(e){return!(!e||!e.responseText)&&A(e.responseText)}function N(){var e,t,n,r,a=0,i=arguments.length;for(r=i>1&&arguments[a++]||{};a<i;a++)if(null!=(n=arguments[a]))for(t in n)r[t],r!==(e=n[t])&&void 0!==e&&(r[t]=e);return r}function M(e,t){var n,r=0;if(y(e))for(n=e.length;r<n&&!1!==t.call(e[r],r,e[r]);r++);else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e}function y(e){return!!Array.isArray(e)||"number"==typeof(!!e&&"length"in e&&e.length)}function k(e,t,n){var r=document.createElement("script");r.src=e,r.onload=function(){t(n)},r.onerror=function(){O(new Error("Failed to load script "+e))},document.head.appendChild(r)}function x(e){return B({dataType:"script",cache:!0,url:e})}function L(e){return e.filter((function(e,t,n){return n.lastIndexOf(e)===t}))}function O(e){var t=window.console;t&&t.error&&t.error(e)}function V(e){e.constructor!=Array&&(e=[e]);for(var t=$(e[0]),n=1;n<e.length;n++)t=t.find(e[n]);return t}function U(e){if(e&&e.length<6){var t=1,n=e.split("");for("#"!==n[0]&&(t=0);t<n.length;t++)n[t]=n[t]+n[t];e=n.join("")}var r=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return r?parseInt(r[1],16)+", "+parseInt(r[2],16)+", "+parseInt(r[3],16):null}function G(e){return!!e&&e.indexOf(",")>-1}function F(e){if("transparent"===e.toLowerCase())return 0;if(!G(e))return 1;-1!==e.indexOf("#")&&(e=U(e));var t=e.split(",").map((function(e){return e.trim()}));return 4===t.length?parseFloat((parseFloat(t[3].replace(/[()]/g,""))/255).toFixed(2)):1}function B(e){return new Promise((function(t,n){$.ajax(e).done((function(e){return t(e)})).fail((function(e,t,r){n(function(e,t,n){return{xhr:e,status:t,error:n}}(e,t,r))}))}))}function H(e){return Object.prototype.toString.call(e).slice(8,-1)}var z=Object.freeze({__proto__:null,isSpecialKey:r,rectangle:a,generateGuidString:i,trim:o,replaceAll:l,lTrim:s,rTrim:c,stringFormat:u,escapeHtml:d,tryParseInt:f,tryParseFloat:p,parseToLocalDate:g,adjustTimezone:v,unadjustTimezone:h,areEqual:m,reportSourcesAreEqual:E,areEqualArrays:b,isSvgSupported:T,isInternalServerError:P,isSystemArgumentException:I,isInvalidClientException:_,isApplicationException:C,isApplicationExceptionInstance:S,isExceptionOfType:function(e,t){return w(D(e),t,t)},exceptionTypeNamesMatch:R,parseJSON:A,getExceptionInstance:D,extend:N,each:M,selector:function(){return document.querySelectorAll(arguments[0])},isArray:y,loadScriptWithCallback:k,loadScript:x,filterUniqueLastOccurance:L,logError:O,findElement:V,toRgbColor:U,isRgbColor:G,getColorAlphaValue:F,$ajax:B,type:H,isEqual:function e(t,n){if(t===n)return!0;if(t!=t&&n!=n)return!0;if(t!=t&&n==n||t==t&&n!=n)return!1;const r=H(t);if(r!==H(n))return!1;if("Array"===r){if(t.length!==n.length)return!1;const r=t.length;for(let a=0;a<r;a++)if(!e(t[a],n[a]))return!1;return!0}if("Object"===r){const r=Object.keys(t),a=Object.keys(n);if(r.length!==a.length)return!1;const i=r.length;for(let a=0;a<i;a++){const i=r[a];if(!e(t[i],n[i]))return!1}return!0}return"Date"===r&&t.getTime()===n.getTime()}});function W(e){return parseInt(e,10)||0}function K(e){var t=$(e);return{left:W(t.css("marginLeft")),right:W(t.css("marginRight")),top:W(t.css("marginTop")),bottom:W(t.css("marginBottom"))}}function j(e){var t=$(e);return{left:W(t.css("paddingLeft")),right:W(t.css("paddingRight")),top:W(t.css("paddingTop")),bottom:W(t.css("paddingBottom"))}}function Y(e){var t=$(e);return{left:W(t.css("borderLeftWidth")),right:W(t.css("borderRightWidth")),top:W(t.css("borderTopWidth")),bottom:W(t.css("borderBottomWidth"))}}function X(e,t,n,r,a){r=r||0,a=a||0;var i=u("scale({0}, {1})",[t=t||1,n=n||1]),o=u("{0} {1}",[r,a]);$(e).css("transform",i).css("transform-origin",o)}var q,J=Object.freeze({__proto__:null,getMargins:K,getPadding:j,getBorderWidth:Y,scale:X});window.telerikReportViewer||(window.telerikReportViewer={}),(q=window.telerikReportViewer).sr||(q.sr={controllerNotInitialized:"Controller is not initialized.",noReportInstance:"No report instance.",missingTemplate:"!obsolete resource!",noReport:"No report.",noReportDocument:"No report document.",missingOrInvalidParameter:"There are missing or invalid parameter values. Please input valid data for the following parameters:\n",invalidParameter:"Please input a valid value.",invalidDateTimeValue:"Please input a valid date.",parameterIsEmpty:"Parameter value cannot be empty.",cannotValidateType:"Cannot validate parameter of type {type}.",loadingFormats:"Loading...",loadingReport:"Loading report...",preparingDownload:"Preparing document to download. Please wait...",preparingPrint:"Preparing document to print. Please wait...",errorLoadingTemplates:"Error loading the report viewer's templates. (templateUrl = '{0}').",errorServiceUrl:"Cannot access the Reporting REST service. (serviceUrl = '{0}'). Make sure the service address is correct and enable CORS if needed. (https://enable-cors.org)",errorServiceVersion:"The version of the Report Viewer '{1}' does not match the version of the Reporting REST Service '{0}'. Please make sure both are running same version.",loadingReportPagesInProgress:"{0} pages loaded so far...",loadedReportPagesComplete:"Done. Total {0} pages loaded.",noPageToDisplay:"No page to display.",errorDeletingReportInstance:"Error deleting report instance: '{0}'.",errorRegisteringViewer:"Error registering the viewer with the service.",noServiceClient:"No serviceClient has been specified for this controller.",errorRegisteringClientInstance:"Error registering client instance.",errorCreatingReportInstance:"Error creating report instance (Report = '{0}').",errorCreatingReportDocument:"Error creating report document (Report = '{0}'; Format = '{1}').",unableToGetReportParameters:"Unable to get report parameters.",errorObtainingAuthenticationToken:"Error obtaining authentication token.",clientExpired:"Click 'Refresh' to restore client session.",promisesChainStopError:"Error shown. Throwing promises chain stop error.",renderingCanceled:"Report processing was canceled.",tryReportPreview:"The report may now be previewed.",parameterEditorSelectNone:"clear selection",parameterEditorSelectAll:"select all",parametersAreaPreviewButton:"Preview",menuNavigateBackwardText:"Navigate Backward",menuNavigateBackwardTitle:"Navigate Backward",menuNavigateForwardText:"Navigate Forward",menuNavigateForwardTitle:"Navigate Forward",menuStopRenderingText:"Stop Rendering",menuStopRenderingTitle:"Stop Rendering",menuRefreshText:"Refresh",menuRefreshTitle:"Refresh",menuFirstPageText:"First Page",menuFirstPageTitle:"First Page",menuLastPageText:"Last Page",menuLastPageTitle:"Last Page",menuPreviousPageTitle:"Previous Page",menuNextPageTitle:"Next Page",menuPageNumberTitle:"Page Number Selector",menuDocumentMapTitle:"Toggle Document Map",menuParametersAreaTitle:"Toggle Parameters Area",menuZoomInTitle:"Zoom In",menuZoomOutTitle:"Zoom Out",menuPageStateTitle:"Toggle FullPage/PageWidth",menuPrintText:"Print...",menuContinuousScrollText:"Toggle Continuous Scrolling",menuSendMailText:"Send an email",menuPrintTitle:"Print",menuContinuousScrollTitle:"Toggle Continuous Scrolling",menuSendMailTitle:"Send an email",menuExportText:"Export",menuExportTitle:"Export",menuPrintPreviewText:"Toggle Print Preview",menuPrintPreviewTitle:"Toggle Print Preview",menuSearchText:"Search",menuSearchTitle:"Toggle Search",menuSideMenuTitle:"Toggle Side Menu",sendEmailFromLabel:"From:",sendEmailToLabel:"To:",sendEmailCCLabel:"CC:",sendEmailSubjectLabel:"Subject:",sendEmailFormatLabel:"Format:",sendEmailSendLabel:"Send",sendEmailCancelLabel:"Cancel",ariaLabelPageNumberSelector:"Page number selector. Showing page {0} of {1}.",ariaLabelPageNumberEditor:"Page number editor",ariaLabelExpandable:"Expandable",ariaLabelSelected:"Selected",ariaLabelParameter:"parameter",ariaLabelErrorMessage:"Error message",ariaLabelParameterInfo:"Contains {0} options",ariaLabelMultiSelect:"Multiselect",ariaLabelMultiValue:"Multivalue",ariaLabelSingleValue:"Single value",ariaLabelParameterDateTime:"DateTime",ariaLabelParameterString:"String",ariaLabelParameterNumerical:"Numerical",ariaLabelParameterBoolean:"Boolean",ariaLabelParametersAreaPreviewButton:"Preview the report",ariaLabelMainMenu:"Main menu",ariaLabelCompactMenu:"Compact menu",ariaLabelSideMenu:"Side menu",ariaLabelDocumentMap:"Document map area",ariaLabelDocumentMapSplitter:"Document map area splitbar.",ariaLabelParametersAreaSplitter:"Parameters area splitbar.",ariaLabelPagesArea:"Report contents area",ariaLabelSearchDialogArea:"Search area",ariaLabelSendEmailDialogArea:"Send email area",ariaLabelSearchDialogStop:"Stop search",ariaLabelSearchDialogOptions:"Search options",ariaLabelSearchDialogNavigateUp:"Navigate up",ariaLabelSearchDialogNavigateDown:"Navigate down",ariaLabelSearchDialogMatchCase:"Match case",ariaLabelSearchDialogMatchWholeWord:"Match whole word",ariaLabelSearchDialogUseRegex:"Use regex",ariaLabelMenuNavigateBackward:"Navigate backward",ariaLabelMenuNavigateForward:"Navigate forward",ariaLabelMenuStopRendering:"Stop rendering",ariaLabelMenuRefresh:"Refresh",ariaLabelMenuFirstPage:"First page",ariaLabelMenuLastPage:"Last page",ariaLabelMenuPreviousPage:"Previous page",ariaLabelMenuNextPage:"Next page",ariaLabelMenuPageNumber:"Page number selector",ariaLabelMenuDocumentMap:"Toggle document map",ariaLabelMenuParametersArea:"Toggle parameters area",ariaLabelMenuZoomIn:"Zoom in",ariaLabelMenuZoomOut:"Zoom out",ariaLabelMenuPageState:"Toggle FullPage/PageWidth",ariaLabelMenuPrint:"Print",ariaLabelMenuContinuousScroll:"Continuous scrolling",ariaLabelMenuSendMail:"Send an email",ariaLabelMenuExport:"Export",ariaLabelMenuPrintPreview:"Toggle print preview",ariaLabelMenuSearch:"Search in report contents",ariaLabelMenuSideMenu:"Toggle side menu",ariaLabelSendEmailFrom:"From email address",ariaLabelSendEmailTo:"Recipient email address",ariaLabelSendEmailCC:"Carbon Copy email address",ariaLabelSendEmailSubject:"Email subject:",ariaLabelSendEmailFormat:"Report format:",ariaLabelSendEmailSend:"Send email",ariaLabelSendEmailCancel:"Cancel sending email",searchDialogTitle:"Search in report contents",searchDialogSearchInProgress:"searching...",searchDialogNoResultsLabel:"No results",searchDialogResultsFormatLabel:"Result {0} of {1}",searchDialogStopTitle:"Stop Search",searchDialogNavigateUpTitle:"Navigate Up",searchDialogNavigateDownTitle:"Navigate Down",searchDialogMatchCaseTitle:"Match Case",searchDialogMatchWholeWordTitle:"Match Whole Word",searchDialogUseRegexTitle:"Use Regex",searchDialogCaptionText:"Find",searchDialogPageText:"page",sendEmailDialogTitle:"Send Email",sendEmailValidationEmailRequired:"Email field is required",sendEmailValidationEmailFormat:"Email format is not valid",sendEmailValidationSingleEmail:"The field accepts a single email address only",sendEmailValidationFormatRequired:"Format field is required",errorSendingDocument:"Error sending report document (Report = '{0}')."});var Z=Z||{};const Q=(window.telerikReportViewer||{}).sr||{},ee=$.extend({},Z,Q);var te={};function ne(e){var t,n,r,a=!1,i={CONFIRM_KEY:13,CONTENT_AREA_KEY:67,DOCUMENT_MAP_AREA_KEY:68,MENU_AREA_KEY:77,PARAMETERS_AREA_KEY:80};if(e=$.extend({},te,e),!(t=e.controller))throw"No controller (telerikReporting.ReportViewerController) has been specified.";function o(){n||(!function(){(n={})[i.DOCUMENT_MAP_AREA_KEY]=V(["div[data-role=telerik_ReportViewer_DocumentMapArea]","div[data-role=treeview]"]),n[i.MENU_AREA_KEY]=V("ul[data-role=telerik_ReportViewer_MainMenu]"),n[i.CONTENT_AREA_KEY]=l();var e=V(["div[data-role=telerik_ReportViewer_ParametersArea]","div.trv-parameters-area-content"]);e&&(n[i.PARAMETERS_AREA_KEY]=e,function(e){if(0===e.length)return;var t=e.parent("div[data-role=telerik_ReportViewer_ParametersArea]");if(!c(t))return;M(e.children(),(function(){$(this).keydown((function(e){e.which==i.CONFIRM_KEY&&(t.find("button.trv-parameters-area-preview-button").focus(),e.preventDefault())}))}))}(e))}(),$(document.body).off("keydown",s),$(document.body).on("keydown",s))}function l(){return V(["div[data-role=telerik_ReportViewer_PagesArea]"])}function s(e){if(n&&e.altKey&&e.ctrlKey){var t=n[e.which];if(t&&c(t.parent())){var a="k-focus";r&&r.removeClass(a),t.addClass(a),t.focus(),r=t,e.preventDefault()}}}function c(e){return e&&!(e.hasClass("k-collapsed")||e.hasClass("trv-hidden"))}return t.reportLoadComplete((function(){o();var e=l();e.length>0&&e.focus()})).pageReady((function(e,t){!function(e){if(!e)return;o(),function(e){if(!e)return;var t=e.find("div [data-reporting-action]");if(!t.length>0)return;M(t,(function(){var e=$(this);e.keydown((function(t){t.which==i.CONFIRM_KEY&&e.click()}))}))}(n[i.CONTENT_AREA_KEY])}(t),a=!0})).error((function(e,t){!function(){var e=V(["div.trv-pages-area","div.trv-error-message"]);if(0===e.length)return;e.attr("tabIndex",0),e.focus()}(),window.setTimeout(o,500)})),t.updateUI((function(e){a&&(function(){var e=$(".trv-report-pager");if(e.length>0){var n=t.getCurrentPageNumber(),r=t.getPageCount();M(e,(function(){var e=$(this);e.attr("aria-label",u(ee.ariaLabelPageNumberSelector,[n,r]));var t=e.find("input[data-role=telerik_ReportViewer_PageNumberInput]");t.length>0&&M(t,(function(){var e=$(this);e.attr("aria-label",ee.ariaLabelPageNumberEditor),e.attr("min","1"),e.attr("max",""+r)}))}))}}(),function(){var e=n[i.MENU_AREA_KEY];if(!e)return;M(e,(function(){M($(this).children("li.k-item"),(function(){var e=$(this);if(!e.hasClass("trv-report-pager")){var t=e.attr("aria-label"),n=u(". {0}",[ee.ariaLabelExpandable]),r=e.find("ul").length>0&&t.indexOf(n)<0?n:"",a=u(". {0}",[ee.ariaLabelSelected]),i=e.hasClass("k-selected")&&t.indexOf(a)<0?a:"",o=t+r+i;e.attr("aria-label",o),e.hasClass("k-disabled")?e.attr("aria-disabled","true"):e.removeAttr("aria-disabled")}}))}))}())})),{getKeyMap:function(){return i},setKeyMap:function(e){i=e,n=void 0}}}const re={viewerInstances:[]};var ae={bind:function(e){var t=Array.prototype.slice.call(arguments,1);!function(e,t){var n=t[0].commands,r=t[1],a='[data-command^="telerik_ReportViewer_"]',i="[data-target-report-viewer]"+a;e.on("click",a,o),re.CommandHandlerAttached||($(document.body).on("click",i,l),re.CommandHandlerAttached=!0);function o(e){var t=$(this).attr("data-command");if(t){var r=t.substring(21),a=n[r];a&&a.enabled()&&a.exec($(this).attr("data-command-parameter")),e.preventDefault()}}function l(e){var t=$(this),n=t.attr("data-command"),r=t.attr("data-target-report-viewer");if(n&&r){var a=n.substring(21),i=$(r).data("telerik_ReportViewer").commands[a];i.enabled()&&i.exec($(this).attr("data-command-parameter")),e.preventDefault()}}M(n,(function(t,n){!function(e,t,n,r){if(t){var a='[data-command="telerik_ReportViewer_'+e+'"]',i='[data-target-report-viewer="'+n.selector+'"]'+a,o=r.find(a),l=$(i);$(t).on("enabledChanged",(function(e){(t.enabled()?$.fn.removeClass:$.fn.addClass).call(o.parent("li"),"k-disabled"),(t.enabled()?$.fn.removeClass:$.fn.addClass).call(l,n.disabledButtonClass)})).on("checkedChanged",(function(e){var r=o.parent("li");(t.checked()?$.fn.addClass:$.fn.removeClass).call(r,function(e){return e.hasClass("trv-menu-toggleable")?"k-selected !k-bg-primary":"k-selected"}(r)),(t.checked()?$.fn.addClass:$.fn.removeClass).call(l,n.checkedButtonClass)}))}}(t,n,r,e)}))}(e,t),M(e.find('[data-role^="telerik_ReportViewer_"]'),(function(){var e=$(this),n=$.fn[e.attr("data-role")];"function"==typeof n&&n.apply(e,t)}))}};function ie(e,t){var n,r=$(e),a=r.attr("data-command");a&&(n=t.commands[a]),n&&(r.click((function(e){n.enabled()?n.exec($(this).attr("data-command-parameter")):e.preventDefault()})),$(n).on("enabledChanged",(function(e){(n.enabled()?$.fn.removeClass:$.fn.addClass).call(r,"disabled")})).on("checkedChanged",(function(e){(n.checked()?$.fn.addClass:$.fn.removeClass).call(r,"checked")})))}var oe="telerik_ReportViewer_LinkButton";function le(e,t){var n=$(e),a=0,i=t.commands.goToPage;function o(e){a===e&&n.is(":focus")||(n.val(e),a=e)}t.controller.pageNumberChange((function(e,t){o(t)})),n.change((function(){var e=f($(this).val());isNaN(e)||o(i.exec(e))})),n.keydown((function(e){if(13==e.which)return $(this).change(),e.preventDefault()})),n.keypress((function(e){if(r(e.keyCode))return!0;var t=n.val()+String.fromCharCode(e.charCode);return/^([0-9]+)$/.test(t)})).on("paste",(function(e){}))}$.fn[oe]=function(e){return M(this,(function(){$.data(this,oe)||$.data(this,oe,new ie(this,e))}))};var se="telerik_ReportViewer_PageNumberInput";function ce(e,t){var n=$(e);t.controller.pageCountChange((function(e,t){n.text(t)}))}$.fn[se]=function(e){return M(this,(function(){$.data(this,se)||$.data(this,se,new le(this,e))}))};var ue="telerik_ReportViewer_PageCountLabel";$.fn[ue]=function(e){return M(this,(function(){$.data(this,ue)||$.data(this,ue,new ce(this,e))}))};const de={INTERACTIVE:"INTERACTIVE",PRINT_PREVIEW:"PRINT_PREVIEW"},fe={AUTO_SELECT:"AUTO_SELECT",FORCE_PDF_PLUGIN:"FORCE_PDF_PLUGIN",FORCE_PDF_FILE:"FORCE_PDF_FILE"},pe={SINGLE_PAGE:"SINGLE_PAGE",CONTINUOUS_SCROLL:"CONTINUOUS_SCROLL"},ge={FIT_PAGE_WIDTH:"FIT_PAGE_WIDTH",FIT_PAGE:"FIT_PAGE",SPECIFIC:"SPECIFIC"},ve={INTEGER:"System.Int64",FLOAT:"System.Double",STRING:"System.String",DATETIME:"System.DateTime",BOOLEAN:"System.Boolean"},he={COMBO_BOX:"COMBO_BOX",LIST_VIEW:"LIST_VIEW"},me={RIGHT:"RIGHT",LEFT:"LEFT",TOP:"TOP",BOTTOM:"BOTTOM"},Ee={RIGHT:"RIGHT",LEFT:"LEFT"};function be(e){var t=!0,n=!1,r={enabled:function(e){if(0===arguments.length)return t;var n=Boolean(e);return t=n,$(this).trigger("enabledChanged"),r},checked:function(e){if(0===arguments.length)return n;var t=Boolean(e);return n=t,$(this).trigger("checkedChanged"),r},exec:e};return r}var Te={};Te[ge.FIT_PAGE]={scaleMode:ge.FIT_PAGE_WIDTH},Te[ge.FIT_PAGE_WIDTH]={scaleMode:ge.SPECIFIC,scale:1},Te[ge.SPECIFIC]={scaleMode:ge.FIT_PAGE};var Pe=[.1,.25,.5,.75,1,1.5,2,4,8];function Ie(e){var t=e.controller;if(!t)throw"No options.controller.";var n=e.history;if(!n)throw"No options.history.";return{historyBack:new be((function(){n.back()})),historyForward:new be((function(){n.forward()})),stopRendering:new be((function(){t.stopRendering()})),goToPrevPage:new be((function(){t.navigateToPage(t.getCurrentPageNumber()-1)})),goToNextPage:new be((function(){t.navigateToPage(t.getCurrentPageNumber()+1)})),goToFirstPage:new be((function(){t.navigateToPage(1)})),goToLastPage:new be((function(){t.navigateToPage(t.getPageCount())})),goToPage:new be((function(e){if(!isNaN(e)){var n=t.getPageCount();return e>n?e=n:e<1&&(e=1),t.navigateToPage(e),e}})),refresh:new be((function(){t.refreshReport(!0)})),export:new be((function(e){e&&t.exportReport(e)})),print:new be((function(){t.printReport()})),pageMode:new be((function(){t.setPageMode(t.getPageMode()===pe.SINGLE_PAGE?pe.CONTINUOUS_SCROLL:pe.SINGLE_PAGE)})),togglePrintPreview:new be((function(){t.setViewMode(t.getViewMode()===de.PRINT_PREVIEW?de.INTERACTIVE:de.PRINT_PREVIEW)})),toggleDocumentMap:new be((function(){var e;t.setDocumentMapVisible({visible:(e={},t.getDocumentMapState(e),!Boolean(e.visible))})})),toggleParametersArea:new be((function(){var e;t.setParametersAreaVisible({visible:(e={},t.getParametersAreaState(e),!Boolean(e.visible))})})),zoom:new be((function(e){t.setScale(e)})),zoomIn:new be((function(){r(1)})),zoomOut:new be((function(){r(-1)})),toggleSideMenu:new be((function(){var e;t.setSideMenuVisible({visible:(e={},t.getSideMenuVisible(e),!Boolean(e.visible))})})),toggleZoomMode:new be((function(e){var n=t.getScale(),r=t.getScaleMode();t.setScale(Te[r].scale||n),t.setScaleMode(Te[r].scaleMode)})),toggleSearchDialog:new be((function(){var e;t.setSearchDialogVisible({visible:(e={},t.getSearchDialogState(e),!Boolean(e.visible))})})),toggleSendEmailDialog:new be((function(){var e;t.setSendEmailDialogVisible({visible:(e={},t.getSendEmailDialogState(e),!Boolean(e.visible))})}))};function r(e){t.setScale(function(e,t){for(var n=-1,r=Pe.length,a=0;a<r;a++){var i=Pe[a];if(e<i){n=a-.5;break}if(e===i){n=a;break}}n+=t,n=t>=0?Math.round(n-.49):Math.round(n+.49);n<0?n=0:n>r-1&&(n=r-1);return Pe[n]}(t.getScale(),e))}}function _e(){return{hasPdfPlugin:function(){return null!==(e=null,M(["AcroPDF.PDF.1","PDF.PdfCtrl.6","PDF.PdfCtrl.5"],(function(t,n){try{if(e=new ActiveXObject(n))return!1}catch(e){}})),e);var e}}}function Ce(){return{hasPdfPlugin:function(){return function(){var e=/Firefox[\/\s](\d+\.\d+)/.exec(navigator.userAgent);if(null!==e&&e.length>1&&parseFloat(e[1])>=19)return!1;var t=navigator.mimeTypes["application/pdf"],n=null!==t?t.enabledPlugin:null;if(n){var r=n.description;return-1!==r.indexOf("Adobe")&&(-1===r.indexOf("Version")||parseFloat(r.split("Version")[1])>=6)}return!1}()}}}function Se(e){return{hasPdfPlugin:function(){return t=navigator.plugins,n=!1,M(t,(function(r,a){if(t[r].name===e||"Adobe Acrobat"===t[r].name)return n=!0,!1})),n;var t,n}}}var we=function(){if(window.navigator){var e=window.navigator.userAgent.toLowerCase();return e.indexOf("msie")>-1||e.indexOf("mozilla")>-1&&e.indexOf("trident")>-1?_e():e.indexOf("firefox")>-1?Ce():e.indexOf("edg/")>-1?Se("Microsoft Edge PDF Plugin"):e.indexOf("chrome")>-1?Se("Chrome PDF Viewer"):e.indexOf("safari")>-1?Se("WebKit built-in PDF"):{hasPdfPlugin:function(){return!1}}}return null}(),Re=!!we&&we.hasPdfPlugin(),Ae=function(){var e;function t(){return window.navigator&&window.navigator.msSaveOrOpenBlob}var n=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)?function(e){window.open(e,"_self")}:function(n){var r=null;if(e||((e=document.createElement("iframe")).style.display="none",e.onload=function(){try{e.contentDocument.execCommand("print",!0,null)}catch(e){O(e)}finally{r&&(window.URL||window.webkitURL).revokeObjectURL(r)}}),function(e){var t=window.location,n=document.createElement("a");n.setAttribute("href",e),""==n.host&&(n.href=n.href);return t.hostname===n.hostname&&t.protocol===n.protocol&&t.port===n.port}(n)&&t())return e.src=n,void document.body.appendChild(e);var a=new XMLHttpRequest;a.open("GET",n,!0),a.responseType="arraybuffer",a.onload=function(n){if(200===this.status){var a=new Blob([this.response],{type:"application/pdf"});t()?window.navigator.msSaveOrOpenBlob(a):(r=(window.URL||window.webkitURL).createObjectURL(a),e.src=r,document.body.appendChild(e))}else console.log("Could not retrieve remote PDF document.")},a.send()};return{print:function(e){n(e)},getDirectPrintState:function(){return Re}}}(),De=function(){var e={};function t(e,t,n,r){var a=[].concat(t).map((function(t){return function(e,t,n){if(e.availableValues){var r=!1;if(M(e.availableValues,(function(e,a){return!(r=n(t,a.value))})),!r){if(e.allowNull&&!t)return t;throw ee.invalidParameter}}return t}(e,n(t),r)}));if(e.multivalue){if(null==t||0==t.length){if(e.allowNull)return t;throw ee.invalidParameter}return a}return a[0]}function n(e,t){return e.allowNull&&-1!=[null,"",void 0].indexOf(t)}return e[ve.STRING]={validate:function(e,n){return t(e,n,(function(t){if(!t){if(e.allowNull)return null;if(e.allowBlank)return"";throw ee.parameterIsEmpty}return t}),(function(e,t){return e==t}))}},e[ve.FLOAT]={validate:function(e,r){return t(e,r,(function(t){var r=p(t);if(isNaN(r)){if(n(e,t))return null;throw ee.parameterIsEmpty}return r}),(function(e,t){return p(e)==p(t)}))}},e[ve.INTEGER]={validate:function(e,r){return t(e,r,(function(t){var r=f(t);if(isNaN(r)){if(n(e,t))return null;throw ee.parameterIsEmpty}return r}),(function(e,t){return f(e)==p(t)}))}},e[ve.DATETIME]={validate:function(e,n){return t(e,n,(function(t){if(e.allowNull&&(null===t||""===t||void 0===t))return null;if(!isNaN(Date.parse(t)))return e.availableValues?t:g(t);throw ee.invalidDateTimeValue}),(function(e,t){return e=g(e),t=g(t),e.getTime()==t.getTime()}))}},e[ve.BOOLEAN]={validate:function(e,r){return t(e,r,(function(t){if(-1!=["true","false"].indexOf((""+t).toLowerCase()))return Boolean(t);if(n(e,t))return null;throw ee.parameterIsEmpty}),(function(e,t){return Boolean(e)==Boolean(t)}))}},{validate:function(t,n){var r=e[t.type];if(!r)throw u(ee.cannotValidateType,t);return r.validate(t,n)}}}();function Ne(e){return 1e3*e}function Me(e,t,n){if(!e)throw ee.noServiceClient;if("number"!=typeof(r=n)||!isFinite(r))throw"sessionTimeoutSeconds must a number and must be finite";var r,a,i;function o(){i<=0||(a=setInterval((function(){e.keepClientAlive(t)}),i))}function l(){a&&(clearInterval(a),a=null)}return i=n<=120?Ne(n)/2:Ne(n-60),{start:o,restart:function(){l(),o()},stop:l}}function ye(){var e=$({});return{on:function(t,n){e.on(t,n)},trigger:function(t,...n){e.trigger(t,...n)}}}var ke={pagePollIntervalMs:500,documentInfoPollIntervalMs:2e3};function xe(e){var t,n,r,a,i,o,l,s,c,p,g,v,h,m,E,b={},S=de.INTERACTIVE,w=pe.CONTINUOUS_SCROLL,y=fe.AUTO_SELECT,k=!1,x=De,$=new ye;z();var L=(e=N({},ke,e)).settings;"function"==typeof L.getPrintMode&&(y=L.getPrintMode());var O=e.serviceClient;if(!O)throw ee.noServiceClient;function V(){t=null,a=null,G(),E=null,L.setClientId(null)}function U(){if("function"!=typeof L.getKeepClientAlive)throw new Error("Required settings.getKeepClientAlive() is not supplied for ReportViewerController");if(L.getKeepClientAlive()&&t)return O.getClientsSessionTimeoutSeconds().then((function(e){(E=new Me(O,t,e)).start()}))}function G(){L.getKeepClientAlive()&&E&&E.stop()}function F(e,t,n){var r="";if(!e.xhr)throw r=e,b.raiseError(q({responseText:r},null,null,null)),r;var a=e.xhr;_(a)&&(k=!0,b.clientExpired());var i=q(a,e.status,P(e.error)?"":e.error,t);if(b.raiseError(i),!n){if(C(a)){var o=D(a);if(o)throw o}throw a.responseJSON&&a.responseJSON.exceptionMessage?a.responseJSON.exceptionMessage:ee.promisesChainStopError}}function B(){return a||(a=O.registerClient().catch((function(e){F(e,ee.errorRegisteringViewer)})).then((function(e){t=e,G(),L.setClientId(t),U()})).catch(V)),a}function H(){var e,r;return i||(i=(e=l,r=s,ne(),O.createReportInstance(t,e,r).catch((function(t){F(t,u(ee.errorCreatingReportInstance,[d(e)]))}))).then((function(e){n=e}))).catch((function(e){i=null})),i}function z(){r=null,n=null,i=null,W()}function W(){p=g=0}function K(e,r,a,i,o){return ne(),re(),O.createReportDocument(t,n,e,r,a,i,o).catch((function(t){F(t,u(ee.errorCreatingReportDocument,[d(l),d(e)]))}))}function j(e,t,r,a){return a.isCanceled||t!==n?Promise.reject():O.getDocumentInfo(e,t,r).catch(F).then((function(n){return n&&n.documentReady||(n.promise=new Promise((function(e,t){window.setTimeout(e,a.documentInfoPollIntervalMs)})).then((function(){return j(e,t,r,a)}))),n}))}function Y(a,i,o,l){var s,c={};function u(e){a&&(r=e,a&&a.beginLoadReport(),ne(),re(),ae(),d(j(t,n,r,c)))}function d(e){e.then((function(e){e.documentReady?function(e){a&&a.onReportLoadComplete(e)}(e):(!function(e){a&&(g=e.pageCount,a.reportLoadProgress(e))}(e),d(e.promise))}))}function f(a){return new Promise((function(i,o){var l=function(){O.getPage(t,n,r,a).catch(F).then((function(t){t.pageReady?i(t):window.setTimeout(l,e.pagePollIntervalMs)}))};l()}))}function p(){if(!s){var t=S===de.PRINT_PREVIEW?"HTML5":"HTML5Interactive",n=function(){var e=X();return e.ContentOnly=!0,e.UseSVG=T(),e}();r={deviceInfo:n},c.documentInfoPollIntervalMs=e.pagePollIntervalMs,a&&a.beforeLoadReport(r),s=B().then(H).then((function(){return K(t,n,i,o,l)})).then(u)}var r;return s}return{beginLoad:function(){p()},beginGetPage:function(t){ne(),p().then((function(){return function(e){a&&a.beginLoadPage(e)}(t),f(t)})).then((function(t){c.documentInfoPollIntervalMs=e.documentInfoPollIntervalMs,a&&a.pageReady(t)}))},getPageData:function(e){return ne(),p().then((function(){return f(e)}))},dispose:function(){a=null},cancel:function(){c.isCanceled=!0}}}function X(){var e={};L.getEnableAccessibility()&&(e.enableAccessibility=!0,e.contentTabIndex=L.contentTabIndex);var t={};b.getSearchDialogState(t);var n=t.visible,r=!L.getSearchMetadataOnDemand()||n;return e.enableSearch=r,e}function q(e,t,n,r){var a,i=A(e.responseText),o="";if(i){var l=R(i.exceptionType||i.error,a="InvalidParameterException","Telerik.Reporting.Services.Engine."+a)?ee.missingOrInvalidParameter:"";if(l)return l;o=d(i.message);var s=d(i.exceptionMessage||i.error_description);s&&(o?o+=" "+s:o=s)}else o=d(e.responseText);return(r||n)&&(o&&(o=" "+o),o=d(r||n)+o),_(e)&&(o+="<br />"+ee.clientExpired),o}function J(){ie();var e={ImmediatePrint:!0},t={deviceInfo:e,handled:!1};if(b.printStarted(t),!t.handled){b.setUIState({operationName:"PrintInProgress",inProgress:!0}),b.showNotification({stringResources:"preparingPrint"});var n="response-content-disposition="+(function(){switch(y){case fe.FORCE_PDF_FILE:case!1:return!1;case fe.FORCE_PDF_PLUGIN:case!0:return!0;default:return Ae.getDirectPrintState()}}()?"inline":"attachment");Q("PDF",e).then((function(e){var t=O.formatDocumentUrl(e.clientId,e.instanceId,e.documentId,n),r={url:t,handled:!1};b.printReady(r),b.hideNotification(),b.setUIState({operationName:"PrintInProgress",inProgress:!1}),r.handled||Ae.print(t)}))}}function Z(e){ie(),e.deviceInfo||(e.deviceInfo=X());var r={deviceInfo:e.deviceInfo,handled:!1,format:e.format};b.sendEmailStarted(r);r.handled||Q(e.format,e.deviceInfo).then((function(r){var a=O.formatDocumentUrl(r.clientId,r.instanceId,r.documentId,"response-content-disposition=attachment");e.url=a,e.handled=!1,b.sendEmailReady(e),delete e.deviceInfo,e.handled||function(e,r){ne(),re(),O.sendDocument(t,n,e,r).catch((function(e){F(e,u(ee.errorSendingDocument,[d(l)]))}))}(r.documentId,e)}))}function Q(a,i){return ie(),B().then(H).then((function(){return K(a,i,!0,r)})).then((function(r){return function(e,t,n,r){return new Promise((function(a,i){var o=function(r){r.then((function(r){r.documentReady?a({clientId:e,instanceId:t,documentId:n}):o(r.promise)}))};o(j(e,t,n,r))}))}(t,n,r,e)}))}function te(e){ie(),re(),ae(),he(),b.refreshReportCore(!1,r,e)}function ne(){if(!t)throw ee.controllerNotInitialized}function re(){if(!n)throw ee.noReportInstance}function ae(){if(!r)throw ee.noReportDocument}function ie(){if(!l)throw ee.noReport}function oe(e,t){return"function"==typeof t[0]?$.on(e,t[0]):$.trigger(e,t),b}function le(e,t){if(e)for(var n=0,r=e.length;n<r;n++){var a=e[n];if(a.id===t)return a.page;var i=le(a.items,t);if(i)return i}return null}function se(e){ce(e),b.reportSourceChanged()}function ce(e){"function"==typeof L.setReportSource&&L.setReportSource(e)}t=L.getClientId(),U();var ue={sorting:function(e){te(e.Id)},toggleVisibility:function(e){te(e.Id)},navigateToReport:function(e){var t,n,r=e.Value;he(),b.setReportSource({report:r.Report,parameters:(t=r.ParameterValues,n={},Array.isArray(t)&&t.forEach((function(e){n[e.Key]=e.Value})),n)}),b.refreshReport(!1)},navigateToUrl:function(e){var t=e.Value;window.open(t.Url,t.Target)},navigateToBookmark:function(e){var t=e.Value,n=le(h,t);b.navigateToPage(n,{type:"bookmark",id:t})},customAction:function(e){}};function ve(e){var t=e.action,n=ue[t.Type];"function"==typeof n&&window.setTimeout((function(){!function(e){b.interactiveActionExecuting(e)}(e),e.cancel||n(t)}),0)}function he(){b.serverActionStarted()}function me(e){if(!I(e.xhr))throw F(e,null,!0),null;throw A(e.xhr.responseText).exceptionMessage}return b.Events={ERROR:"error",EXPORT_STARTED:"exportStarted",EXPORT_DOCUMENT_READY:"exportDocumentReady",PRINT_STARTED:"printStarted",PRINT_DOCUMENT_READY:"printDocumentReady",BEFORE_LOAD_PARAMETERS:"beforeLoadParameters",LOADED_REPORT_CHANGE:"loadedReportChange",BEFORE_LOAD_REPORT:"beforeLoadReport",BEGIN_LOAD_REPORT:"beginLoadReport",REPORT_LOAD_COMPLETE:"reportLoadComplete",REPORT_LOAD_PROGRESS:"reportLoadProgress",REPORT_LOAD_FAIL:"reportLoadFail",BEGIN_LOAD_PAGE:"beginLoadPage",PAGE_READY:"pageReady",VIEW_MODE_CHANGED:"viewModeChanged",PAGE_MODE_CHANGED:"pageModeChanged",PRINT_MODE_CHANGED:"printModeChanged",REPORT_SOURCE_CHANGED:"reportSourceChanged",NAVIGATE_TO_PAGE:"navigateToPage",CURRENT_PAGE_CHANGED:"currentPageChanged",GET_DOCUMENT_MAP_STATE:"trv.GET_DOCUMENT_MAP_STATE",SET_DOCUMENT_MAP_VISIBLE:"trv.SET_DOCUMENT_MAP_VISIBLE",GET_PARAMETER_AREA_STATE:"trv.GET_PARAMETER_AREA_STATE",SET_PARAMETER_AREA_VISIBLE:"trv.SET_PARAMETER_AREA_VISIBLE",SCALE_CHANGED:"scaleChanged",SCALE_MODE_CHANGED:"scaleModeChanged",SERVER_ACTION_STARTED:"serverActionStarted",SET_TOGGLE_SIDE_MENU:"trv.SET_TOGGLE_SIDE_MENU",GET_TOGGLE_SIDE_MENU:"trv.GET_TOGGLE_SIDE_MENU",UPDATE_UI:"trv.UPDATE_UI",CSS_LOADED:"cssLoaded",RELOAD_PARAMETERS:"reloadParameters",INTERACTIVE_ACTION_EXECUTING:"interactiveActionExecuting",INTERACTIVE_ACTION_ENTER:"interactiveActionEnter",INTERACTIVE_ACTION_LEAVE:"interactiveActionLeave",UPDATE_UI_INTERNAL:"trv.UPDATE_UI_INTERNAL",CLIENT_EXPIRED:"clientExpired",TOOLTIP_OPENING:"tooltipOpening",TOOLTIP_CLOSING:"tooltipClosing",PAGE_NUMBER:"trv.PAGE_NUMBER",PAGE_COUNT:"trv.PAGE_COUNT",GET_SEARCH_DIALOG_STATE:"trv.GET_SEARCH_DIALOG_STATE",GET_SEND_EMAIL_DIALOG_STATE:"trv.GET_SEND_EMAIL_DIALOG_STATE",SET_SEARCH_DIALOG_VISIBLE:"trv.SET_SEARCH_DIALOG_VISIBLE",SET_SEND_EMAIL_DIALOG_VISIBLE:"trv.SET_SEND_EMAIL_DIALOG_VISIBLE",SEND_EMAIL_STARTED:"sendEmailStarted",SEND_EMAIL_READY:"sendEmailDocumentReady",SHOW_NOTIFICATION:"trv.SHOW_NOTIFICATION",HIDE_NOTIFICATION:"trv.HIDE_NOTIFICATION",UI_STATE:"trv.UI_STATE",SCROLL_PAGE_READY:"scrollPageReady",UPDATE_SCROLL_PAGE_DIMENSIONS_READY:"trv.UPDATE_SCROLL_PAGE_DIMENSIONS_READY",MISSING_OR_INVALID_PARAMETERS:"missingOrInvalidParameters",RENDERING_STOPPED:"renderingStopped"},N(b,{getPageData:function(e){if(v)return v.getPageData(e)},getReportSource:function(){return null===l?null:{report:l,parameters:N({},s)}},setReportSource:function(e){return null===e?(l=s=null,z(),se(e),this):(l=e.report,s=e.parameters,se(e),this)},updateSettings:function(t){e.settings=N({},t,e.settings)},clearReportSource:function(){return l=s=null,z(),se(void 0),this},getReportDocumentId:function(){return r},setReportDocumentId:function(e){r=e},setParameters:function(e){s=e},setProcessedParameter:function(e){c=e},getPageCount:function(){return g},getCurrentPageNumber:function(){return p},setCurrentPageNumber:function(e){var t,n=f(e);return n!==p&&(p=n,t=n,L.setPageNumber(t),b.currentPageChanged()),this},getScale:function(){return L.getScale()},setScale:function(e){return L.getScale()!==e&&(L.setScale(e),b.scaleChanged(e),b.setScaleMode(ge.SPECIFIC)),b},getScaleMode:function(){return L.getScaleMode()},setScaleMode:function(e){return L.getScaleMode()!==e&&(L.setScaleMode(e),b.scaleModeChanged(e)),b},getViewMode:function(){return S},setViewMode:function(e){return S!==e&&(S=e,b.viewModeChanged(e),l&&b.refreshReportCore(!1,r)),b},getPageMode:function(){return w},setPageMode:function(e){return w!==e&&(w=e,b.pageModeChanged(e),l&&b.refreshReportCore(!1,r)),b},getPrintMode:function(){return y},setPrintMode:function(e){return y!==e&&(y=e,b.printModeChanged(e)),b},previewReport:function(e,t,n){b.loadedReportChange(),b.refreshReportCore(e,t,n)},refreshReportCore:function(e,t,n){!function(e,t,n){l?(v&&(v.dispose(),v=null),z(),(v=new Y(b,!e,t,n)).beginLoad()):b.raiseError(ee.noReport)}(e,t,n)},stopRendering:function(){ie(),re(),ae(),O.deleteReportDocument(t,n,r).catch(F).then((function(){v&&v.cancel(),W(),b.renderingStopped()}))},getReportParameters:function(){var e={};for(var t in c){var n=c[t],r=s[t];n&&n.availableValues?n.multivalue?e[t]=Le(n,r,t):e[t]=$e(n,r,t):e[t]=r}return e},refreshReport:function(e,t,n){if(b.loadedReportChange(),k&&(k=!1,V()),l){var r=b.loadParameters(null);r.then((function(r){var a={},i=[],o=!1;M(r||[],(function(){try{var e=x.validate(this,this.value);a[this.id]=e}catch(e){return o=!0,void i.push(this)}})),o?(b.raiseError(ee.missingOrInvalidParameter),function(e){for(var t=document.querySelector(".trv-pages-area .trv-error-message"),n=document.createElement("ul"),r=0;r<e.length;r++){var a=document.createElement("li");a.classList.add(e[r].name),a.innerText=u("{0} ({1})",[e[r].text,e[r].name]),n.appendChild(a)}t.appendChild(n)}(i),b.missingOrInvalidParameters()):(b.setParameters(a),b.refreshReportCore(e,t,n))})),b.reloadParameters(r)}else b.raiseError(ee.noReport)},exportReport:function(e,t){!function(e,t){ie(),t||(t=X());var n={format:e,deviceInfo:t,handled:!1};b.exportStarted(n),n.handled||(b.setUIState({operationName:"ExportInProgress",inProgress:!0}),b.showNotification({stringResources:"preparingDownload"}),Q(e,n.deviceInfo).then((function(t){var n=O.formatDocumentUrl(t.clientId,t.instanceId,t.documentId,"response-content-disposition=attachment"),r={url:n,format:e,handled:!1,windowOpenTarget:"_self"};b.exportReady(r),b.hideNotification(),b.setUIState({operationName:"ExportInProgress",inProgress:!1}),r.handled||window.open(n,r.windowOpenTarget)})))}(e,t)},sendReport:function(e){Z(e)},printReport:function(){J()},getReportPage:function(e){var t;t=e,v&&v.beginGetPage(t)},executeReportAction:function(e){ve(e)},reportActionEnter:function(e){!function(e){b.interactiveActionEnter({action:e.action,element:e.element})}(e)},reportActionLeave:function(e){!function(e){b.interactiveActionLeave({action:e.action,element:e.element})}(e)},reportToolTipOpening:function(e){!function(e){b.toolTipOpening(e)}(e)},loadParameters:function(e){return null===l?{}:(b.beforeLoadParameters(null===e),function(e,n){return B().then((function(){return O.getParameters(t,e,n||s||{}).catch((function(e){F(e,ee.unableToGetReportParameters)}))}))}(l,e))},getDocumentFormats:function(){return m?Promise.resolve(m):(o||(o=O.getDocumentFormats().catch(F)),o)},getServiceVersion:function(){return O.getServiceVersion().catch(F)},setAuthenticationToken:function(e){O.setAccessToken(e)},clientId:function(){return t},onReportLoadComplete:function(e){g=e.pageCount,h=e.bookmarkNodes,m=e.renderingExtensions,ce(b.getReportSource()),b.reportLoadComplete(e)},raiseError:function(...e){var t=function(e){var t=e.length;return 1===t?e[0]:t>1?u(e[0],Array.prototype.slice.call(e,1)):""}(e);b.error(t)},getSearchResults:function(e,a){return function(e){return e.searchToken&&""!==e.searchToken?O.getSearchResults(t,n,r,e.searchToken,e.matchCase,e.matchWholeWord,e.useRegex).catch(me):Promise.resolve(null)}(e)},on:function(e,t){return $.on(e,t),b},trigger:function(e,t){return $.trigger(e,t),b},showNotification:function(...e){return oe(b.Events.SHOW_NOTIFICATION,e)},hideNotification:function(...e){return oe(b.Events.HIDE_NOTIFICATION,e)},setUIState:function(...e){return oe(b.Events.UI_STATE,e)},error:function(...e){return oe(b.Events.ERROR,e)},reloadParameters:function(...e){return oe(b.Events.RELOAD_PARAMETERS,e)},exportStarted:function(...e){return oe(b.Events.EXPORT_STARTED,e)},exportReady:function(...e){return oe(b.Events.EXPORT_DOCUMENT_READY,e)},sendEmailStarted:function(...e){return oe(b.Events.SEND_EMAIL_STARTED,e)},sendEmailReady:function(...e){return oe(b.Events.SEND_EMAIL_READY,e)},printStarted:function(...e){return oe(b.Events.PRINT_STARTED,e)},printReady:function(...e){return oe(b.Events.PRINT_DOCUMENT_READY,e)},beforeLoadParameters:function(...e){return oe(b.Events.BEFORE_LOAD_PARAMETERS,e)},loadedReportChange:function(...e){return oe(b.Events.LOADED_REPORT_CHANGE,e)},beforeLoadReport:function(...e){return oe(b.Events.BEFORE_LOAD_REPORT,e)},beginLoadReport:function(...e){return oe(b.Events.BEGIN_LOAD_REPORT,e)},reportLoadComplete:function(...e){return oe(b.Events.REPORT_LOAD_COMPLETE,e)},reportLoadProgress:function(...e){return oe(b.Events.REPORT_LOAD_PROGRESS,e)},reportLoadFail:function(...e){return oe(b.Events.REPORT_LOAD_FAIL,e)},beginLoadPage:function(...e){return oe(b.Events.BEGIN_LOAD_PAGE,e)},pageReady:function(...e){return oe(b.Events.PAGE_READY,e)},viewModeChanged:function(...e){return oe(b.Events.VIEW_MODE_CHANGED,e)},pageModeChanged:function(...e){return oe(b.Events.PAGE_MODE_CHANGED,e)},printModeChanged:function(...e){return oe(b.Events.PRINT_MODE_CHANGED,e)},reportSourceChanged:function(...e){return oe(b.Events.REPORT_SOURCE_CHANGED,e)},navigateToPage:function(...e){return oe(b.Events.NAVIGATE_TO_PAGE,e)},currentPageChanged:function(...e){return oe(b.Events.CURRENT_PAGE_CHANGED,e)},getDocumentMapState:function(...e){return oe(b.Events.GET_DOCUMENT_MAP_STATE,e)},setDocumentMapVisible:function(...e){return oe(b.Events.SET_DOCUMENT_MAP_VISIBLE,e)},getParametersAreaState:function(...e){return oe(b.Events.GET_PARAMETER_AREA_STATE,e)},setParametersAreaVisible:function(...e){return oe(b.Events.SET_PARAMETER_AREA_VISIBLE,e)},setSideMenuVisible:function(...e){return oe(b.Events.SET_TOGGLE_SIDE_MENU,e)},getSideMenuVisible:function(...e){return oe(b.Events.GET_TOGGLE_SIDE_MENU,e)},scaleChanged:function(...e){return oe(b.Events.SCALE_CHANGED,e)},scaleModeChanged:function(...e){return oe(b.Events.SCALE_MODE_CHANGED,e)},serverActionStarted:function(...e){return oe(b.Events.SERVER_ACTION_STARTED,e)},cssLoaded:function(...e){return oe(b.Events.CSS_LOADED,e)},interactiveActionExecuting:function(...e){return oe(b.Events.INTERACTIVE_ACTION_EXECUTING,e)},interactiveActionEnter:function(...e){return oe(b.Events.INTERACTIVE_ACTION_ENTER,e)},interactiveActionLeave:function(...e){return oe(b.Events.INTERACTIVE_ACTION_LEAVE,e)},updateUI:function(...e){return oe(b.Events.UPDATE_UI,e)},updateUIInternal:function(...e){return oe(b.Events.UPDATE_UI_INTERNAL,e)},toolTipOpening:function(...e){return oe(b.Events.TOOLTIP_OPENING,e)},pageNumberChange:function(...e){return oe(b.Events.PAGE_NUMBER,e)},pageCountChange:function(...e){return oe(b.Events.PAGE_COUNT,e)},getSearchDialogState:function(...e){return oe(b.Events.GET_SEARCH_DIALOG_STATE,e)},getSendEmailDialogState:function(...e){return oe(b.Events.GET_SEND_EMAIL_DIALOG_STATE,e)},setSearchDialogVisible:function(...e){return oe(b.Events.SET_SEARCH_DIALOG_VISIBLE,e)},setSendEmailDialogVisible:function(...e){return oe(b.Events.SET_SEND_EMAIL_DIALOG_VISIBLE,e)},scrollPageReady:function(...e){return oe(b.Events.SCROLL_PAGE_READY,e)},updatePageDimensionsReady:function(...e){return oe(b.Events.UPDATE_SCROLL_PAGE_DIMENSIONS_READY,e)},missingOrInvalidParameters:function(...e){return oe(b.Events.MISSING_OR_INVALID_PARAMETERS,e)},renderingStopped:function(...e){return oe(b.Events.RENDERING_STOPPED,e)},clientExpired:function(...e){return oe(b.Events.CLIENT_EXPIRED,e)},dispose:function(){G(),this.serviceClientSentinel=null}}),b}function $e(e,t,n){try{var r=e.availableValues.find((e=>e.value===t));if(!r)throw new Error(`The available values of parameter ${n} do not contain Value property that equals ${t}`);return{valueMember:t,displayMember:r.name}}catch(e){O(e)}}function Le(e,t,n){var r=[];for(var a in t)r.push($e(e,t[a],n));return r}const Oe={EXPORT_BEGIN:"EXPORT_BEGIN",EXPORT_END:"EXPORT_END",PRINT_BEGIN:"PRINT_BEGIN",PRINT_END:"PRINT_END",RENDERING_BEGIN:"RENDERING_BEGIN",RENDERING_END:"RENDERING_END",PAGE_READY:"PAGE_READY",ERROR:"ERROR",UPDATE_UI:"UPDATE_UI",INTERACTIVE_ACTION_EXECUTING:"INTERACTIVE_ACTION_EXECUTING",INTERACTIVE_ACTION_ENTER:"INTERACTIVE_ACTION_ENTER",INTERACTIVE_ACTION_LEAVE:"INTERACTIVE_ACTION_LEAVE",VIEWER_TOOLTIP_OPENING:"VIEWER_TOOLTIP_OPENING",SEND_EMAIL_BEGIN:"SEND_EMAIL_BEGIN",SEND_EMAIL_END:"SEND_EMAIL_END"};function Ve(e){var t=e.controller;if(!t)throw"No controller (telerikReporting.reportViewerController) has been specified.";var n=e.settings,r=n.getHistory()||{records:[],position:-1};function a(){var e=r.records;return e.length>0?e[r.position]:null}function i(){n.setHistory(r)}function o(e){!function(){var e=r.records.length-1;for(;e>=0&&!0===r.records[e].temp;)r.records.splice(e,1),r.position>=e&&r.position--,e--}();var n,o,l,s=a(),c=t.getReportSource();s&&E(s.reportSource,c)||(n={reportSource:c,pageNumber:1,temp:e},o=r.records,l=r.position,(o=Array.prototype.slice.call(o,0,l+1)).push(n),r.records=o,r.position=o.length-1,i())}function l(e){t.setReportDocumentId(e.reportDocumentId),t.setViewMode(e.viewMode),t.setReportSource(e.reportSource),t.refreshReport(!1,e.reportDocumentId),t.navigateToPage(e.pageNumber)}function s(e){var t=r.position,n=r.records.length,a=t+e;return 0<=a&&a<n}function c(e){var t=r.position,n=r.records.length,o=t+e;o<0?o=0:o>=n&&(o=n-1),o!=t&&(r.position=o,i(),l(a()))}return t.loadedReportChange((function(){o(!0)})).currentPageChanged((function(){var e;(e=a())&&(e.pageNumber=t.getCurrentPageNumber(),e.viewMode=t.getViewMode(),e.reportDocumentId=t.getReportDocumentId(),i())})).reportLoadComplete((function(e,t){o(!1)})).clientExpired((function(){for(var e=r.records,t=0;t<e.length;t++)e[t].reportDocumentId=null})),{back:function(){c(-1)},forward:function(){c(1)},canMoveBack:function(){return s(-1)},canMoveForward:function(){return s(1)},loadCurrent:function(){var e=a();return e&&l(e),Boolean(e)}}}function Ue(e,t){var n,r;function a(e,n){var r=t[e];"function"==typeof r&&r(n)}!function(e){if("function"==typeof $.fn.kendoTouch)try{$(e).mousedown((function(){r=!0})).mouseup((function(){r=!1})).kendoTouch({multiTouch:!0,enableSwipe:!0,swipe:function(e){r||function(e){a("swipe",e)}(e)},gesturestart:function(e){r||function(e){n=kendo.touchDelta(e.touches[0],e.touches[1]).distance}(e)},gestureend:function(e){},gesturechange:function(e){r||function(e){var t=kendo.touchDelta(e.touches[0],e.touches[1]).distance;(function(e){a("pinch",e)})({distance:t,lastDistance:n}),n=t}(e)},doubletap:function(e){r||function(e){a("doubletap",e)}(e)},touchstart:function(e){r||a("touchstart")}})}catch(e){throw console.error("Instantiation of Kendo Touch threw an exception",e),e}}(e)}var Ge={controller:{},$placeholder:null,$pageContainer:null,pageContainer:null,$pageWrapper:null,pageWrapper:null,viewMode:null,loadedPage:{},scrollInProgress:!1,enabled:!1,pageCount:0,additionalTopOffset:130,pageDistance:20,oldScrollTopPosition:0,skeletonTemplate:'<div class="trv-report-page trv-skeleton-page trv-skeleton-{0}" style="{1}" data-page="{0}"><div class="trv-skeleton-wrapper" style="{2}"></div></div>',init:function(e,t){var n=this;n.$placeholder=$("[data-selector='"+t.viewerSelector+"']").find(e),n.$pageContainer=this.$placeholder.find(".trv-page-container"),n.pageContainer=this.$pageContainer[0],n.$pageWrapper=this.$placeholder.find(".trv-page-wrapper"),n.pageWrapper=this.$pageWrapper[0],n.controller=t.controller,n.viewMode=null,n.loadedPage={},n.scrollInProgress=!1,n.enabled=!1,n.pageCount=0,n.controller.scaleChanged((function(e,t){n.enabled&&setTimeout((function(){n._loadMorePages(),n._keepCurrentPageInToView()}),100)})).loadedReportChange((function(e){n.enabled&&(n.disable(),"loadedReportChange"!==e.type&&setTimeout((function(){n.controller.getPageData(1).then((function(e){n.renderPage(e)}))})))})).viewModeChanged((function(e){n.enabled&&n.disable()})).interactiveActionExecuting((function(e,t){var r=t.action.Type;!n.enabled||"sorting"!==r&&"toggleVisibility"!==r||n.disable()})).updatePageDimensionsReady((function(e,t){n.enabled&&n._currentPageNumber()>0&&n._keepCurrentPageInToView()})).pageCountChange((function(e,t){n.enabled&&n.pageCount!==t&&(n._currentPageNumber()>0&&!n.scrollInProgress&&n._loadMorePages(),t>1&&n._initEvents(),n.pageCount=t)}))},isEnabled:function(){return this.enabled},disable:function(){this.$pageWrapper.empty(),this.enabled=!1,this.loadedPage={},this.pageCount=0,this.$placeholder.removeClass("scrollable"),this._unbind()},enable:function(){this.enabled=!0,this.$placeholder.addClass("scrollable"),this._initEvents()},renderPage:function(e){var t=this,n=t.controller.getViewMode(),r=t.$placeholder.find('[data-page="'+e.pageNumber+'"]');t.enabled?(n===t.viewMode&&r.length?t._navigateToPage(e,r):t._updatePageArea(e),t.viewMode=t.controller.getViewMode()):(t.enabled=!0,t.$placeholder.addClass("scrollable"),n===t.viewMode&&r.length?(t._render(e,!0),this.$pageContainer.scrollTop(3),t._setCurrentPage(e.pageNumber)):t._updatePageArea(e),t.viewMode=t.controller.getViewMode(),t._loadMorePages())},navigateToElement:function(e,t){var n=this;n.scrollInProgress=!0,n._isSkeletonScreen(null,t)?n.controller.getPageData(t).then((function(r){n._render(r,!1),n.$pageContainer.animate({scrollTop:e},500,(function(){n._setCurrentPage(t),setTimeout((function(){n.scrollInProgress=!1}),100)}))})):n.$pageContainer.animate({scrollTop:e},500,(function(){n._setCurrentPage(t),setTimeout((function(){n.scrollInProgress=!1}),100)}))},_setCurrentPage:function(e){var t=this;e!==t._currentPageNumber()&&t.controller.setCurrentPageNumber(e),t.controller.getPageCount()>1&&(t.$placeholder.find(".k-state-default").removeClass("k-state-default"),t.$placeholder.find('[data-page="'+e+'"]').addClass("k-state-default")),t._loadNextPreviousPage(e)},_updatePageArea:function(e){var t=this,n=0,r=e.pageNumber;t.scrollInProgress=!0,r>1&&t._generateSkeletonScreens(r),t._render(e,!1),t._setCurrentPage(e.pageNumber),setTimeout((function(){n=r>1?t.$placeholder.find('[data-page="'+r+'"]').position().top:0,t.$pageContainer.animate({scrollTop:n},0,(function(){t.scrollInProgress=!1}))}),100)},_navigateToPage:function(e,t){var n=this;n.scrollInProgress=!0;var r=t.position().top,a=n.$placeholder.find(".trv-report-page"),i=e.pageNumber;$(a[0]).height(),n._isSkeletonScreen(t,i)?n.controller.getPageData(i).then((function(e){n._render(e,!1),n.$pageContainer.animate({scrollTop:r},500,(function(){setTimeout((function(){n._setCurrentPage(e.pageNumber),n.scrollInProgress=!1}))}))})):(n._updatePageContent(e,t),n.$pageContainer.animate({scrollTop:r},500,(function(){setTimeout((function(){n._setCurrentPage(e.pageNumber),n.scrollInProgress=!1}))})))},_updatePageContent:function(e,t){this._updatePageStyle(e);var n=e.pageNumber,r=$($.parseHTML(e.pageContent)).find("div.sheet"),a=this.$placeholder.find('[data-page="'+n+'"]');r.css("margin",0),a.append(r).append($('<div class="trv-page-overlay"></div>')),t.replaceWith(a),this.controller.scrollPageReady({page:e,target:a})},_currentPageNumber:function(){return this.controller.getCurrentPageNumber()},_isSkeletonScreen:function(e,t){return e||(e=this.$placeholder.find('[data-page="'+t+'"]')),e.hasClass("trv-skeleton-"+t)},_addSkeletonScreen:function(e,t){var n=this,r=t?parseInt(e+1):parseInt(e-1),a=n.$placeholder.find('[data-page="'+r+'"]'),i=a.attr("style"),o=a.find("sheet").attr("style"),l=u(n.skeletonTemplate,[e,i,o]);t?n.$pageWrapper.prepend(l):n.$pageWrapper.append(l)},_generateSkeletonScreens:function(e){for(var t=this,n="",r=this.$placeholder.find('[data-page="1"]'),a=r.attr("style"),i=r.find("sheet").attr("style"),o=t.$placeholder.find(".trv-report-page").last().attr("data-page"),l=o?parseInt(o)+1:1;l<e;l++)n+=u(t.skeletonTemplate,[l,a,i]);t.$pageWrapper.append($(n))},_loadMorePages:function(){var e=this,t=e.controller.getPageCount(),n=e.$pageContainer.innerHeight()>e.$pageWrapper.innerHeight();if(t>1)if(n){e.scrollInProgress=!0;var r=parseInt(e.$placeholder.find(".trv-report-page").last().attr("data-page"))+1;r<=t&&e.controller.getPageData(r).then((function(t){e._render(t,!1),e._loadMorePages(),e.scrollInProgress=!1}))}else e._loadVisiblePages(),e.scrollInProgress=!1},_loadVisiblePages:function(){var e=this,t=e.$placeholder.find(".trv-report-page");$.each(t,(function(t,n){var r=$(n),a=parseInt(r.attr("data-page"));e._scrolledInToView(r)&&e._isSkeletonScreen(r,a)&&e.controller.getPageData(a).then((function(t){e._render(t,!1)}))}))},_scrolledInToView:function(e){var t=e[0].getBoundingClientRect(),n=e.closest(".trv-pages-area")[0].getBoundingClientRect(),r=n.top,a=n.top+n.height,i=t.top,o=i+e.outerHeight(!0),l=this.additionalTopOffset+r;return i>0&&i<a||o<a&&o>l},_render:function(e,t){var n=this,r=e.pageNumber,a=n.$placeholder.find('[data-page="'+r+'"]');if(t||!a||!a.length||n._isSkeletonScreen(a,r)){n.loadedPage[r]=e,n._updatePageStyle(e);var i=$($.parseHTML(e.pageContent)).find("div.sheet"),o=$('<div class="trv-report-page" data-page="'+r+'"></div>');i.css("margin",0),o.append(i).append($('<div class="trv-page-overlay"></div>')),t&&n.$pageWrapper.empty(),n.$pageWrapper.removeData().data("pageNumber",r);var l=n.$placeholder.find(".trv-skeleton-"+r);l.length?l.replaceWith(o):n.$pageWrapper.append(o),n.controller.scrollPageReady({page:e,target:o})}},_updatePageStyle:function(e){var t,n=this,r=n.loadedPage[n._lastLoadedPage()]||e,a="trv-"+n.controller.clientId()+"-styles";$("#"+a).remove(),(t=$("<style id="+a+"></style>")).append(r.pageStyles),t.appendTo("head")},_lastLoadedPage:function(){var e;for(var t in this.loadedPage)this.loadedPage.hasOwnProperty(t)&&(e=t);return e},_loadNextPreviousPage:function(e){var t,n,r,a,i=this;e<i.controller.getPageCount()&&(t=e+1,r=i.$placeholder.find('[data-page="'+t+'"]')),e>1&&(n=e-1,a=i.$placeholder.find('[data-page="'+n+'"]')),a&&a.length&&i._isSkeletonScreen(a,n)&&i.controller.getPageData(n).then((function(e){i._render(e,!1)})),r&&r.length&&i._isSkeletonScreen(r,t)&&i.controller.getPageData(t).then((function(e){i._render(e,!1)}))},_clickPage:function(e){var t=this,n=t._currentPageNumber(),r=parseInt(e.attr("data-page"));n!==r&&(t._isSkeletonScreen(e,r)?t.controller.getPageData(r).then((function(e){t._render(e,!1,!0),t._setCurrentPage(e.pageNumber)})):t._setCurrentPage(r))},_initEvents:function(){var e=this;e.$pageContainer.off("click",".trv-report-page").on("click",".trv-report-page",(function(t){e._clickPage($(t.currentTarget))})),e.$pageContainer.scroll((function(){var t=e.$placeholder.find(".trv-report-page"),n=parseInt((e.$pageContainer.scrollTop()+e.$pageContainer.innerHeight()).toFixed(0));e.scrollInProgress||e.oldScrollTopPosition===n||(e.oldScrollTopPosition>n?e._scrollUp(t):e._scrollDown(t,n)),e.oldScrollTopPosition=n})),e.$pageContainer.scroll((function(){var t=e.$placeholder.find(".trv-report-page"),n=parseInt((e.$pageContainer.scrollTop()+e.$pageContainer.innerHeight()).toFixed(0));!e.scrollInProgress&&t.length&&e.oldScrollTopPosition!==n&&e._advanceCurrentPage(t)}))},_unbind:function(){this.$pageContainer.off("click",".trv-report-page"),this.$pageContainer.off("scroll")},_advanceCurrentPage:function(e){var t,n=this,r=n._findNewCurrentPage(e),a=n._currentPageNumber(),i=n._scrolledInToView(n.$placeholder.find('[data-page="'+a+'"]'));-1!==r?(r=$(r),a===(t=parseInt(r.attr("data-page")))||i||(n._isSkeletonScreen(r,t)?n.controller.getPageData(t).then((function(e){n._render(e,!1,!0),n._setCurrentPage(e.pageNumber)})):n._setCurrentPage(t))):console.log("Page not found - ",r)},_findNewCurrentPage:function(e){var t=this,n=Math.floor(e.length/2),r=t._findPageInViewPort(n,e);return 1===e.length?e[0]:0===r?e[n]:r<0&&e.length>1?t._findNewCurrentPage(e.splice(n,Number.MAX_VALUE)):r>0&&e.length>1?t._findNewCurrentPage(e.splice(0,n)):-1},_findPageInViewPort:function(e,t){var n=this.$placeholder.find(t[e]),r=n[0].getBoundingClientRect(),a=n.closest(".trv-pages-area")[0].getBoundingClientRect(),i=a.top;a.top,a.height;var o=r.top,l=o+n.outerHeight(!0),s=this.additionalTopOffset+i;return o<=s&&s<l?0:l<s?-1:1},_scrollDown:function(e,t){var n=this;if(t>=n.pageContainer.scrollHeight-5){var r=parseInt($(e[e.length-1]).attr("data-page"))+1;n._currentPageNumber()<r&&r<=n.controller.getPageCount()&&(n._addSkeletonScreen(r,!1),n.controller.getPageData(r).then((function(e){n._render(e,!1)})))}else n._advanceCurrentPage(e),n._loadVisiblePages()},_scrollUp:function(e){var t=this;if(0===t.$pageContainer.scrollTop()){var n=$(e[0]),r=parseInt(n.attr("data-page"))-1;t._currentPageNumber()>r&&r>=1&&(t._addSkeletonScreen(r,!0),t.controller.getPageData(r).then((function(e){t._render(e,!1),t.$pageContainer.scrollTop(3)})))}else t._advanceCurrentPage(e),t._loadVisiblePages()},_keepCurrentPageInToView:function(){var e=this,t=e.$placeholder.find('[data-page="'+e._currentPageNumber()+'"]'),n=t.position().top,r=t.innerHeight(),a=e.$pageContainer.innerHeight();e.scrollInProgress=!0,r<a&&(n=parseInt(n-(a-r)/2)),e.$pageContainer.animate({scrollTop:n},0,(function(){setTimeout((function(){e.scrollInProgress=!1}),100)}))}},Fe={$placeholder:null,$scrollableContainer:null,itemsInitialState:{},xFrozenAreasBounds:{},yFrozenAreasBounds:{},freezeMaxZIndex:{},zIndex:1,freezeBGColor:{},currentlyfreezedContainer:{vertical:{},horizontal:{}},isInitialize:!1,scaleFactor:null,init:function(e){this.$placeholder=e,this.$scrollableContainer=e.find(".trv-page-container"),this.isInitialize&&this.reset(e),this._attachToScrollEvent(),this.isInitialize=!0},reset:function(e){this.$placeholder=e,this.$scrollableContainer=e.find(".trv-page-container"),this.itemsInitialState={},this.xFrozenAreasBounds={},this.yFrozenAreasBounds={},this.currentlyfreezedContainer={vertical:{},horizontal:{}}},setScaleFactor:function(e){this.scaleFactor=e},_attachToScrollEvent:function(){var e=this;this.$scrollableContainer.scroll((function(){var t=e.$scrollableContainer.find("div[data-sticky-id]");if(t.length)for(var n=t.map((function(e,t){return $(t).attr("data-sticky-id")})).get(),r=n.filter((function(e,t){return t===n.indexOf(e)})),a=e.$scrollableContainer.scrollTop(),i=e.$scrollableContainer.scrollLeft(),o=0;o<r.length;o++){var l=r[o];e.itemsInitialState[l]||e._saveFreezeItemsInitialState(l),e._updateFreezeItemsOnScroll(l,a,i)}}))},_saveFreezeItemsInitialState:function(e){var t,n,r=$("[data-sticky-direction][data-sticky-id='"+e+"']"),i=$("[data-reporting-action][data-sticky-id='"+e+"']");this.itemsInitialState[e]={},this.freezeBGColor[e]=$("[data-id='"+e+"']").attr("data-sticky-bg-color");for(var o=0;o<r.length;o++){var l=$(r[o]),s=l.attr("data-sticky-direction"),c=l.attr("data-id"),u=l.position(),d={top:u.top/this.scaleFactor,left:u.left/this.scaleFactor},f=a(d.left,d.top,l.outerWidth(!0)*this.scaleFactor,l.outerHeight(!0)*this.scaleFactor);switch(s){case"Vertical":t=t?t.union(f):f;break;case"Horizontal":n=n?n.union(f):f}this._saveFreezeItemInitialState(e,l,c,d)}this.freezeMaxZIndex[e]=i.length?i.css("zIndex"):this.zIndex,this.yFrozenAreasBounds[e]=t,this.xFrozenAreasBounds[e]=n},_saveFreezeItemInitialState:function(e,t,n,r){var a=t.css("background-color"),i=this._hasSetBgColor(a),o={top:r.top,left:r.left,zIndex:t.css("zIndex"),hasBgColor:i};this.itemsInitialState[e][n]=o},_updateFreezeItemsOnScroll:function(e,t,n){var r=$("div[data-id='"+e+"']");if(this._isInScrollVisibleArea(r)){var a=r.closest(".trv-report-page"),i=a.position(),o=parseFloat(a.css("margin-top")),l=parseFloat(a.css("padding-top")),s=parseFloat(a.css("padding-left")),c=parseFloat(a.css("border-top-width")),u=parseFloat(a.css("border-left-width")),d=$("[data-sticky-direction*='Horizontal'][data-sticky-id='"+e+"']"),f=$("[data-sticky-direction*='Vertical'][data-sticky-id='"+e+"']"),p=d.length>0,g=f.length>0,v=r.position(),h=v.top+i.top+o+l+c,m=v.left+s+u,E=t-h,b=n-m;g&&E>0?t<=r.outerHeight()*this.scaleFactor+h-this.yFrozenAreasBounds[e].height&&(this.currentlyfreezedContainer.vertical[e]=!0,this._updateUIElementsPosition(f,"top",E/this.scaleFactor,e)):this.currentlyfreezedContainer.vertical[e]&&(delete this.currentlyfreezedContainer.vertical[e],this._updateUIElementsPosition(f,"top",-1,e)),p&&b>0?n<=r.outerWidth()*this.scaleFactor+m-this.xFrozenAreasBounds[e].width&&(this.currentlyfreezedContainer.horizontal[e]=!0,this._updateUIElementsPosition(d,"left",b/this.scaleFactor,e)):this.currentlyfreezedContainer.horizontal[e]&&(delete this.currentlyfreezedContainer.horizontal[e],this._updateUIElementsPosition(d,"left",-1,e))}else(this.currentlyfreezedContainer.horizontal[e]||this.currentlyfreezedContainer.vertical[e])&&this._resetToDefaultPosition(e)},_resetToDefaultPosition:function(e){var t=$("[data-sticky-direction*='Horizontal'][data-sticky-id='"+e+"']"),n=$("[data-sticky-direction*='Vertical'][data-sticky-id='"+e+"']");this._updateUIElementsPosition(n,"top",-1,e),this._updateUIElementsPosition(t,"left",-1,e),delete this.currentlyfreezedContainer.horizontal[e],delete this.currentlyfreezedContainer.vertical[e]},_updateUIElementsPosition:function(e,t,n,r){for(var a=0;a<e.length;a++){var i=$(e[a]),o=i.attr("data-sticky-direction").indexOf(",")>0,l=i.attr("data-id"),s=this.itemsInitialState[r][l],c=s[t],u=s.zIndex,d=s.hasBgColor,f=1,p=this.freezeMaxZIndex[r]?this.freezeMaxZIndex[r]:f,g={"z-index":f=o?"auto"!==u?u:p+2:"auto"!==u?u+1:p};n>=0?c+=n:g["z-index"]=u,d||this._applyBgColorOnScroll(i,o,d,n>=0,r),g[t]=c+"px",i.css(g)}},_applyBgColorOnScroll:function(e,t,n,r,a){return!!e.is("img")||(t&&this._isFrozen(a)&&!n?(e.css("background-color",this.freezeBGColor[a]),!0):void(r?e.css("background-color",this.freezeBGColor[a]):e.css("background-color","initial")))},_hasSetBgColor:function(e){return F(e)>0},_isFrozen:function(e){return this.currentlyfreezedContainer.horizontal[e]||this.currentlyfreezedContainer.vertical[e]},_isInScrollVisibleArea:function(e){var t=e.closest(".trv-report-page"),n=e.position();return this._isVisibleVertically(e,t,n)&&this._isVisibleHorizontally(e,t,n)},_isVisibleHorizontally:function(e,t,n){var r=parseFloat(t.css("padding-left")),a=this.$scrollableContainer.scrollLeft(),i=this.$scrollableContainer.width(),o=e.outerWidth(!0)*this.scaleFactor,l=n.left+r;return l>a-o&&l<a+o+i},_isVisibleVertically:function(e,t,n){var r=parseFloat(t.css("padding-top")),a=t.position(),i=this.$scrollableContainer.scrollTop(),o=this.$scrollableContainer.height(),l=e.outerHeight(!0)*this.scaleFactor,s=n.top+r+a.top;return s>i-l&&s<i+l+o}},Be={};function He(e,t,n){var r=(t=$.extend({},Be,t,n)).controller;if(!r)throw"No controller (telerikReportViewer.reportViewerController) has been specified.";var a,i,o,l,s,c,p,g,v,h=$(e),m=h.find(".trv-page-container"),E=m[0],b=h.find(".trv-page-wrapper"),T=b[0],P=h.find(".trv-error-message"),I=r.getScaleMode(),_=r.getScale(),C=.1,S=8,w=!0,R=!1,A=!1,D='.trv-page-container {background: #ffffff url("{0}") no-repeat center 50px}',y="trv-initial-image-styles",k=N({},Ge,{}),x=null;function L(){G(s),s=!1}function O(){return-1!==[ge.FIT_PAGE,ge.FIT_PAGE_WIDTH].indexOf(I)}function V(){for(var e=0,t=m.find(".trv-report-page"),n=t.length;e<n;e++){var a=parseInt($(t[e]).attr("data-page"));Z(t[e],I,_,a)}r.updatePageDimensionsReady()}function U({scale:e,scaleMode:t}){_=e||_,I=t||I,_=Math.max(C,Math.min(S,_)),V()}function G(e){m.off("click","[data-reporting-action]",Q),m.off("mouseenter","[data-reporting-action]",te),m.off("mouseleave","[data-reporting-action]",ne),m.off("mouseenter","[data-tooltip-title],[data-tooltip-text]",ae),m.off("mouseleave","[data-tooltip-title],[data-tooltip-text]",oe),i=void 0,e&&b.empty(),q()}function F(e){var t,n=m.find(".trv-report-page");return r.getPageMode()===pe.SINGLE_PAGE?M(n,(function(n,r){return J(r)===e&&(t=r),!t})):$.each(n,(function(n,r){if(parseInt($(r).attr("data-page"))===e)return t=r,!1})),t}function B(e,t){w?function(e,t){var n=F(e);n?(t&&H(t,e),k.isEnabled()&&!t&&k.navigateToElement(n.offsetTop,e)):(i=t,function(e){W(!0),window.setTimeout(r.getReportPage.bind(r,e),1),o=null}(e))}(e,t):function(e,t){o=e,l=t}(e,t)}function H(e,n){if(e){var r=m.find("[data-"+e.type+"-id="+e.id+"]")[0];if(r){if(t.enableAccessibility){var a=z($(r));a&&a.focus()}for(var i=m[0],o=0,l=0;r&&r!==i;){if($(r).is(".trv-page-wrapper")){var s=$(r).data("pageScale");"number"==typeof s&&(o*=s,l*=s)}o+=r.offsetTop,l+=r.offsetLeft,r=r.offsetParent}k.isEnabled()&&n?k.navigateToElement(o,n):(i.scrollTop=o,i.scrollLeft=l)}else k.isEnabled()&&n&&k.navigateToElement(h.find('[data-page="'+n+'"]')[0].offsetTop,n)}}function z(e){if(!e||0===e.length)return null;var t=f(e.attr("tabindex"));return!isNaN(t)&&t>-1?e:z(e.next())}function W(e){(e?$.fn.addClass:$.fn.removeClass).call(h,"trv-loading")}function q(e){P.text(e),(e?$.fn.addClass:$.fn.removeClass).call(h,"trv-error")}function J(e,t){var n=e.$?e:$(e),r="pageNumber";return void 0===t?n.data(r):(n.data(r,t),e)}function Z(e,t,n,r){var a=$(e),i=r?a:a.find("div.trv-report-page"),o=i.find("div.sheet"),l=i.find("div.trv-skeleton-wrapper"),s=o[0]||l[0],c=l[0];if(s){var u,d,f=a.data("box");if(!f){var p=K(a),g=Y(i),v=j(i);f={padLeft:p.left+g.left+v.left,padRight:p.right+g.right+v.right,padTop:p.top+g.top+v.top,padBottom:p.bottom+g.bottom+v.bottom},a.data("box",f)}void 0===a.data("pageWidth")?(u=s.offsetWidth,d=s.offsetHeight,a.data("pageWidth",u),a.data("pageHeight",d)):(u=a.data("pageWidth"),d=a.data("pageHeight"));var h=d>u&&t===ge.FIT_PAGE_WIDTH?20:0,m=(E.clientWidth-h-f.padLeft-f.padRight)/u,b=(E.clientHeight-1-f.padTop-f.padBottom)/d;t===ge.FIT_PAGE_WIDTH?n=m:n&&t!==ge.FIT_PAGE||(n=Math.min(m,b)),x&&x.setScaleFactor(n),a.data("pageScale",n),i.data("pageScale",n),c||X(o,n,n),i.css({height:n*d,width:n*u})}}function Q(e){var t=re($(this).attr("data-reporting-action"));t&&(o=function(e,t){if(k.isEnabled()&&("sorting"===t||"toggleVisibility"===t))return $(e.target).closest(".trv-report-page").attr("data-page")||r.getCurrentPageNumber();return r.getCurrentPageNumber()}(e,t.Type),r.executeReportAction({element:e.currentTarget,action:t,cancel:!1})),e.stopPropagation()}function te(e){var t=re($(this).attr("data-reporting-action"));null!==t&&e.currentTarget===this&&r.reportActionEnter({element:e.currentTarget,action:t})}function ne(e){var t=re($(this).attr("data-reporting-action"));null!==t&&e.currentTarget===this&&r.reportActionLeave({element:e.currentTarget,action:t})}function re(e){var t;return a?(M(a,(function(){return this.Id===e&&(t=this),void 0===t})),t):null}function ae(e){var n=$(this),a=n.attr("data-tooltip-title"),i=n.attr("data-tooltip-text");if(a||i){var o={element:e.currentTarget,toolTip:{title:a||"",text:i||""},cancel:!1};if(r.reportToolTipOpening(o),!o.cancel){var l,s,c,u,d=function(e){var n=t.templates["trv-pages-area-kendo-tooltip"],r=$(n),a=r.find(".trv-pages-area-kendo-tooltip-title"),i=r.find(".trv-pages-area-kendo-tooltip-text");return a.html(ie(e.toolTip.title)),i.html(ie(e.toolTip.text)),r.clone().wrap("<p>").parent().html()}(o),f=e.currentTarget.viewportElement,p=function(e,t){var n=e.data("kendoTooltip");if(!n)try{n=e.kendoTooltip({content:t,autohide:!0,callout:!1}).data("kendoTooltip")}catch(e){throw console.error("Instantiation of Kendo Tooltip threw an exception",e),e}return n}(n,d);p.show(n),f&&"svg"===f.nodeName&&(l=p,c=(s=e).pageX,u=s.pageY,l.popup.element.closest("[role=region]").css({left:c+10,top:u+5}))}}}function ie(e){return e=(e=(e=d(e)).replaceAll("\r\n","<br>")).replaceAll("\n","<br>")}function oe(e){var t=$(this).data("kendoTooltip");t&&t.hide()}function le(){$("#"+y).remove()}(p=h).attr("aria-label",ee[p.attr("aria-label")]),k&&k.init(e,t),$(window).on("resize",(function(e,t){O()&&V()})),Ue(h,{swipe:function(e){var t=r.getCurrentPageNumber();g&&"left"===e.direction?t<r.getPageCount()&&r.navigateToPage(t+1):v&&"right"===e.direction&&t>1&&r.navigateToPage(t-1)},pinch:function(e){var t=F(r.getCurrentPageNumber());U({scale:($(t).data("pageScale")||_)*(e.distance/e.lastDistance),scaleMode:ge.SPECIFIC})},doubletap:function(e){t.commands.toggleZoomMode.exec()},touchstart:function(e){var t=T;v=0===t.scrollLeft,g=t.scrollWidth-t.offsetWidth===t.scrollLeft}}),r.pageModeChanged((function(){r.getPageMode()===pe.CONTINUOUS_SCROLL?k.enable():k.disable(),r.refreshReport(!0)})).reportSourceChanged((function(){s=!0,o=null,l=null,w=!1})).beforeLoadParameters((function(e,t){t&&q(ee.loadingReport)})).beforeLoadReport((function(){w=!1,o||(o=1),c&&window.clearTimeout(c),G(),W(!0),q(ee.loadingReport)})).beginLoadReport((function(e,t){var n;w=!0,(n=F(o))&&J(n,-1)})).reportLoadProgress((function(e,t){var n,r;n=o,r=t.pageCount,n&&n<=r&&B(n,l),q(u(ee.loadingReportPagesInProgress,[t.pageCount]))})).reportLoadComplete((function(e,t){var n,a;0===t.pageCount?(L(),q(ee.noPageToDisplay)):(n=o,a=t.pageCount,n&&B(n=Math.min(n,a),l),q(u(ee.loadedReportPagesComplete,[t.pageCount])),c=window.setTimeout(q,2e3),m.on("click","[data-reporting-action]",Q),m.on("mouseenter","[data-reporting-action]",te),m.on("mouseleave","[data-reporting-action]",ne),m.on("mouseenter","[data-tooltip-title],[data-tooltip-text]",ae),m.on("mouseleave","[data-tooltip-title],[data-tooltip-text]",oe)),t.containsFrozenContent&&!x&&(x=N({},Fe,{}),r.getViewMode()===de.INTERACTIVE&&x.init(h))})).navigateToPage((function(e,t,n){B(t,n)})).pageReady((function(e,t){r.getPageMode()===pe.SINGLE_PAGE?(k.isEnabled()&&k.disable(),function(e){a=JSON.parse(e.pageActions),function(e){var t="trv-"+r.clientId()+"-styles";$("#"+t).remove();var n=$("<style id="+t+"></style>");n.append(e.pageStyles),n.appendTo("head")}(e);var t=e.pageNumber,n=$($.parseHTML(e.pageContent)),o=n.find("div.sheet"),l=$('<div class="trv-report-page" data-page="'+t+'"></div>');o.css("margin",0),l.append(o).append($('<div class="trv-page-overlay"></div>'));var s=b.empty().removeData().data("pageNumber",t).append(l);r.setCurrentPageNumber(t),r.getViewMode()===de.INTERACTIVE?(h.removeClass("printpreview"),h.addClass("interactive")):(h.removeClass("interactive"),h.addClass("printpreview"));Z(s,I,_),m.scrollTop(0),m.scrollLeft(0),H(i)}(t)):k.renderPage(t),A||(A=!0),R&&le(),r.getViewMode()===de.INTERACTIVE&&x&&x.init(h),W(!1)})).error((function(e,t){W(!1),L(),q(t)})).showNotification((function(e,t){q(ee[t.stringResources])})).hideNotification((function(e,t){q()})).scaleChanged((function(e,t){U({scale:t,scaleMode:r.getScaleMode()})})).scaleModeChanged((function(e,t){U({scale:r.getScale(),scaleMode:t})})).serverActionStarted((function(){W(!0),q(ee.loadingReport)})).scrollPageReady((function(e,t){!function(e){var t=JSON.parse(e.page.pageActions);a=a?a.concat(t):t;r.getViewMode()===de.INTERACTIVE?(h.removeClass("printpreview"),h.addClass("interactive")):(h.removeClass("interactive"),h.addClass("printpreview"));Z(e.target,I,_,e.page.pageNumber)}(t)})).missingOrInvalidParameters((function(e,n){var r;t.initialPageAreaImageUrl&&!A&&(L(),r=$("<style id="+y+"></style>"),le(),r.append(u(D,[t.initialPageAreaImageUrl])),r.appendTo("head"),R=!0)})).renderingStopped((function(){G(!0),q(ee.renderingCanceled)})),r.setDocumentMapVisible((function(){O()&&setTimeout((function(){V()}))})).setParametersAreaVisible((function(){O()&&setTimeout((function(){V()}))}))}var ze="telerik_ReportViewer_PagesArea";$.fn[ze]=function(e,t){return M(this,(function(){$.data(this,ze)||$.data(this,ze,new He(this,e,t))}))};var We,Ke={MultiSelect:function(e,t){return Boolean(e.availableValues)&&e.multivalue&&(!t||!t.multiSelect||t.multiSelect!==he.COMBO_BOX)},MultiSelectCombo:function(e,t){return Boolean(e.availableValues)&&e.multivalue&&t&&t.multiSelect&&t.multiSelect===he.COMBO_BOX},SingleSelect:function(e,t){return Boolean(e.availableValues)&&!e.multivalue&&(!t||!t.singleSelect||t.singleSelect!==he.COMBO_BOX)},SingleSelectCombo:function(e,t){return Boolean(e.availableValues)&&!e.multivalue&&t&&t.singleSelect&&t.singleSelect===he.COMBO_BOX},MultiValue:function(e){return Boolean(e.multivalue)},DateTime:function(e){return e.type===ve.DATETIME},String:function(e){return e.type===ve.STRING},Number:function(e){switch(e.type){case ve.INTEGER:case ve.FLOAT:return!0;default:return!1}},Boolean:function(e){return e.type===ve.BOOLEAN},Default:function(e){return!0}},je={formatValue:function(e){var t="";return e&&[].concat(e).forEach((function(e){t.length>0&&(t+="\n"),t+=e})),t},parseValues:function(e){return(""+e).split("\n")}};function Ye(e){function t(t){return!!r(t.keyCode)||(n=$(e).val()+String.fromCharCode(t.charCode),/^(\-|\+)?([0-9]*)$/.test(n));var n}function n(e){}return $(e).on("keypress",t).on("paste",n),{dispose:function(){!function(e){$(e).off("keypress",t).off("paste",n)}(e)}}}function Xe(e){function t(t){return!!r(t.keyCode)||(n=$(e).val()+String.fromCharCode(t.charCode),/^(\-|\+)?([0-9]*(\.[0-9]*)?)$/.test(n));var n}function n(e){}return $(e).on("keypress",t).on("paste",n),{dispose:function(){!function(e){$(e).off("keypress",t).off("paste",n)}(e)}}}function qe(e,t,n){(e?$.fn.addClass:$.fn.removeClass).call(n,t)}function Je(e,t){qe(!t,"k-disabled",e)}function Ze(e,t,n,r,a){r||(r="");var i=u("{0}. {1} {2}. {3}",[n,t,ee.ariaLabelParameter,r]);e.attr("aria-label",i),tt(e,a)}var Qe=0;function et(e){if(!We){var t=$("div.trv-parameters-area-content");if(t.length>0){var n=t.attr("tabIndex");n&&(We=f(n))}We&&!isNaN(We)||(We=300)}var r=e.closest(".trv-parameter-value"),a=r.find(".trv-select-all"),i=r.find(".trv-select-none"),o=e.closest(".k-widget").find(".k-input"),l=o&&o.length;a&&a.length&&a.attr("tabindex",We+ ++Qe),i&&i.length&&i.attr("tabindex",We+ ++Qe),l?o.attr("tabindex",We+ ++Qe):e.attr("tabindex",We+ ++Qe)}function tt(e,t){var n=u(" {0}:",[ee.ariaLabelErrorMessage]),r=e.attr("aria-label");if(r){var a=r.indexOf(n);a>-1&&(r=r.substring(0,a)),t&&""!==t?(e.attr("aria-required",!0),e.attr("aria-invalid",!0),r+=n+t):e.removeAttr("aria-invalid"),e.attr("aria-label",r)}}function nt(e){return kendo.version>="2017.3.1018"||e}var rt=[{match:Ke.MultiSelect,createEditor:function(e,t){var n=$(e),r=!0;n.html(t.templates["trv-parameter-editor-available-values-multiselect"]);var a,i,o,l,s=n.find(".trv-list"),c=n.find(".trv-select-all"),d=n.find(".trv-select-none"),f=t.parameterChanged;function p(e){l&&(function(e){M(s.find(".trv-listviewitem"),(function(){var t=$(this),n=e.filter(t).length>0;t.attr("aria-selected",n)}))}(e),function(e){var t=i.availableValues,n=$.map(e,(function(e){return t[$(e).index()].value}));v();var r=!i.autoRefresh&&!i.childParameters;o=window.setTimeout((function(){b(i.value,n)||f(i,n),o=null}),r?0:1e3)}(e))}function v(){o&&window.clearTimeout(o)}function h(){return $(a.element).find(".k-selected")}function E(e){if(r){var t=$(e.target),n=a.select();t.hasClass("k-selected")?n.splice($.inArray(t[0],n),1):n.push(t),a.clearSelection(),a.select(n),a.trigger("change")}}function T(e){p(h())}function P(e){if(r&&32===e.which){var t=a.element.find(".k-focus");t.length>0&&(t.toggleClass("k-selected"),p(h()),e.preventDefault())}}function I(e){!function(e){Array.isArray(e)||(e=[e]);var t=s.find(".trv-listviewitem");M(i.availableValues,(function(n,r){var a,i,o=!1;M(e,(function(e,t){var n=r.value;return t instanceof Date&&(n=g(r.value)),!(o=m(t,n))})),a=$(t[n]),qe(i=o,"k-selected",a),a.attr("aria-selected",i)}))}(e),p(h())}return c.text(ee[c.text()]),c.click((function(e){e.preventDefault(),r&&I(i.availableValues.map((function(e){return e.value})))})),d.text(ee[d.text()]),d.click((function(e){e.preventDefault(),r&&I([])})),{beginEdit:function(e){l=!1,a&&(a.element.off("touch click",".trv-listviewitem",E),a.element.off("keydown",P)),i=e;try{a=s.kendoListView({template:kendo.template('<div class="trv-listviewitem" style="cursor: pointer">${name}</div>'),dataSource:{data:i.availableValues},selectable:"MULTIPLE",navigatable:nt(t.enableAccessibility),change:T}).data("kendoListView")}catch(e){throw console.error("Instantiation of Kendo ListView as MultiSelect parameter editor threw an exception",e),e}et(s),I(i.value),a.element.off().on("touch click",".trv-listviewitem",E),a.element.on("keydown",P),l=!0},enable:function(e){Je(s,r=e)},clearPendingChange:v,addAccessibility:function(e){var t=u(ee.ariaLabelParameterInfo,[e.availableValues.length]);Ze(s,ee.ariaLabelMultiSelect,e.text,t,e.Error),s.attr("aria-multiselectable","true"),M(s.find(".trv-listviewitem"),(function(){$(this).attr("aria-label",this.innerText)}))},setAccessibilityErrorState:function(e){tt(s,e.Error)},destroy:function(){a.destroy()}}}},{match:Ke.MultiSelectCombo,createEditor:function(e,t){var n,r,a,i,o,l,s=$(e),c=!0,d=t.parameterChanged,f=!0;function p(e){!function(e){g();var t=!l.autoRefresh&&!l.childParameters;o=window.setTimeout((function(){b(l.value,e)||d(l,e),o=null}),t?0:1e3)}(e)}function g(){o&&window.clearTimeout(o)}function v(){f&&p(i.value())}return s.html(t.templates["trv-parameter-editor-available-values-multiselect-combo"]),n=s.find(".trv-combo"),(r=s.find(".trv-select-none"))&&(r.text(ee[r.text()]),r.click((function(e){e.preventDefault(),i.value([]),i.trigger("change")}))),(a=s.find(".trv-select-all"))&&(a.text(ee[a.text()]),a.click((function(e){if(e.preventDefault(),c){var t=$.map(l.availableValues,(function(e){return e.value}));i.value(t),i.trigger("change")}}))),{beginEdit:function(e){i&&i.unbind("change",v),l=e;try{i=n.kendoMultiSelect({itemTemplate:'<div class="trv-editoritem">${name}</div>',dataSource:l.availableValues,dataTextField:"name",dataValueField:"value",value:l.value,filter:"contains",autoClose:!1,open:function(){f=!1},close:function(e){f=!0,v()},autoWidth:!0,clearButton:!1}).data("kendoMultiSelect")}catch(e){throw console.error("Instantiation of Kendo MultiSelect as MultiSelectCombo parameter editor threw an exception",e),e}et(n),i.bind("change",v)},enable:function(e){c=e,i.enable(e)},clearPendingChange:g,addAccessibility:function(e){var t=i.input,n=u(ee.ariaLabelParameterInfo,[e.availableValues.length]);Ze(t,ee.ariaLabelMultiSelect,e.text,n,e.Error),M(i.items(),(function(){$(this).attr("aria-label",this.innerText)}))},setAccessibilityErrorState:function(e){tt(n,e.Error)},destroy:function(){i.destroy()}}}},{match:Ke.SingleSelect,createEditor:function(e,t){var n=$(e),r=!0;n.html(t.templates["trv-parameter-editor-available-values"]);var a,i,o=n.find(".trv-list"),l=n.find(".trv-select-none"),s=t.parameterChanged;function c(e){!function(e){var t=i.availableValues,n=$.map(e,(function(e){return t[$(e).index()].value}));Array.isArray(n)&&(n=n[0]);s(i,n)}(e)}function d(){c(a.select())}function f(){var e,t;et(o),e=i.value,t=o.find(".trv-listviewitem"),M(i.availableValues,(function(n,r){var i=r.value;return e instanceof Date&&(i=g(r.value)),!m(e,i)||(a.select(t[n]),!1)})),a.bind("change",d)}return l&&(l.text(ee[l.text()]),l.click((function(e){e.preventDefault(),a.clearSelection(),a.trigger("change")}))),{beginEdit:function(e){a&&a.unbind("change",d),i=e;try{a=o.kendoListView({template:'<div class="trv-listviewitem">${name}</div>',dataSource:{data:i.availableValues},selectable:!0,navigatable:nt(t.enableAccessibility)}).data("kendoListView")}catch(e){throw console.error("Instantiation of Kendo ListView as SingleSelect parameter editor threw an exception",e),e}f()},enable:function(e){Je(o,r=e),r?(a.bind("change",d),o.addClass("k-selectable")):(a.unbind("change",d),o.removeClass("k-selectable"))},addAccessibility:function(e){var t=u(ee.ariaLabelParameterInfo,[e.availableValues.length]);Ze(o,ee.ariaLabelSingleValue,e.text,t,e.Error),M(o.find(".trv-listviewitem"),(function(){$(this).attr("aria-label",this.innerText)}))},setAccessibilityErrorState:function(e){tt(o,e.Error)},destroy:function(){a.destroy()}}}},{match:Ke.SingleSelectCombo,createEditor:function(e,t){var n,r,a,i,o=$(e),l=t.parameterChanged;function s(e,t){!function(e,t){var n=t||"";!t&&e>=0&&(n=i.availableValues[e].value);l(i,n)}(e,t)}function c(e){s(a.select(),this.value())}return o.html(t.templates["trv-parameter-editor-available-values-combo"]),n=o.find(".trv-combo"),(r=o.find(".trv-select-none"))&&(r.text(ee[r.text()]),r.click((function(e){e.preventDefault(),a.value(""),a.trigger("change")}))),{beginEdit:function(e){a&&a.unbind("change",c),i=e;try{a=n.kendoComboBox({template:'<div class="trv-editoritem">${name}</div>',dataSource:i.availableValues,dataTextField:"name",dataValueField:"value",value:i.value,filter:"contains",suggest:!0,clearButton:!1}).data("kendoComboBox")}catch(e){throw console.error("Instantiation of Kendo ComboBox as SingleSelectCombo parameter editor threw an exception",e),e}et(n),a.bind("change",c)},enable:function(e){a.enable(e)},addAccessibility:function(e){var t=a.input,n=u(ee.ariaLabelParameterInfo,[e.availableValues.length]);Ze(t,ee.ariaLabelSingleValue,e.text,n,e.Error),M(a.items(),(function(){$(this).attr("aria-label",this.innerText)}))},setAccessibilityErrorState:function(e){tt(n,e.Error)},destroy:function(){a.destroy()}}}},{match:Ke.MultiValue,createEditor:function(e,t){var n,r=$(e);r.html(t.templates["trv-parameter-editor-multivalue"]);var a=r.find("textarea").on("change",(function(){t.parameterChanged&&t.parameterChanged(n,je.parseValues(this.value))}));return{beginEdit:function(e){var t;n=e,t=e.value,n.value=t,a.val(je.formatValue(t)),et(a)},enable:function(e){Je(a,e),a.prop("disabled",!e)},addAccessibility:function(e){Ze(a,ee.ariaLabelMultiValue,e.text,null,e.Error)},setAccessibilityErrorState:function(e){tt(a,e.Error)}}}},{match:Ke.DateTime,createEditor:function(e,t){var n,r=$(e);r.html(t.templates["trv-parameter-editor-datetime"]);try{var a=r.find("input[type=datetime]").kendoDatePicker({change:function(){var e=t.parameterChanged;if(e){var r=this.value();null!==r&&(r=v(r)),e(n,r)}}}),i=a.data("kendoDatePicker")}catch(e){throw console.error("Instantiation of Kendo DatePicker as DateTime parameter editor threw an exception",e),e}return{beginEdit:function(e){n=e,function(e){n.value=e;var t=null;try{e&&(t=h(e))}catch(e){t=null}i.value(t)}(e.value),et(a)},enable:function(e){i.enable(e),Je(a,e)},addAccessibility:function(e){Ze(a,ee.ariaLabelParameterDateTime,e.text,null,e.Error),a.attr("aria-live","assertive")},setAccessibilityErrorState:function(e){tt(a,e.Error)},destroy:function(){i.destroy()}}}},{match:Ke.String,createEditor:function(e,t){var n,r=$(e);r.html(t.templates["trv-parameter-editor-text"]);var a=r.find('input[type="text"]').change((function(){t.parameterChanged&&t.parameterChanged(n,a.val())}));return{beginEdit:function(e){var t;n=e,t=e.value,n.value=t,a.val(t),et(a)},enable:function(e){a.prop("disabled",!e),Je(a,e)},addAccessibility:function(e){Ze(a,ee.ariaLabelParameterString,e.text,null,e.Error),a.attr("aria-live","assertive")},setAccessibilityErrorState:function(e){tt(a,e.Error)}}}},{match:Ke.Number,createEditor:function(e,t){var n,r,a=$(e);a.html(t.templates["trv-parameter-editor-number"]);var i=a.find("input[type=number]").on("change",(function(){t.parameterChanged&&t.parameterChanged(n,i.val())}));return{beginEdit:function(e){r&&r.dispose(),n=e,i.val(n.value),r=n.type===ve.INTEGER?Ye(i):Xe(i),et(i)},enable:function(e){i.prop("disabled",!e),Je(i,e)},addAccessibility:function(e){Ze(i,ee.ariaLabelParameterNumerical,e.text,null,e.Error),i.attr("aria-live","assertive")},setAccessibilityErrorState:function(e){tt(i,e.Error)}}}},{match:Ke.Boolean,createEditor:function(e,t){var n,r=$(e);r.html(t.templates["trv-parameter-editor-boolean"]);var a=r.find("input[type=checkbox]").on("change",(function(){t.parameterChanged&&t.parameterChanged(n,this.checked)}));return{beginEdit:function(e){var t;n=e,t=e.value,n.value=t,a[0].checked=!0===t,et(a)},enable:function(e){Je(a,e),a.attr("disabled",!e)},addAccessibility:function(e){Ze(a,ee.ariaLabelParameterBoolean,e.text,null,e.Error),a.attr("aria-live","assertive")},setAccessibilityErrorState:function(e){tt(a,e.Error)}}}},{match:Ke.Default,createEditor:function(e,t){var n=$(e);return n.html('<div class="trv-parameter-editor-generic"></div>'),{beginEdit:function(e){n.find(".trv-parameter-editor-generic").text(e.Error?"(error)":e.value)},enable:function(e){}}}}];function at(e,t){var n,r=!!e.querySelectorAll&&e.querySelectorAll(".trv-menu-small")[0],a={small:{documentMapVisible:!1,parametersAreaVisible:!1,onDocumentMapVisibleChanged:function(e,n){n.visible&&t.setParametersAreaVisible({visible:!1})},onParameterAreaVisibleChanged:function(e,n){n.visible&&t.setDocumentMapVisible({visible:!1})},onBeforeLoadReport:function(){t.setParametersAreaVisible({visible:!1}),t.setDocumentMapVisible({visible:!1})},onNavigateToPage:function(){t.setParametersAreaVisible({visible:!1}),t.setDocumentMapVisible({visible:!1})}},large:{documentMapVisible:!0,parametersAreaVisible:!0}};function i(e){var t,r=g();if(r!==n){var i=a[n],o=a[r];n=r,e&&e.call(void 0,i,o),h((t=o).documentMapVisible),m(t.parametersAreaVisible)}}function o(e,t){p("onDocumentMapVisibleChanged",arguments)}function l(e,t){p("onParameterAreaVisibleChanged",arguments)}function s(){p("onBeforeLoadReport",arguments)}function c(){p("onNavigateToPage",arguments)}function u(){p("onReportLoadComplete",arguments)}function d(){i((function(e,t){v(e)}))}function f(){i(null)}function p(e,t){var r=a[n],i=r[e];"function"==typeof i&&i.apply(r,t)}function g(){var e=$(window).width()/parseFloat($("body").css("font-size"));return r&&e<=40.5?"small":"large"}function v(e){e.documentMapVisible=h(),e.parametersAreaVisible=m()}function h(){if(0===arguments.length){var e={};return t.getDocumentMapState(e),e.visible}return t.setDocumentMapVisible({visible:Boolean(arguments[0])}),this}function m(){if(0===arguments.length){var e={};return t.getParametersAreaState(e),e.visible}return t.setParametersAreaVisible({visible:Boolean(arguments[0])}),this}return n=g(),v(a.large),{attach:function(){window.addEventListener("resize",d),t.setDocumentMapVisible(o),t.setParametersAreaVisible(l),t.beforeLoadReport(s),t.navigateToPage(c),t.reportLoadComplete(u),t.cssLoaded(f)},dispose:function(){window.removeEventListener("resize",d)}}}var it="application/json; charset=UTF-8",ot="application/x-www-form-urlencoded; charset=UTF-8",lt="GET",st="POST",ct="DELETE",ut={};function dt(e){var t,n=c((e=N({},ut,e)).serviceUrl||e.baseUrl,"\\/"),r=B;function a(e){if(!e)throw"Invalid clientID"}function i(e,t){return u(e,t=N({},{baseUrl:n},t))}function o(e){return e?{headers:{Authorization:"Bearer "+e}}:{}}function l(){if(!t){var n=e.loginInfo;t=n&&n.url&&(n.username||n.password)?r({url:n.url,type:st,data:{grant_type:"password",username:n.username,password:n.password},dataType:"json",contentType:ot}).then((function(e){return e.access_token})):Promise.resolve()}return t}return{_urlFromTemplate:i,registerClient:function(e){return l().then((function(t){var n=N(o(t),e,{type:st,url:i("{baseUrl}/clients"),dataType:"json",data:JSON.stringify({timeStamp:Date.now()})});return r(n)})).then((function(e){if(e.Message)throw e.Message;return e.clientId}))},unregisterClient:function(e,t){return a(e),l().then((function(n){var a=N(o(n),t,{type:ct,url:i("{baseUrl}/clients/{clientID}",{clientID:e})});return r(a)}))},getParameters:function(e,t,n,s){return a(e),l().then((function(a){var l=N(o(a),s,{type:st,url:i("{baseUrl}/clients/{clientID}/parameters",{clientID:e}),contentType:it,dataType:"json",data:JSON.stringify({report:t,parameterValues:n})});return r(l)}))},createReportInstance:function(e,t,n,s){return a(e),l().then((function(a){var l=N(o(a),s,{type:st,url:i("{baseUrl}/clients/{clientID}/instances",{clientID:e}),contentType:it,dataType:"json",data:JSON.stringify({report:t,parameterValues:n})});return r(l)})).then((function(e){return e.instanceId}))},deleteReportInstance:function(e,t,n){return a(e),l().then((function(a){var l=N(o(a),n,{type:ct,url:i("{baseUrl}/clients/{clientID}/instances/{instanceID}",{clientID:e,instanceID:t})});return r(l)}))},createReportDocument:function(e,t,s,c,u,d,f,p){return a(e),l().then((function(a){(c=c||{}).BasePath=n;var l=N(o(a),p,{type:st,url:i("{baseUrl}/clients/{clientID}/instances/{instanceID}/documents",{clientID:e,instanceID:t}),contentType:it,dataType:"json",data:JSON.stringify({format:s,deviceInfo:c,useCache:u,baseDocumentID:d,actionID:f})});return r(l)})).then((function(e){return e.documentId}))},sendDocument:function(e,t,n,s,c){return a(e),l().then((function(a){var l=N(o(a),c,{type:st,url:i("{baseUrl}/clients/{clientID}/instances/{instanceID}/documents/{documentID}/send",{clientID:e,instanceID:t,documentID:n}),contentType:it,data:JSON.stringify({from:s.from,to:s.to,cc:s.cc,subject:s.subject,body:s.body})});return r(l)}))},deleteReportDocument:function(e,t,n,s){return a(e),l().then((function(a){var l=N(o(a),s,{type:ct,url:i("{baseUrl}/clients/{clientID}/instances/{instanceID}/documents/{documentID}",{clientID:e,instanceID:t,documentID:n})});return r(l)}))},getDocumentInfo:function(e,t,n,s){return a(e),l().then((function(a){var l=N(o(a),s,{type:lt,url:i("{baseUrl}/clients/{clientID}/instances/{instanceID}/documents/{documentID}/info",{clientID:e,instanceID:t,documentID:n}),dataType:"json"});return r(l)}))},getPage:function(e,t,n,s,c){return a(e),l().then((function(a){var l=N(o(a),c,{type:lt,url:i("{baseUrl}/clients/{clientID}/instances/{instanceID}/documents/{documentID}/pages/{pageNumber}",{clientID:e,instanceID:t,documentID:n,pageNumber:s}),dataType:"json"});return r(l)}))},get:function(e){return r({type:lt,url:e})},formatDocumentUrl:function(e,t,n,r){var a=i("{baseUrl}/clients/{clientID}/instances/{instanceID}/documents/{documentID}",{clientID:e,instanceID:t,documentID:n});return r&&(a+="?"+r),a},getDocumentFormats:function(e){return l().then((function(t){var n=N(o(t),e,{type:lt,url:i("{baseUrl}/formats"),dataType:"json"});return r(n)}))},getServiceVersion:function(e){return l().then((function(t){var n=N(o(t),e,{type:lt,url:i("{baseUrl}/version"),dataType:"json"});return r(n)}))},getResource:function(e,t,n,s,c){return a(e),l().then((function(a){var l=N(o(a),c,{type:lt,url:i("{baseUrl}/clients/{clientID}/instances/{instanceID}/documents/{documentID}/resources/{resourceID}",{clientID:e,instanceID:t,documentID:n,resourceID:s}),dataType:(null==c?void 0:c.dataType)||"json"});return r(l)}))},getSearchResults:function(e,t,n,s,c,u,d,f){a(e);var p=i("{baseUrl}/clients/{clientID}/instances/{instanceID}/documents/{documentID}/search",{clientID:e,instanceID:t,documentID:n});return l().then((function(e){var t=N(o(e),f,{type:st,url:p,contentType:it,dataType:"json",data:JSON.stringify({searchToken:s,matchCase:c,matchWholeWord:u,useRegularExpressions:d})});return r(t)}))},setAccessToken:function(e){t=Promise.resolve(e)},login:l,keepClientAlive:function(e,t){return l().then((function(n){var a=N(o(n),t,{type:st,url:i("{baseUrl}/clients/keepAlive/{clientID}",{clientID:e})});return r(a)}))},getClientsSessionTimeoutSeconds:function(e){return l().then((function(t){var n=N(o(t),e,{type:lt,url:i("{baseUrl}/clients/sessionTimeout")});return r(n)})).then((function(e){return e.clientSessionTimeout}))}}}function ft(e){var t={ExportInProgress:1,PrintInProgress:2,RenderInProgress:4};function n(e){return!!(l&e)}function r(e,t){t?l|=e:l&=~e}var a,i=e.controller,o=e.history,l=0,s=e.commands;if(!i)throw"No controller (telerikReporting.ReportViewerController) has been specified.";function c(){a||(a=!0,window.setTimeout((function(){try{e=i.getReportSource(),r=i.getPageCount(),l=i.getCurrentPageNumber(),c=e&&e.report,d=(u=c&&r>0)&&l<r,f=u&&l>1,p=u&&l,P={},i.getDocumentMapState(P),g=P,v=function(){var e={};return i.getParametersAreaState(e),e}(),h=function(){var e={};return i.getSearchDialogState(e),e}(),m=function(){var e={};return i.getSendEmailDialogState(e),e}(),E=n(t.RenderInProgress),b=n(t.PrintInProgress),T=n(t.ExportInProgress),s.goToFirstPage.enabled(f),s.goToPrevPage.enabled(f),s.stopRendering.enabled(c&&E),s.goToLastPage.enabled(d),s.goToNextPage.enabled(d),s.goToPage.enabled(u),s.print.enabled(u&&!E&&!b),s.export.enabled(u&&!E&&!T),s.refresh.enabled(c),s.historyBack.enabled(o&&o.canMoveBack()),s.historyForward.enabled(o&&o.canMoveForward()),s.toggleDocumentMap.enabled(c&&g.enabled).checked(g.enabled&&g.visible),s.toggleParametersArea.enabled(c&&v.enabled).checked(v.enabled&&v.visible),s.togglePrintPreview.enabled(u).checked(i.getViewMode()==de.PRINT_PREVIEW),s.pageMode.enabled(u).checked(i.getPageMode()==pe.CONTINUOUS_SCROLL),s.zoom.enabled(p),s.zoomIn.enabled(p),s.zoomOut.enabled(p),s.toggleZoomMode.enabled(p).checked(i.getScaleMode()==ge.FIT_PAGE||i.getScaleMode()==ge.FIT_PAGE_WIDTH),s.toggleSearchDialog.enabled(u).checked(h.visible),s.toggleSendEmailDialog.enabled(u).checked(m.visible),i.updateUI(null),i.pageNumberChange(l),i.pageCountChange(r)}finally{a=!1}var e,r,l,c,u,d,f,p,g,v,h,m,E,b,T,P}),10))}i.setParametersAreaVisible(c),i.setDocumentMapVisible(c),i.updateUIInternal(c),i.setSearchDialogVisible(c),i.setSendEmailDialogVisible(c),i.scaleModeChanged(c),i.currentPageChanged(c),i.beforeLoadReport((function(){r(t.RenderInProgress,!0),c()})),i.reportLoadProgress(c),i.reportLoadComplete((function(){r(t.RenderInProgress,!1),c()})),i.reportSourceChanged(c),i.viewModeChanged(c),i.pageModeChanged((function(){c()})),i.setUIState((function(e,n){r(t[n.operationName],n.inProgress),c()})),i.error((function(){r(t.ExportInProgress,!1),r(t.PrintInProgress,!1),r(t.RenderInProgress,!1),c()})),i.renderingStopped((function(){r(t.RenderInProgress,!1),c()})),c()}var pt={};function gt(e,t,n){var r=(t=$.extend({},pt,t,n)).controller;if(!r)throw"No controller (telerikReporting.reportViewerController) has been specified.";var a,i,o=$(e),l=!1!==t.documentMapVisible,s=t.enableAccessibility,c=null,u=!1;function d(e){var t=this.dataItem(e.node),n=t.page,a=t.id;r.navigateToPage(n,{type:"bookmark",id:a})}function f(e){s&&window.setTimeout((function(){p(e.node)}),100)}function p(e){M($(e).find("li"),(function(){var e=$(this);e.attr("aria-label",e[0].innerText)}))}function g(){v([])}function v(e){var n,r,i=e&&!$.isEmptyObject(e),l=a.data("kendoTreeView");if(!l)try{a.kendoTreeView({dataTextField:"text",select:d}),l=a.data("kendoTreeView")}catch(e){throw console.error("Instantiation of Kendo TreeView as Document Map threw an exception",e),e}l.setDataSource(e),s&&((r=l).bind("expand",f),r.element.attr("aria-label",ee.ariaLabelDocumentMap),M(r.element.find("ul"),(function(){p(this)})),u&&(n=o.next(),t.documentMapAreaPosition===Ee.RIGHT&&(n=o.prev()),n.attr("aria-label",ee.ariaLabelDocumentMapSplitter))),m(i)}function h(){o.removeClass("trv-loading")}function m(e){var n=re.viewerInstances.find((e=>e.id===t.viewerSelector+"-document-map-splitter")).instance,r=o.next();t.documentMapAreaPosition===Ee.RIGHT&&(r=o.prev()),n&&((u?$.fn.removeClass:$.fn.addClass).call(r,"trv-hidden"),n.toggle(".trv-document-map",e))}(a=$('<div id="'+t.viewerSelector+'-documentMap"></div>')).appendTo(e),r.beginLoadReport((function(){o.addClass("trv-loading");var e,t=r.getReportSource().report,n=c!==t||(e={},r.getDocumentMapState(e),!e.visible);c=t,n&&g()})).reportLoadComplete((function(e,t){t.documentMapAvailable?(u=!0,v(t.documentMapNodes),r.setDocumentMapVisible({enabled:!0,visible:l})):m(u=!1),h()})).error((function(e,t){h(),g()})).renderingStopped((function(){u=!1,m(!1)})),r.setDocumentMapVisible((function(e,t){m((l=t.visible)&&u)})).getDocumentMapState((function(e,t){t.enabled=u,t.visible=l})),(i=o.find(".trv-document-map-overlay"))&&i.attr("aria-label",ee[i.attr("aria-label")])}var vt="telerik_ReportViewer_DocumentMapArea";$.fn[vt]=function(e,t){return M(this,(function(){$.data(this,vt)||$.data(this,vt,new gt(this,e,t))}))};var ht={},mt="pa.parametersReady",Et="pa.Error";function bt(e,t,n){t=$.extend({},ht,t,n);var r={},a=$(r),i={},o=t.controller;if(!o)throw"No controller (telerikReporting.reportViewerController) has been specified.";var l,s,c,u=[].concat(t.parameterEditors,rt),f=void 0,p=$(e),g=p.find(".trv-parameters-area-content"),v=p.find(".trv-error-message"),h=p.find(".trv-parameters-area-preview-button");h.text(ee[h.text()]),h.attr("aria-label",ee[h.attr("aria-label")]),h.on("click",(function(e){e.preventDefault(),w()&&A()}));var m,E=t.templates["trv-parameter"],b=!1!==t.parametersAreaVisible,T=t.enableAccessibility;function P(e,t){e.style.display=t?"none":""}function I(e){var n=$(E),r=n.find(".trv-parameter-value"),a=n.find(".trv-parameter-title"),o=n.find(".trv-parameter-error"),s=n.find(".trv-parameter-error-message"),f=n.find(".trv-parameter-use-default input"),p=t.parameters&&t.parameters.editors?t.parameters.editors:null,g=function(e,t){var n;return M(u,(function(){return this&&this.match(e,t)&&(n=this),!n})),n}(e,p),v=d(e.text),m=!e.isVisible;m&&(v+=" [<b>hidden</b>]"),a.html(v).attr("title",v),s.text(e.Error),(e.Error?$.fn.show:$.fn.hide).call(o);var b=g.createEditor(r,{templates:t.templates,parameterChanged:function(e,t){var n=document.querySelector(".trv-pages-area .trv-error-message ul li."+e.name);try{t=De.validate(e,t),o.hide(),n&&P(n,!0),function(e,t){delete e.Error,e.value=t,l[e.id]=t,void 0!==c?e.id in c&&(l[e.id]=t):l[e.id]=t;if(y(e),e.childParameters)G(N);else{var n=w();if(_(n),n){var r=document.querySelector(".trv-pages-area .trv-error-message");h.is(":visible")&&r&&(r.textContent=ee.tryReportPreview),N()}}}(e,t)}catch(t){n&&P(n,!1),e.Error=t,e.value=[],s.text(t),o.show(),_(!1)}finally{!function(e){var t=i[e.id];if(!t||!T)return;t.setAccessibilityErrorState(e)}(e)}},enableAccessibility:T});(i[e.id]=b,b.beginEdit(e),T&&!m&&b.addAccessibility(e),f.length>0)&&(f.on("click",(function(){var t=$(this).is(":checked");t?(delete l[e.id],delete c[e.id],y(e),G(H)):(l[e.id]=e.value,c[e.id]=e.value),b.enable(!t),D()})),null!==c?e.id in c||(f.prop("checked",!0),b.enable(!1)):m&&(f.prop("checked",!0),b.enable(!1)));return n}function _(e){e?(h.prop("disabled",!1),h.removeClass("k-disabled")):(h.prop("disabled",!0),h.addClass("k-disabled"))}function C(e){v.text(e),(e?$.fn.addClass:$.fn.removeClass).call(p,"trv-error")}function S(){var e;(e=!0,M(s,(function(){return e=!this.isVisible||this.autoRefresh})),e?$.fn.removeClass:$.fn.addClass).call(p,"preview")}function w(){var e=!0;return M(s,(function(){return e=!this.Error})),e}function R(e){var n;l={},f={},s=e||[],M(i,(function(){this.hasOwnProperty("destroy")&&this.destroy()})),i={};var r=$("<div></div>");M(s,(function(){try{this.value=De.validate(this,this.value)}catch(e){this.Error=this.Error||e}!Boolean(this.Error)?(l[this.id]=this.value,this.availableValues?f[this.id]={valueMember:this.value,displayMember:this.label,availableValues:this.availableValues,multivalue:this.multivalue}:f[this.id]=this.value):this.Error=ee.invalidParameter,(this.isVisible||t.showHiddenParameters)&&(n=I(this))&&r.append(n)})),void 0!==c&&(null===c?(c={},M(s,(function(){this.isVisible?c[this.id]=this.value:delete l[this.id]}))):M(s,(function(){this.id in c||delete l[this.id]}))),g.empty(),s.length>0&&(g.append(r.children()),T&&g.attr("aria-label","Parameters area. Contains "+s.length+" parameters.")),S(),_(w()),o.setProcessedParameter($.extend({},f))}function A(){o.setParameters($.extend({},l)),o.previewReport(!1)}function D(){r.parametersReady(l)}function N(){D(),function(){for(var e=!0,t=s.length-1;e&&t>=0;t--){var n=s[t];e=n.id in l&&(Boolean(n.autoRefresh)||!n.isVisible)}return e}()&&A()}function y(e){e.childParameters&&M(e.childParameters,(function(e,t){var n=function(e){if(s)for(var t=0;t<s.length;t++){var n=s[t];if(n.id===e)return n}return null}(t);n&&y(n),delete l[t],function(e){if(i){var t=i[e];t&&"function"==typeof t.clearPendingChange&&t.clearPendingChange()}}(t)}))}function k(e){if(!e||null===e)return!1;var t=!1;return M(e,(function(){return!(t=this.isVisible)})),t}(m=p.find(".trv-parameters-area-preview-button"))&&(m.attr("aria-label",ee[m.attr("aria-label")]),m.text(ee[m.text()]));var x=0;function L(){x++,p.addClass("trv-loading")}function O(){x>0&&0==--x&&p.removeClass("trv-loading")}var V=!1;function U(e,n){(V=k(e))||z(!1),R(e),C(""),V&&b&&(z(!0),T&&function(){var e=p.prev(),n=p.find(".trv-parameters-area-content").attr("tabIndex");t.parametersAreaPosition!==me.TOP&&t.parametersAreaPosition!==me.LEFT||(e=p.next());e.attr("aria-label",ee.ariaLabelParametersAreaSplitter),e.attr("tabIndex",n)}()),o.updateUIInternal(),"function"==typeof n&&n(),O()}function G(e){F(o.loadParameters(l),e)}function F(e,t){L(),e.then((function(e){U(e,t)})).catch((function(e){O(),W(),p.hasClass("trv-hidden")||C(e),r.error(e)}))}function B(e,t){var n=function(e){var t;return e&&e.length&&(t=e[0]),"function"==typeof t?t:null}(t);return n?a.on(e,n):a.trigger(e,t),o}function H(){null===c&&(c=$.extend({},l)),D()}function z(e){var n=re.viewerInstances.find((e=>e.id===t.viewerSelector+"-parameters-splitter")).instance,r=p.prev();t.parametersAreaPosition!==me.TOP&&t.parametersAreaPosition!==me.LEFT||(r=p.next()),n&&((V?$.fn.removeClass:$.fn.addClass).call(r,"trv-hidden"),n.toggle(".trv-parameters-area",e))}function W(){R([])}return o.reloadParameters((function(e,t){C(),g.empty(),F(t,H)})).beforeLoadReport((function(){x=0,L()})).error(O).pageReady(O),o.getParametersAreaState((function(e,t){var n=!1;s&&(n=k(s)),t.enabled=n,t.visible=b})).setParametersAreaVisible((function(e,t){b=t.visible,z(t.visible&&k(s))})),$.extend(r,{allParametersValid:function(){return w()},clear:function(){W()},error:function(){return B(Et,arguments)},parametersReady:function(){return B(mt,arguments)},setParameters:function(e){c=null===e?null:$.extend({},e)}}),r}var Tt,Pt,It="telerik_ReportViewer_ParametersArea";function _t(e,t,n){var r,a=$.extend({},t,n),i=$(e).data("kendoMenu"),o=e.childNodes,l=a.controller,s=a.enableAccessibility;if(!l)throw"No controller (telerikReporting.ReportViewerController) has been specified.";function c(t){M($(e).find("ul[data-command-list=export-format-list]"),(function(){var e=$(this),n=e.parents("li"),r=s?n.attr("tabindex"):-1;r||(r=1),e.empty(),M(t,(function(){var e="<li "+(s?u('aria-label="{localizedName}" ',this):" ")+u('tabindex="'+r+'"><a tabindex="-1" href="#" data-command="telerik_ReportViewer_export" data-command-parameter="{name}"><span>{localizedName}</span></a></li>',this);i.append(e,n)})),s&&M(n.find("li"),(function(){var e=$(this);e.off("keydown"),e.on("keydown",(function(t){switch(t.which){case kendo.keys.ENTER:d(e);break;case kendo.keys.UP:var n=e.prev();n.length>0?n.focus():e.parents("li").focus();break;case kendo.keys.DOWN:var r=e.next();r.length>0?r.focus():e.parent().children("li").first().focus()}}))}))}))}function d(e){if(m(e))n="#trv-main-menu-export-command",$("[data-role='telerik_ReportViewer_MainMenu']").data("kendoMenu").open(n);else if(e&&e.length>0){var t=e.children("a");t.length>0&&t.click()}var n}function p(e){var t,n=$(e.item);t=n,Tt&&Tt.is(t)&&window.setTimeout((function(){var e=t.find("li");e.length>0&&e[0].focus()}),100)}function g(e){Pt=void 0}function v(e){switch(e.which){case kendo.keys.ENTER:if(!s){var t=h();t.length>0&&(m(t)&&Pt&&(t=Pt),d(t))}break;case kendo.keys.RIGHT:s?function(){var e=h();if(!e||!e.length>0)return;var t=e.next();"none"==t.css("display")&&(t=t.next());!t.length>0&&(t=$(o).filter("li.k-item").first());t.focus()}():function(){var e=i.element.children("li.k-item"),t=e.filter(".k-focus");if(kendo.version>="2017.3.913")return void(r=t);if(t.hasClass("k-disabled"))if(!r||t.is(r)){var n=t.next();!n.length>0&&(n=e.first()),t.toggleClass("k-focus"),n.toggleClass("k-focus"),r=n,i._oldHoverItem=n}else r=t;else i._oldHoverItem=t,r=t}();break;case kendo.keys.LEFT:s?function(){var e=h();if(!e||!e.length>0)return;var t=e.prev();"none"==t.css("display")&&(t=t.prev());!t.length>0&&(t=$(o).filter("li.k-item").last());t.focus()}():(n=i.element.children("li.k-item.k-focus"),r=n);break;case kendo.keys.DOWN:case kendo.keys.UP:s||(Pt=function(){var e=i.element.find('li.k-item.k-focus [data-command="telerik_ReportViewer_export"]');if(1===e.length)return e.parent("li");return}())}var n}function h(){var e,t=document.activeElement;if(t&&"li"==t.localName)for(var n=$(o).filter("li.k-item"),r=0;r<n.length;r++){var a=n[r];if(t===a){e=$(a);break}}else t&&"input"==t.localName?e=$(t).closest("li.k-item"):0===(e=i.element.children("li.k-item.k-focus")).length&&(e=i.element.children("li.k-item").first());return e}function m(e){if(0!==e.length){var t=e.attr("id");return"trv-main-menu-export-command"==t||"trv-side-menu-export-command"==t}}i||function(){try{i=$(e).kendoMenu().data("kendoMenu")}catch(e){throw console.error("Instantiation of Kendo Menu as Main Menu threw an exception",e),e}i.bind("activate",p),i.bind("deactivate",g),i.element.off("keydown",v),i.element.on("keydown",v),a.enableAccessibility&&M($.find('[data-role="telerik_ReportViewer_MainMenu"]'),(function(){var e=$(this),t=e.find("li"),n=0,r=e.attr("tabIndex");r&&((n=f(r))&&!isNaN(n)||(n=0)),function(e,t){M(e,(function(){var e=$(this);e.attr("tabindex",t),e.focus((function(){e.addClass("k-focus")})),e.blur((function(){e.removeClass("k-focus")}));var n=e.children("a");if(n.length>0){var r=$(n);r.attr("tabindex",-1),e.attr("title",r.attr("title"))}e.off("keydown"),e.on("keydown",(function(t){t.which==kendo.keys.ENTER&&(d(e),Tt=e)}))}))}(t,n);var a=t.find('input[data-role="telerik_ReportViewer_PageNumberInput"]');a.length>0&&a.attr("tabindex",n)}));!function(){var e=V("ul[data-role=telerik_ReportViewer_MainMenu]");if(!e)return;M(e,(function(){var e=$(this),t=e.children("li.k-item");e.attr("aria-label",ee[e.attr("aria-label")]),M(t,(function(){var e=$(this);if(e.attr("aria-label",ee[e.attr("aria-label")]),e.hasClass("trv-report-pager"))e.attr("title",ee[e.attr("title")]);else{var t=e.find("a");t&&t.attr("title",ee[t.attr("title")])}}))}))}()}(),l.reportLoadComplete((function(e,t){s||i&&i._oldHoverItem&&i._oldHoverItem.toggleClass("k-focus"),t.renderingExtensions?c(t.renderingExtensions):l.getDocumentFormats().then(c)}))}$.fn[It]=function(e,t){return M(this,(function(){$.data(this,It)||$.data(this,It,new bt(this,e,t))}))};var Ct="telerik_ReportViewer_MainMenu";$.fn[Ct]=function(e,t){return M(this,(function(){$.data(this,Ct)||$.data(this,Ct,new _t(this,e,t))}))};var St={};function wt(e,t,n){var r,a,i,o,l,s,c,d,f,p,g,v,h,m,E,b,T,P,I,_,C,S=(t=$.extend({},St,t)).controller,w=!1,R=!1,A=[],D=$("[data-selector='"+n.viewerSelector+"']").find(".trv-report-viewer"),N="",y={shadedClassName:"trv-search-dialog-shaded-result",highlightedClassName:"trv-search-dialog-highlighted-result",current:null,elements:[]};if(!S)throw"No controller (telerikReporting.ReportViewerController) has been specified.";function k(){P||(x(!1),I=!1)}function x(t){R=t,t?(I=!0,function(){if(!w){r=$(e),a=r.find(".trv-search-dialog-input-box"),f=r.find(".trv-search-dialog-results-label"),p=r.find(".trv-search-dialog-results-area"),function(){try{p.kendoListView({selectable:!0,navigatable:!0,dataSource:{},contentElement:"",template:"<div class='trv-search-dialog-results-row'><span>#: description #</span> <span class='trv-search-dialog-results-pageSpan'>"+ee.searchDialogPageText+" #:page#</span></div>",change:function(){var e=this.select().index(),t=this.dataSource.view();!function(e){if(!e)return;y.current&&(y.current.removeClass(y.highlightedClassName),y.current.addClass(y.shadedClassName));e.page===S.getCurrentPageNumber()?Y(e):S.getPageMode()!==pe.CONTINUOUS_SCROLL?q():Y(e);_=e,S.navigateToPage(e.page,{type:"search",id:e.id})}(t[e]),X(e,t.length)}})}catch(e){throw console.error("Instantiation of Kendo ListView as search result area threw an exception",e),e}}(),function(e){if(!e)return;var t=e.find(".trv-search-dialog-caption-label"),n=e.find(".trv-search-dialog-search-options"),r=e.find("a[data-command='telerik_ReportViewer_searchDialog_StopSearch']"),a=e.find("a[data-command='telerik_ReportViewer_searchDialog_MatchCase']"),i=e.find("a[data-command='telerik_ReportViewer_searchDialog_MatchWholeWord']"),o=e.find("a[data-command='telerik_ReportViewer_searchDialog_UseRegex']"),l=e.find("a[data-command='telerik_ReportViewer_searchDialog_NavigateUp']"),s=e.find("a[data-command='telerik_ReportViewer_searchDialog_NavigateDown']");te(e,"aria-label"),te(n,"aria-label"),c=t,c&&c.text(ee[c.text()]),Q(r),Q(a),Q(i),Q(o),Q(l),Q(s);var c}(r);try{i=r.find(".trv-search-dialog-search-options").kendoMenu(),l=r.find(".trv-search-dialog-stopsearch-placeholder").kendoMenu(),c=r.find(".trv-search-dialog-navigational-buttons").kendoMenu()}catch(e){throw console.error("Instantiation of Kendo Menu for Search Dialog threw an exception",e),e}o=i.data("kendoMenu"),s=l.data("kendoMenu"),d=c.data("kendoMenu"),o.element.on("keydown",L),s.element.on("keydown",L),d.element.on("keydown",L),function(e){for(var t=$(e).find(".k-menu-item"),n=0;n<t.length;n++)$(t[n]).removeClass("k-item")}(".trv-search-dialog-search-options");try{g=a.kendoComboBox({dataTextField:"value",dataValueField:"value",dataSource:A,contentElement:"",change:z,ignoreCase:!1,filtering:H,filter:"startswith",delay:1e3,open:function(e){T&&e.preventDefault()},select:U}).data("kendoComboBox")}catch(e){throw console.error("Instantiation of Kendo ComboBox as search input threw an exception",e),e}try{v=D.find(".trv-search-window").kendoWindow({title:ee.searchDialogTitle,height:390,width:310,minWidth:310,minHeight:390,maxHeight:700,scrollable:!1,close:function(){O(),N=""},open:function(){V()},deactivate:function(){S.setSearchDialogVisible({visible:!1})},activate:function(){g.input.focus()}}).data("kendoWindow")}catch(e){throw console.error("Instantiation of Kendo Window for Search dialog threw an exception",e),e}v.wrapper.addClass("trv-search"),m={searchDialog_MatchCase:new ne((function(){G(this)})),searchDialog_MatchWholeWord:new ne((function(){G(this)})),searchDialog_UseRegex:new ne((function(){G(this)}))},ae.bind(i,{controller:S,commands:m},n),h=new ne((function(){F(!1)})),ae.bind(l,{controller:S,commands:{searchDialog_StopSearch:h}},n),E={searchDialog_NavigateUp:new ne((function(){J(-1)})),searchDialog_NavigateDown:new ne((function(){J(1)}))},ae.bind(c,{controller:S,commands:E},n),w=!0}}(),v.open(),g.value(""),K(null),Z(!1,null)):(q(),v&&v.options.visible&&v.close())}function L(e){var t=$(e.target).find(".k-focus");if(13===e.keyCode&&t&&t.length>0){var n=t.children("a");n.length>0&&n.click()}}function O(){var e=v.element.parent(".k-window");C=e.offset()}function V(){var e=$(window).innerWidth(),t=$(window).innerHeight(),n=v.wrapper,r=n.outerWidth(!0),a=n.outerHeight(!0),i=10;if(C){var o=C.left,l=C.top,s=l+a;o+r>e-i&&(o=Math.max(i,e-r-i),n.css({left:o}),v.setOptions({position:{left:o}})),s>t-i&&(l=Math.max(i,t-a-i),n.css({top:l}),v.setOptions({position:{top:l}}))}else{var c=D[0].getBoundingClientRect();n.css({top:c.top+i,left:c.right-r-i}),v.setOptions({position:{top:c.top+i,left:c.right-r-i}})}}function U(e){if(window.event||window.event.type){var t=window.event;"keydown"===t.type&&(e.preventDefault(),40===t.keyCode?J(1):38===t.keyCode&&J(-1))}}function G(e){e.checked(!e.checked()),g&&W(g.value())}function F(e){h.enabled(e)}function B(e,t){R&&j(b)}function H(e){e.preventDefault(),e.filter&&e.filter.value!==N&&W(N=e.filter.value)}function z(e){var t=e.sender.value();t&&N!==t&&W(N=t)}function W(e){f.text(ee.searchDialogSearchInProgress),q(),b=null,F(!0),Z(!1,null),function(e){if(!e||""===e)return;var t=A.filter((function(t){return t.value===e}));if(t&&t.length>0)return;A.unshift({value:e}),A.length>10&&A.pop();T=!0,g.dataSource.data(A),g.select((function(t){return t.value===e})),T=!1}(e),S.getSearchResults({searchToken:e,matchCase:m.searchDialog_MatchCase.checked(),matchWholeWord:m.searchDialog_MatchWholeWord.checked(),useRegex:m.searchDialog_UseRegex.checked()}).then((function(e){K(e,null)})).catch((function(e){e&&K(null,e)}))}function K(e,t){var n,r;F(!1),t&&Z(!0,t),function(e){var t=p.data("kendoListView");e||(e=[]);t.dataSource.data(e)}(e),b=e,e&&e.length>0?(j(e),n=p.data("kendoListView"),r=n.element.children().first(),n.select(r),n.trigger("change")):X(-1,0)}function j(e){if(e&&0!==e.length){var t=r.parent().find(".trv-page-container").find("[data-search-id]");M(e,(function(){var e=t.filter("[data-search-id="+this.id+"]");e&&(e.addClass(y.shadedClassName),y.elements.push(e))})),Y(_),_=null}}function Y(e){if(e){var t=e.id,n=$(y.elements.filter((function(e){return e.attr("data-search-id")===t}))).first();if(n&&(y.current=n[0],y.current)){var r=$("[data-search-id='"+t+"']");r.removeClass(y.shadedClassName),r.addClass(y.highlightedClassName)}}}function X(e,t){var n=0===t?ee.searchDialogNoResultsLabel:u(ee.searchDialogResultsFormatLabel,[e+1,t]);f.text(n);var r=e>0,a=e<t-1;E.searchDialog_NavigateUp.enabled(r),E.searchDialog_NavigateDown.enabled(a)}function q(){y.elements&&y.elements.length>0&&M(y.elements,(function(){this.removeClass(y.shadedClassName)})),y.current&&y.current.removeClass(y.highlightedClassName),y.elements=[],y.current=null}function J(e){var t=p.data("kendoListView"),n=t.select();if(n){var r=t.select().trigger("change").index(),a=t.dataSource.view(),i=Math.min(a.length-1,Math.max(0,r+e));if(i!==r){var o=a[i],l=t.element.find('[data-uid="'+o.uid+'"]');l&&(t.select(l),t.trigger("change"),function(e,t){if(e.offsetTop-e.clientHeight<t.scrollTop)e.scrollIntoView();else{var n=e.offsetTop+e.offsetHeight;n>t.scrollTop+t.offsetHeight&&(t.scrollTop=n-t.offsetHeight)}}(l[0],t.element[0]))}}else n=t.element.children().first(),t.select(n),t.trigger("change")}function Z(e,t){var n=i.find("i[data-role='telerik_ReportViewer_SearchDialog_Error']");if(n&&0!==n.length){var r=i.data("kendoMenu").element.find("li").last();e?(n[0].title=t,r.show()):r.hide()}else console.log(t)}function Q(e){te(e,"title"),te(e,"aria-label")}function te(e,t){e&&e.attr(t,ee[e.attr(t)])}function ne(e){var t=!0,n=!1,r={enabled:function(e){if(0===arguments.length)return t;var n=Boolean(e);return t=n,$(this).trigger("enabledChanged"),r},checked:function(e){if(0===arguments.length)return n;var t=Boolean(e);return n=t,$(this).trigger("checkedChanged"),r},exec:e};return r}S.pageReady(B).scrollPageReady(B).beginLoadReport(k).viewModeChanged(k),S.setSendEmailDialogVisible((function(e,t){t.visible&&R&&x(!R)})).getSearchDialogState((function(e,t){t.visible=R})).setSearchDialogVisible((function(e,t){!function(e){if(R=e,e){if(n.searchMetadataOnDemand&&!I)return P=!0,S.reportLoadComplete((function(){P&&(x(!0),P=!1)})),void S.refreshReport(!0)}x(e)}(t.visible)})),$(window).resize((function(){v&&v.options.visible&&(O(),V())}))}var Rt="telerik_ReportViewer_SearchDialog";$.fn[Rt]=function(e,t){return M(this,(function(){$.data(this,Rt)||$.data(this,Rt,new wt(this,e,t))}))};var At={};function Dt(e,t,n){var r,a,i,o,l,s,c,u,d,f,p,g,v,h=(t=$.extend({},At,t)).controller,m=!1,E=!1,b=n.viewerSelector,T=$("[data-selector='"+b+"']").find(".trv-report-viewer");if(!h)throw"No controller (telerikReporting.ReportViewerController) has been specified.";n.sendEmail&&n.sendEmail.enabled?(h.beginLoadReport(P).viewModeChanged(P),h.getSendEmailDialogState((function(e,t){t.visible=E})).setSendEmailDialogVisible((function(e,t){I(t.visible)})).setSearchDialogVisible((function(e,t){t.visible&&E&&I(!E)})),h.getDocumentFormats().then((function(e){p=e})),$(window).resize((function(){a&&a.options.visible&&(C(),S(),w())}))):$("[data-selector='"+b+"']").find("a[data-command='telerik_ReportViewer_toggleSendEmailDialog']").closest(".k-item ").hide();function P(){I(!1)}function I(t){E=t,t?(!function(){if(!m){r=$(e),i=r.find("[name='from']"),o=r.find("[name='to']"),l=r.find("[name='cc']"),s=r.find("[name='subject']"),u=r.find("[name='format']"),d=r.find("textarea"),r.find(".trv-send-email-field input").each((function(){var e=$(this),t=e.attr("name");e.attr("id",b+"-"+t)})),r.find(".trv-send-email-label label").each((function(){var e=$(this),t=e.attr("for");e.attr("for",b+"-"+t)})),g={sendEmail_Cancel:new L((function(){k()})),sendEmail_Send:new L((function(e){var t,n,r,a,d;d={from:i.val(),to:o.val(),cc:l.val(),subject:s.val(),format:c.value(),body:_(),deviceInfo:{}},t=A(i)||!M(i,!1),n=A(o)||!M(o,!0),r=l.val().length&&!M(l,!0),(a=c.value().length)||D(u,"data-required-msg"),!(t||n||r)&&a&&(h.sendReport(d),k())}))},ae.bind(r.find(".trv-send-email-actions"),{controller:h,commands:g},n),function(e){if(!e)return;var t=e.find(".trv-replace-string"),n=e.find("[aria-label]"),r=e.find("[title]");t.length&&$.each(t,(function(e,t){var n;(n=$(t))&&n.text(ee[n.text()])}));n.length&&$.each(n,(function(e,t){x($(t),"aria-label")}));r.length&&$.each(r,(function(e,t){x($(t),"title")}))}(r);try{a=T.find(".trv-send-email-window").kendoWindow({title:ee.sendEmailDialogTitle,minWidth:350,minHeight:350,maxHeight:900,modal:!0,close:function(){C(),$(".k-invalid-msg").removeClass("-visible")},open:function(){S(),w()},deactivate:function(){h.setSendEmailDialogVisible({visible:!1})},activate:function(){a.wrapper.find(".trv-send-email-fields input[type='email']:visible").first().focus(),setTimeout((function(){i.off("blur").on("blur",(function(e){A($(this))||M($(this),!1)})),o.off("blur").on("blur",(function(e){A($(this))||M($(this),!0)})),l.off("blur").on("blur",(function(e){$(this).val().length?M($(this),!0):N($(this))}))}),250)}}).data("kendoWindow")}catch(e){throw console.error("Instantiation of Kendo Window for Send Email dialog threw an exception",e),e}a.wrapper.addClass("trv-send-email");try{c=u.kendoComboBox({dataTextField:"localizedName",dataValueField:"name",dataSource:p||[],filter:"startswith",dataBound:function(){this.select(0),this.trigger("change")}}).data("kendoComboBox")}catch(e){throw console.error("Instantiation of Kendo ComboBox as document format selector threw an exception",e),e}r.on("keydown",'[name="format_input"]',(function(e){var t=9;e.keyCode===t&&f&&setTimeout((function(){f.focus()}))}));try{f=d.kendoEditor({tools:["bold","italic","underline","strikethrough","justifyLeft","justifyCenter","justifyRight","justifyFull","insertUnorderedList","insertOrderedList","indent","outdent","createLink","unlink","cleanFormatting","formatting","fontName","fontSize","foreColor","backColor","subscript","superscript"]}).data("kendoEditor")}catch(e){throw console.error("Instantiation of Kendo Editor for Email body editor threw an exception",e),e}R(n.sendEmail),m=!0}}(),R(n.sendEmail),a.open()):a&&a.options.visible&&a.close()}function _(){return f?f.value():""}function C(){var e=a.element.parent(".k-window");v=e.offset()}function S(){var e=a.element.parent(".k-window"),t=350;$(window).width()>800&&(t=720),e.css({width:t}),a.refresh({width:t})}function w(){if(v){var e=10,t=$(window).innerWidth(),n=$(window).innerHeight(),r=a.wrapper,i=r.outerWidth(!0),o=r.outerHeight(!0),l=v.left,s=v.top,c=s+o;l+i>t-e&&(l=Math.max(e,t-i-e),r.css({left:l}),a.setOptions({position:{left:l}})),c>n-e&&(s=Math.max(e,n-o-e),r.css({top:s}),a.setOptions({position:{top:s}}))}else a.center()}function R(e){i.val(e&&e.from||""),o.val(e&&e.to||""),l.val(e&&e.cc||""),s.val(e&&e.subject||""),e&&e.format?c.value(e.format):c.select(0),c.trigger("change"),f.value(e&&e.body||"")}function A(e){return e.val().length?(N(e),!1):(D(e,"data-required-msg"),!0)}function D(e,t){var n=ee[e.attr(t)];$('[data-for="'+e.attr("name")+'"]').addClass("-visible").text(n)}function N(e){$('[data-for="'+e.attr("name")+'"]').removeClass("-visible")}function M(e,t){var n=e.val();if(t){for(var r=n.split(/[\s,;]+/),a=0;a<r.length;a++)if(!y(r[a].trim(),e))return!1;return!0}return y(n,e)}function y(e,t){return e.indexOf(",")>-1||e.indexOf(";")>-1?(D(t,"data-single-email-msg"),!1):!!/\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*/.test(e)||(D(t,"data-email-msg"),!1)}function k(){a.close()}function x(e,t){e&&e.attr(t,ee[e.attr(t)])}function L(e){var t=!0,n=!1,r={enabled:function(e){if(0===arguments.length)return t;var n=Boolean(e);return t=n,$(this).trigger("enabledChanged"),r},checked:function(e){if(0===arguments.length)return n;var t=Boolean(e);return n=t,$(this).trigger("checkedChanged"),r},exec:e};return r}}var Nt="telerik_ReportViewer_SendEmail";function Mt(e,t,n){var r,a=$.extend({},t,n),i=$(e).data("kendoMenu"),o=a.enableAccessibility,l=3,s=!1,c=a.controller;if(!c)throw"No controller (telerikReporting.ReportViewerController) has been specified.";function d(e){var t=$(e.item);r.unbind("expand",d),r.append({text:ee.loadingFormats,spriteCssClass:"k-icon k-loading"},t),a.controller.getDocumentFormats().then(f).then((function(){r.expand(t)})).then((function(){r.bind("expand",d)}))}function f(t){M($(e).find("ul[data-command-list=export-format-list]"),(function(){var e=$(this),n=e.parents("li"),a=n.attr("tabindex");a||(a=l),e.empty(),M(t,(function(e){var t="<li "+(o?u('aria-label="{localizedName}" ',this):" ")+u('tabindex="'+a+'"><a tabindex="-1" href="#" data-command="telerik_ReportViewer_export" data-command-parameter="{name}"><span>{localizedName}</span></a></li>',this);r.append(t,n)})),g(n.find("li"),a),p(n)}))}function p(e){M(e.find("li"),(function(){0===$(this).children("ul").length&&$(this).children("a").click((function(){c.setSideMenuVisible({visible:!s})}))}))}function g(e,t){e.attr("tabindex",t),M(e.find("li"),(function(){var e=$(this);e.attr("tabindex",t);var n=e.children("a");n.length>0&&$(n).attr("tabindex",-1);e.focus((function(){var t=e.children("a");t.length>0&&t.addClass("k-focus")})),e.blur((function(){var t=e.children("a");t.length>0&&t.removeClass("k-focus")})),e.off("keydown",h),e.on("keydown",h)}))}function v(e){if(e.which==kendo.keys.ENTER){var t,n=!1,a=document.activeElement;if(a&&"li"==a.localName)for(var i=r.element.find("li.k-item"),o=0;o<i.length;o++){var l=i[o];if(a===l){t=$(l),n=!0;break}}else t=r.select();if(!t||!t.length>0)return;m(t,n)}}function h(e){e.which==kendo.keys.ENTER&&m($(e.target),!1)}function m(e,t){if(!(!e.length>0))if(0===e.children("ul").length){var n=e.find("a");n.length>0&&n[0].click()}else t&&(e.hasClass("k-active")?r.collapse(e):r.expand(e))}i||function(e){var t=$(e);try{r=t.children("ul").kendoPanelBar().data("kendoPanelBar")}catch(e){throw console.error("Instantiation of Kendo PanelBar as side menu threw an exception",e),e}r.bind("expand",d),r.element.off("keydown",v),r.element.on("keydown",v),function(e){if(!e)return;var t=e.children("ul"),n=e.attr("tabindex");g(t,n||l)}(t),p(t),t.click((function(t){t.target==e&&c.setSideMenuVisible({visible:!s})})),function(){var e=V("div[data-role=telerik_ReportViewer_SideMenu] > ul");if(!e)return;M(e,(function(){var e=$(this),t=e.children("li.k-panelbar-header");e.attr("aria-label",ee[e.attr("aria-label")]),M(t,(function(){var e=$(this),t=e.find("a");if(e.attr("aria-label",ee[e.attr("aria-label")]),t){var n=t.find("span:not(.k-icon)");t.attr("title",ee[t.attr("title")]),n&&n.text(ee[n.text()])}}))}))}()}(e),c.setSideMenuVisible((function(e,t){var n;(n=r.element.parent()).position().left<0||!n.is(":visible")?n.show():window.setTimeout((function(){n.hide()}),500),o&&r.element.focus(),(s=t.visible)||r.collapse($("#trv-side-menu-export-command"))})).getSideMenuVisible((function(e,t){t.visible=s}))}$.fn[Nt]=function(e,t){return M(this,(function(){$.data(this,Nt)||$.data(this,Nt,new Dt(this,e,t))}))};var yt="telerik_ReportViewer_SideMenu";$.fn[yt]=function(e,t){return M(this,(function(){$.data(this,yt)||$.data(this,yt,new Mt(this,e,t))}))};var kt=Object.defineProperty,xt=(e,t,n)=>(((e,t,n)=>{t in e?kt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);class $t{constructor(){xt(this,"_data",{}),this._data={}}get length(){return Object.keys(this._data).length}getItem(e){return this._data[e]||null}setItem(e,t){this._data[e]=t}removeItem(e){delete this._data[e]}key(e){return Object.keys(this._data)[e]||null}clear(){this._data={}}}const Lt=(Ot={},{load:function(e,t,n){var r=Ot[e];return r||(Ot[e]=r=n.get(e).then((function(e){var n={},r=[],a=c(t,"\\/")+"/";e=l(e,"{service}/",a),e=l(e,"{service}",a);var i=$("<div></div>").html(e);return M(i.find("template"),(function(e,t){var r=$(t);n[r.attr("id")]=o(r.html(),"\n \t")})),M(i.find("link"),(function(e,t){r.push(o(t.outerHTML,"\n \t"))})),r=L(r),{templates:n,styleSheets:r}}))),r}});var Ot,Vt=Object.defineProperty,Ut=(e,t,n)=>(((e,t,n)=>{t in e?Vt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);class Gt{constructor(e,t,n){Ut(this,"_id"),Ut(this,"_storage"),Ut(this,"_defaults"),this._id=e,this._storage=t,this._defaults=n||{}}formatKey(e){return this._id+"_"+e}getItem(e){var t=this._storage.getItem(this.formatKey(e));if("string"==typeof t)try{t=JSON.parse(t)}catch(e){t=null}return null!=t?t:this._defaults[e]}setItem(e,t){var n=this.formatKey(e);this._storage.setItem(n,JSON.stringify(t))}getViewMode(){return this.getItem("viewMode")}setViewMode(e){this.setItem("viewMode",e)}getPageMode(){return this.getItem("pageMode")}setPageMode(e){this.setItem("pageMode",e)}getPrintMode(){return this.getItem("printMode")}setPrintMode(e){this.setItem("printMode",e)}getScale(){return this.getItem("scale")}setScale(e){this.setItem("scale",e)}getScaleMode(){return this.getItem("scaleMode")}setScaleMode(e){this.setItem("scaleMode",e)}getDocumentMapVisible(){return this.getItem("documentMapVisible")}setDocumentMapVisible(e){this.setItem("documentMapVisible",e)}getParametersAreaVisible(){return this.getItem("parametersAreaVisible")}setParametersAreaVisible(e){this.setItem("parametersAreaVisible",e)}getHistory(){return this.getItem("history")}setHistory(e){this.setItem("history",e)}getClientId(){return this.getItem("clientId")}setClientId(e){this.setItem("clientId",e)}getReportSource(){return this.getItem("reportSource")}setReportSource(e){this.setItem("reportSource",e)}getPageNumber(){return this.getItem("pageNumber")}setPageNumber(e){this.setItem("pageNumber",e)}getEnableAccessibility(){return this.getItem("enableAccessibility")}setEnableAccessibility(e){this.setItem("enableAccessibility",e)}getAccessibilityKeyMap(){return this.getItem("accessibilityKeyMap")}setAccessibilityKeyMap(e){this.setItem("accessibilityKeyMap",e)}getSearchMetadataOnDemand(){return this.getItem("searchMetadataOnDemand")}setSearchMetadataOnDemand(e){this.setItem("searchMetadataOnDemand",e)}getKeepClientAlive(){return this.getItem("keepClientAlive")}setKeepClientAlive(e){this.setItem("keepClientAlive",e)}}const Ft=re.viewerInstances;function Bt(e,t){var n=t.serviceUrl,r="";t.reportServer&&(r=c(t.reportServer.url,"\\/"),n=r+"/api/reports");var a,o,l,s=$(e),f={},p=t.id||`trv_${e.id}`,g={},v={},h={},m={},E={},b={},T="";if(t.viewerSelector="reportViewer-"+i(),s.attr("data-selector",t.viewerSelector),function(e){if(!e)return s.text("The report viewer configuration options are not initialized."),!1;if(e.reportServer){if(!e.reportServer.url)return s.text("The report server URL is not specified."),!1}else if(!e.serviceUrl)return s.text("The serviceUrl is not specified."),!1;return!0}(t)){var P="18.1.24.514";return t=N({},function(e,t){return{id:null,serviceUrl:null,templateUrl:c(e,"\\/")+"/resources/templates/telerikReportViewerTemplate-"+t+".html/",reportSource:null,reportServer:null,authenticationToken:null,sendEmail:null,scale:1,scaleMode:ge.FIT_PAGE,viewMode:de.INTERACTIVE,pageMode:pe.CONTINUOUS_SCROLL,parametersAreaPosition:me.RIGHT,documentMapAreaPosition:Ee.LEFT,parameters:{editors:{multiSelect:he.LIST_VIEW,singleSelect:he.LIST_VIEW}},persistSession:!1,parameterEditors:[],disabledButtonClass:null,checkedButtonClass:null,parametersAreaVisible:!0,documentMapVisible:!0,enableAccessibility:!1,searchMetadataOnDemand:!1,initialPageAreaImageUrl:null,keepClientAlive:!0}}(n,P),t),g=new Gt(p,t.persistSession?window.sessionStorage:new $t,{scale:t.scale,scaleMode:t.scaleMode,printMode:t.printMode?t.printMode:t.directPrint,enableAccessibility:t.enableAccessibility,searchMetadataOnDemand:t.searchMetadataOnDemand,sendEmail:t.sendEmail,parametersAreaPosition:t.parametersAreaPosition,documentMapAreaPosition:t.documentMapAreaPosition,keepClientAlive:t.keepClientAlive}),t.reportServer?(T=c(t.reportServer.url,"\\/"),b.serviceUrl=T+"/api/reports",b.loginInfo={url:T+"/Token",username:t.reportServer.username,password:t.reportServer.password}):b.serviceUrl=t.serviceUrl,o=new dt(b),(v=t.controller)?v.updateSettings(g):v=new xe({serviceClient:o,settings:g}),l=new Ve({controller:v,settings:g}),m=new Ie({controller:v,history:l}),new ft({controller:v,history:l,commands:m}),E={stringResources:ee,refreshReport:function(e){return 0===arguments.length&&(e=!0),v.refreshReport(e),E},reportSource:function(e){return e||null===e?(v.setReportSource(e),v.refreshReport(!1),E):v.getReportSource()},clearReportSource:function(){return v.clearReportSource(),E},viewMode:function(e){return e?(v.setViewMode(e),E):v.getViewMode()},pageMode:function(e){return e?(v.setPageMode(e),E):v.getPageMode()},printMode:function(e){return e?(v.setPrintMode(e),E):v.getPrintMode()},scale:function({scale:e,scaleMode:t}={}){return e||t?(v.setScale(e||v.getScale()),v.setScaleMode(t||v.getScaleMode()),E):{scale:v.getScale(),scaleMode:v.getScaleMode()}},currentPage:function(){return v.getCurrentPageNumber()},pageCount:function(){return v.getPageCount()},parametersAreaVisible:function(e){v.setParametersAreaVisible({visible:e})},getReportParameters:function(){return v.getReportParameters()},authenticationToken:function(e){return e&&v.setAuthenticationToken(e),E},bind:function(e,t){I(e,t,!0)},unbind:function(e,t){I(e,t,!1)},accessibilityKeyMap:function(e){if(a)return e?(a.setKeyMap(e),E):a.getKeyMap()},commands:m,dispose:function(){v.dispose(),h&&h.dispose()}},window.Promise?R(P):k("https://cdn.polyfill.io/v2/polyfill.min.js?features=Promise",R,P),E}function I(e,t,n){"function"==typeof t?n?$(E).on(e,{sender:E},t):$(E).off(e,t):t||n||$(E).off(e)}function _(){var n,r,i,o,l,c,u;s.html(f["trv-report-viewer"]),ae.bind(s,{controller:v,commands:m,templates:f},t),(h=new at(e,v)).attach(),function(){var e={max:"500px",min:"50px",size:"210px",collapsible:!0},n=s.find(".trv-parameters-area"),r=[{}],a={max:"500px",min:"50px",size:"210px",collapsible:!0,collapsed:!0},i=s.find(".trv-document-map"),o=[{}],l="horizontal";t.documentMapAreaPosition===Ee.RIGHT?(i.insertAfter(s.find(".trv-pages-area")),o.push(a)):o.unshift(a);t.parametersAreaPosition!==me.TOP&&t.parametersAreaPosition!==me.BOTTOM||(l="vertical",n.addClass("-vertical"),e.size="130px");t.parametersAreaPosition===me.LEFT||t.parametersAreaPosition===me.TOP?(n.insertBefore(s.find(".trv-document-map-splitter")),r.unshift(e)):r.push(e);try{var c=s.find(".trv-document-map-splitter").kendoSplitter({panes:o,expand:function(e){C(e.pane,!0)},collapse:function(e){C(e.pane,!1)},resize:function(e){}}).data("kendoSplitter")}catch(e){throw console.error("Instantiation of Kendo Splitter as Document Map splitter threw an exception",e),e}try{var u=s.find(".trv-parameters-splitter").kendoSplitter({panes:r,orientation:l,expand:function(e){C(e.pane,!0)},collapse:function(e){C(e.pane,!1)},resize:function(e){}}).data("kendoSplitter")}catch(e){throw console.error("Instantiation of Kendo Splitter as Parameters area splitter threw an exception",e),e}var d={id:t.viewerSelector+"-parameters-splitter",instance:u},f={id:t.viewerSelector+"-document-map-splitter",instance:c};Ft.push(d),Ft.push(f)}(),function(){var e={EXPORT_BEGIN:v.Events.EXPORT_STARTED,EXPORT_END:v.Events.EXPORT_DOCUMENT_READY,PRINT_BEGIN:v.Events.PRINT_STARTED,PRINT_END:v.Events.PRINT_DOCUMENT_READY,RENDERING_BEGIN:v.Events.BEFORE_LOAD_REPORT,RENDERING_END:v.Events.REPORT_LOAD_COMPLETE,PAGE_READY:v.Events.PAGE_READY,ERROR:v.Events.ERROR,UPDATE_UI:v.Events.UPDATE_UI,INTERACTIVE_ACTION_EXECUTING:v.Events.INTERACTIVE_ACTION_EXECUTING,INTERACTIVE_ACTION_ENTER:v.Events.INTERACTIVE_ACTION_ENTER,INTERACTIVE_ACTION_LEAVE:v.Events.INTERACTIVE_ACTION_LEAVE,VIEWER_TOOLTIP_OPENING:v.Events.TOOLTIP_OPENING,SEND_EMAIL_BEGIN:v.Events.SEND_EMAIL_STARTED,SEND_EMAIL_END:v.Events.SEND_EMAIL_READY},t=$(E);for(const[n,r]of Object.entries(e))v.on(r,(function(e,r){t.trigger(n,r)}))}(),I(Oe.EXPORT_BEGIN,t.exportBegin,!0),I(Oe.EXPORT_END,t.exportEnd,!0),I(Oe.PRINT_BEGIN,t.printBegin,!0),I(Oe.PRINT_END,t.printEnd,!0),I(Oe.RENDERING_BEGIN,t.renderingBegin,!0),I(Oe.RENDERING_END,t.renderingEnd,!0),I(Oe.PAGE_READY,t.pageReady,!0),I(Oe.ERROR,t.error,!0),I(Oe.UPDATE_UI,t.updateUi,!0),I(Oe.INTERACTIVE_ACTION_EXECUTING,t.interactiveActionExecuting,!0),I(Oe.INTERACTIVE_ACTION_ENTER,t.interactiveActionEnter,!0),I(Oe.INTERACTIVE_ACTION_LEAVE,t.interactiveActionLeave,!0),I(Oe.VIEWER_TOOLTIP_OPENING,t.viewerToolTipOpening,!0),I(Oe.SEND_EMAIL_BEGIN,t.sendEmailBegin,!0),I(Oe.SEND_EMAIL_END,t.sendEmailEnd,!0),n=g.getViewMode(),r=g.getPageMode(),i=g.getPrintMode(),o=g.getScale(),l=g.getScaleMode(),c=g.getDocumentMapVisible(),u=g.getParametersAreaVisible(),g.getAccessibilityKeyMap(),v.setViewMode(n||t.viewMode),v.setPageMode(r||t.pageMode),v.setPrintMode(i||t.printMode),v.setScale(o||t.scale),v.setScaleMode(l||t.scaleMode),v.setDocumentMapVisible({visible:c||t.documentMapVisible}),v.setParametersAreaVisible({visible:u||t.parametersAreaVisible}),v.printModeChanged((function(){g.setPrintMode(v.getPrintMode())})),v.viewModeChanged((function(){g.setViewMode(v.getViewMode())})),v.pageModeChanged((function(){g.setPageMode(v.getPageMode())})),v.scaleChanged((function(e,t){g.setScale(t)})),v.scaleModeChanged((function(e,t){g.setScaleMode(t)})),v.setSideMenuVisible((function(e,t){window.setTimeout((function(){(t.visible?$.fn.addClass:$.fn.removeClass).call(s,"trv-side-menu-visible")}),1)})),v.setDocumentMapVisible((function(){var e={};v.getDocumentMapState(e),g.setDocumentMapVisible(e.visible)})),v.setParametersAreaVisible((function(){var e={};v.getParametersAreaState(e),g.setParametersAreaVisible(e.visible)})),function(e){if(e.enableAccessibility){a=new ne({controller:v,templates:f});var t=e.accessibilityKeyMap;t&&a.setKeyMap(t),g.contentTabIndex=function(){var e="div.trv-pages-area";try{var t=s.find(e);if(0===t.length)throw"Selector "+e+" did not return a result.";return parseInt(t.attr("tabindex"))}catch(e){return console&&console.log(e),0}}()}}(t)}function C(e,t){switch($(e).attr("data-id")){case"trv-document-map":v.setDocumentMapVisible({visible:t});break;case"trv-parameters-area":v.setParametersAreaVisible({visible:t})}}function w(){var e=!1;_(),v.reportLoadComplete((function(){!1===t.documentMapVisible&&v.setDocumentMapVisible({visible:!1})}));var n=g.getReportSource();if(void 0!==n){v.setReportSource(n);var r=g.getPageNumber();void 0!==r&&v.navigateToPage(r),e=!0}else t.viewMode&&v.setViewMode(t.viewMode),t.pageMode&&v.setPageMode(t.pageMode),t.reportSource&&(v.setReportSource(t.reportSource),e=!0);"function"==typeof t.ready&&t.ready.call(E),e&&v.refreshReport(!1)}function R(e){(function(e){return window.kendo?Promise.resolve():x(c(n,"\\/")+"/resources/js/telerikReportViewer.kendo-"+e+".min.js/").catch((function(e){O("Kendo could not be loaded automatically. Make sure 'options.serviceUrl' / 'options.reportServer.url' is correct and accessible. The error is: "+e.error)}))})(e).then((function(){})).then((function(){E.authenticationToken(t.authenticationToken),v.getServiceVersion().catch((function(e){var t=S(e)?e.exceptionMessage:u(ee.errorServiceUrl,[d(n)]);return s.text(t),Promise.reject()})).then((function(r){if(r!==e)return s.text(u(ee.errorServiceVersion,[r,e])),Promise.reject();Lt.load(t.templateUrl,n,o).catch((function(){return s.text(u(ee.errorLoadingTemplates,[d(t.templateUrl)])),Promise.reject()})).then((function(e){return f=e.templates,function(e){if(!e)return Promise.resolve();var t=$("head"),n=t.find("link").map((function(e,t){return t.outerHTML})).toArray(),r=[];return M(e,(function(e,a){-1===n.indexOf(a)&&r.push(new Promise((function(e,n){var r=$(a);r.on("load",e),r.on("onerror",(function(){O("error loading stylesheet "+a),e()})),t.append(r)})))})),Promise.all(r).then(v.cssLoaded)}(e.styleSheets)})).then(w)}))}))}}var Ht="telerik_ReportViewer";$.fn[Ht]=function(e){return this.selector&&!e.selector&&(e.selector=this.selector),M(this,(function(){$.data(this,Ht)||$.data(this,Ht,new Bt(this,e))}))};return[{name:"telerik_ReportViewer_DocumentMapArea",constructor:gt},{name:"telerik_ReportViewer_MainMenu",constructor:_t},{name:"telerik_ReportViewer_PagesArea",constructor:He},{name:"telerik_ReportViewer_ParametersArea",constructor:bt},{name:"telerik_ReportViewer_SearchDialog",constructor:wt},{name:"telerik_ReportViewer_SendEmail",constructor:Dt},{name:"telerik_ReportViewer_SideMenu",constructor:Mt}].forEach((e=>{$.fn[e.name]=function(t,n){return M(this,(function(){$.data(this,e.name)||$.data(this,e.name,new e.constructor(this,t,n))}))}})),e.Accessibility=ne,e.Binder=ae,e.CommandSet=Ie,e.DocumentMapAreaPositions=Ee,e.Events=Oe,e.GlobalSettings=re,e.HistoryManager=Ve,e.PageModes=pe,e.PagesArea=He,e.ParameterEditorTypes=he,e.ParameterEditors=rt,e.ParameterTypes=ve,e.ParameterValidators=De,e.ParametersAreaPositions=me,e.PerspectiveManager=at,e.PrintManager=Ae,e.PrintModes=fe,e.ReportViewer=Bt,e.ReportViewerController=xe,e.ScaleModes=ge,e.Scroll=Ge,e.ServiceClient=dt,e.TouchBehavior=Ue,e.UIController=ft,e.UIFreezeCoordinator=Fe,e.ViewModes=de,e.domUtils=J,e.parameterEditorsMatch=Ke,e.utils=z,Object.defineProperty(e,"__esModule",{value:!0}),e}({});
1
+ var telerikReportViewer=function(e){"use strict";var t=/{(\w+?)}/g,n={DELETE:46,BACKSPACE:8,TAB:9,ESC:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,END:35,HOME:36};function r(){if(window.navigator.userAgent.toLowerCase().indexOf("firefox")>-1){var e=Object.keys(n),t=e.length;return function(r){for(var a=0;a<t;a++)if(n[e[a]]==r)return!0}}return function(e){return!1}}function a(e,t,n,r){return{left:e,top:t,width:n,height:r,right:function(){return e+n},bottom:function(){return t+r},union:function(n){var r=Math.min(e,n.left),i=Math.min(t,n.top);return a(r,i,Math.max(this.right(),n.right())-r,Math.max(this.bottom(),n.bottom())-i)}}}function i(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"==e?t:3&t|8).toString(16)}))}function o(e,t){return c(l(e,t),t)}function s(e,t,n){return e.replace(new RegExp(t,"g"),n)}function l(e,t){return void 0===t&&(t="s"),e.replace(new RegExp("^["+t+"]+"),"")}function c(e,t){return void 0===t&&(t="s"),e.replace(new RegExp("["+t+"]+$"),"")}function u(e,n){var r=Array.isArray(n);return e.replace(t,(function(e,t){return n[r?parseInt(t):t]}))}function d(e){return $("<div>").text(e).html()}function f(e){return/^(\-|\+)?([0-9]+)$/.test(e)?Number(e):NaN}function h(e){return/^(\-|\+)?([0-9]+(\.[0-9]+)?)$/.test(e)?Number(e):NaN}function p(e){return e instanceof Date?e:(/Z|[\+\-]\d\d:?\d\d/i.test(e)||(e+="Z"),new Date(e))}function g(e){return new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()))}function m(e){return new Date(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds())}function v(e,t){if(e instanceof Date&&t instanceof Date){if(e.getTime()!==t.getTime())return!1}else if(e!==t)return!1;return!0}function E(e,t){if(e&&t&&e.report===t.report){var n="";e.parameters&&(n=JSON.stringify(e.parameters));var r="";return t.parameters&&(r=JSON.stringify(t.parameters)),n===r}return!1}function b(e,t){if(null===e)return null===t;if(null===t)return!1;if(e.length!==t.length)return!1;for(var n=e.length-1;n>=0;n--)if(!v(e[n],t[n]))return!1;return!0}function P(){var e=/Version\/(\d+.\d+.\d+) Safari/.exec(navigator.userAgent);return!(e&&e.length>1)||parseFloat(e[1])>=6}function T(e){return!!e&&"internalservererror"===s(e," ","").toLowerCase()}function S(e){var t="ArgumentException";return w(M(e),t,"System."+t)}function _(e){var t="InvalidClientException";return w(M(e),t,"Telerik.Reporting.Services.Engine."+t)}function C(e){return I(M(e))}function I(e){var t="DrawingFactoryUnavailableException";return w(e,t,"Telerik.Drawing.Contract."+t)}function w(e,t,n){return e&&e.exceptionType&&R(e.exceptionType,t,n)}function R(e,t,n){return e&&(e===n||e.endsWith(t))}function A(e){try{return JSON.parse(e,(function(e,t){if(e&&t){var n=e.charAt(0);if(n===n.toUpperCase())this[n.toLowerCase()+e.slice(1)]=t}return t}))}catch(e){return null}}function M(e){return!(!e||!e.responseText)&&A(e.responseText)}function y(e){return!!Array.isArray(e)||"number"==typeof(Boolean(e)&&"length"in e&&e.length)}function N(e){return V(e,{dataType:"script",cache:!0})}function D(e){return e.filter((function(e,t,n){return n.lastIndexOf(e)===t}))}function k(e){var t=window.console;t&&t.error&&t.error(e)}function x(e){if(e&&e.length<6){var t=1,n=e.split("");for("#"!==n[0]&&(t=0);t<n.length;t++)n[t]=n[t]+n[t];e=n.join("")}var r=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return r?parseInt(r[1],16)+", "+parseInt(r[2],16)+", "+parseInt(r[3],16):null}function L(e){return!!e&&e.indexOf(",")>-1}function O(e){if("transparent"===e.toLowerCase())return 0;if(!L(e))return 1;-1!==e.indexOf("#")&&(e=x(e));var t=e.split(",").map((function(e){return e.trim()}));return 4===t.length?parseFloat((parseFloat(t[3].replace(/[()]/g,""))/255).toFixed(2)):1}function V(e,t){return new Promise((function(n,r){$.ajax(e,t).done((function(e){return n(e)})).fail((function(e,t,n){r(function(e,t,n){return{xhr:e,status:t,error:n}}(e,t,n))}))}))}function F(e){return Object.prototype.toString.call(e).slice(8,-1)}var G=Object.freeze({__proto__:null,isSpecialKey:r,rectangle:a,generateGuidString:i,trim:o,replaceAll:s,lTrim:l,rTrim:c,stringFormat:u,escapeHtml:d,tryParseInt:f,tryParseFloat:h,parseToLocalDate:p,adjustTimezone:g,unadjustTimezone:m,areEqual:v,reportSourcesAreEqual:E,areEqualArrays:b,isSvgSupported:P,isInternalServerError:T,isSystemArgumentException:S,isInvalidClientException:_,isApplicationException:C,isApplicationExceptionInstance:I,isExceptionOfType:function(e,t){return w(M(e),t,t)},exceptionTypeNamesMatch:R,parseJSON:A,getExceptionInstance:M,extend:function(){var e,t,n,r,a=0,i=arguments.length;for(r=i>1&&arguments[a++]||{};a<i;a++)if(null!=(n=arguments[a]))for(t in n)r[t],r!==(e=n[t])&&void 0!==e&&(r[t]=e);return r},each:function(e,t){var n,r=0;if(y(e))for(n=e.length;r<n&&!1!==t.call(e[r],r,e[r]);r++);else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},selector:function(){return document.querySelectorAll(arguments[0])},isArray:y,loadScriptWithCallback:function(e,t,n){var r=document.createElement("script");r.src=e,r.onload=function(){t(n)},r.onerror=function(){k(new Error("Failed to load script "+e))},document.head.appendChild(r)},loadScript:N,filterUniqueLastOccurrence:D,logError:k,findElement:function(e){e.constructor!=Array&&(e=[e]);for(var t=$(e[0]),n=1;n<e.length;n++)t=t.find(e[n]);return t},toRgbColor:x,isRgbColor:L,getColorAlphaValue:O,$ajax:V,type:F,isEqual:function e(t,n){if(t===n)return!0;if(t!=t&&n!=n)return!0;if(t!=t&&n==n||t==t&&n!=n)return!1;const r=F(t);if(r!==F(n))return!1;if("Array"===r){if(t.length!==n.length)return!1;const r=t.length;for(let a=0;a<r;a++)if(!e(t[a],n[a]))return!1;return!0}if("Object"===r){const r=Object.keys(t),a=Object.keys(n);if(r.length!==a.length)return!1;const i=r.length;for(let a=0;a<i;a++){const i=r[a];if(!e(t[i],n[i]))return!1}return!0}return"Date"===r&&t.getTime()===n.getTime()}});function U(e){return parseInt(e,10)||0}function B(e){var t=$(e);return{left:U(t.css("marginLeft")),right:U(t.css("marginRight")),top:U(t.css("marginTop")),bottom:U(t.css("marginBottom"))}}function H(e){var t=$(e);return{left:U(t.css("paddingLeft")),right:U(t.css("paddingRight")),top:U(t.css("paddingTop")),bottom:U(t.css("paddingBottom"))}}function z(e){var t=$(e);return{left:U(t.css("borderLeftWidth")),right:U(t.css("borderRightWidth")),top:U(t.css("borderTopWidth")),bottom:U(t.css("borderBottomWidth"))}}function W(e,t,n,r,a){r=r||0,a=a||0;var i=u("scale({0}, {1})",[t=t||1,n=n||1]),o=u("{0} {1}",[r,a]);$(e).css("transform",i).css("transform-origin",o)}var j,K=Object.freeze({__proto__:null,getMargins:B,getPadding:H,getBorderWidth:z,scale:W});window.telerikReportViewer||(window.telerikReportViewer={}),(j=window.telerikReportViewer).sr||(j.sr={controllerNotInitialized:"Controller is not initialized.",noReportInstance:"No report instance.",missingTemplate:"!obsolete resource!",noReport:"No report.",noReportDocument:"No report document.",missingOrInvalidParameter:"There are missing or invalid parameter values. Please input valid data for the following parameters:\n",invalidParameter:"Please input a valid value.",invalidDateTimeValue:"Please input a valid date.",parameterIsEmpty:"Parameter value cannot be empty.",cannotValidateType:"Cannot validate parameter of type {type}.",loadingFormats:"Loading...",loadingReport:"Loading report...",preparingDownload:"Preparing document to download. Please wait...",preparingPrint:"Preparing document to print. Please wait...",errorLoadingTemplates:"Error loading the report viewer's templates. (templateUrl = '{0}').",errorServiceUrl:"Cannot access the Reporting REST service. (serviceUrl = '{0}'). Make sure the service address is correct and enable CORS if needed. (https://enable-cors.org)",errorServiceVersion:"The version of the Report Viewer '{1}' does not match the version of the Reporting REST Service '{0}'. Please make sure both are running same version.",loadingReportPagesInProgress:"{0} pages loaded so far...",loadedReportPagesComplete:"Done. Total {0} pages loaded.",noPageToDisplay:"No page to display.",errorDeletingReportInstance:"Error deleting report instance: '{0}'.",errorRegisteringViewer:"Error registering the viewer with the service.",noServiceClient:"No serviceClient has been specified for this controller.",errorRegisteringClientInstance:"Error registering client instance.",errorCreatingReportInstance:"Error creating report instance (Report = '{0}').",errorCreatingReportDocument:"Error creating report document (Report = '{0}'; Format = '{1}').",unableToGetReportParameters:"Unable to get report parameters.",errorObtainingAuthenticationToken:"Error obtaining authentication token.",clientExpired:"Click 'Refresh' to restore client session.",promisesChainStopError:"Error shown. Throwing promises chain stop error.",renderingCanceled:"Report processing was canceled.",tryReportPreview:"The report may now be previewed.",parameterEditorSelectNone:"clear selection",parameterEditorSelectAll:"select all",parametersAreaPreviewButton:"Preview",menuNavigateBackwardText:"Navigate Backward",menuNavigateBackwardTitle:"Navigate Backward",menuNavigateForwardText:"Navigate Forward",menuNavigateForwardTitle:"Navigate Forward",menuStopRenderingText:"Stop Rendering",menuStopRenderingTitle:"Stop Rendering",menuRefreshText:"Refresh",menuRefreshTitle:"Refresh",menuFirstPageText:"First Page",menuFirstPageTitle:"First Page",menuLastPageText:"Last Page",menuLastPageTitle:"Last Page",menuPreviousPageTitle:"Previous Page",menuNextPageTitle:"Next Page",menuPageNumberTitle:"Page Number Selector",menuDocumentMapTitle:"Toggle Document Map",menuParametersAreaTitle:"Toggle Parameters Area",menuZoomInTitle:"Zoom In",menuZoomOutTitle:"Zoom Out",menuPageStateTitle:"Toggle FullPage/PageWidth",menuPrintText:"Print...",menuContinuousScrollText:"Toggle Continuous Scrolling",menuSendMailText:"Send an email",menuPrintTitle:"Print",menuContinuousScrollTitle:"Toggle Continuous Scrolling",menuSendMailTitle:"Send an email",menuExportText:"Export",menuExportTitle:"Export",menuPrintPreviewText:"Toggle Print Preview",menuPrintPreviewTitle:"Toggle Print Preview",menuSearchText:"Search",menuSearchTitle:"Toggle Search",menuSideMenuTitle:"Toggle Side Menu",sendEmailFromLabel:"From:",sendEmailToLabel:"To:",sendEmailCCLabel:"CC:",sendEmailSubjectLabel:"Subject:",sendEmailFormatLabel:"Format:",sendEmailSendLabel:"Send",sendEmailCancelLabel:"Cancel",ariaLabelPageNumberSelector:"Page number selector. Showing page {0} of {1}.",ariaLabelPageNumberEditor:"Page number editor",ariaLabelExpandable:"Expandable",ariaLabelSelected:"Selected",ariaLabelParameter:"parameter",ariaLabelErrorMessage:"Error message",ariaLabelParameterInfo:"Contains {0} options",ariaLabelMultiSelect:"Multiselect",ariaLabelMultiValue:"Multivalue",ariaLabelSingleValue:"Single value",ariaLabelParameterDateTime:"DateTime",ariaLabelParameterString:"String",ariaLabelParameterNumerical:"Numerical",ariaLabelParameterBoolean:"Boolean",ariaLabelParametersAreaPreviewButton:"Preview the report",ariaLabelMainMenu:"Main menu",ariaLabelCompactMenu:"Compact menu",ariaLabelSideMenu:"Side menu",ariaLabelDocumentMap:"Document map area",ariaLabelDocumentMapSplitter:"Document map area splitbar.",ariaLabelParametersAreaSplitter:"Parameters area splitbar.",ariaLabelPagesArea:"Report contents area",ariaLabelSearchDialogArea:"Search area",ariaLabelSendEmailDialogArea:"Send email area",ariaLabelSearchDialogStop:"Stop search",ariaLabelSearchDialogOptions:"Search options",ariaLabelSearchDialogNavigateUp:"Navigate up",ariaLabelSearchDialogNavigateDown:"Navigate down",ariaLabelSearchDialogMatchCase:"Match case",ariaLabelSearchDialogMatchWholeWord:"Match whole word",ariaLabelSearchDialogUseRegex:"Use regex",ariaLabelMenuNavigateBackward:"Navigate backward",ariaLabelMenuNavigateForward:"Navigate forward",ariaLabelMenuStopRendering:"Stop rendering",ariaLabelMenuRefresh:"Refresh",ariaLabelMenuFirstPage:"First page",ariaLabelMenuLastPage:"Last page",ariaLabelMenuPreviousPage:"Previous page",ariaLabelMenuNextPage:"Next page",ariaLabelMenuPageNumber:"Page number selector",ariaLabelMenuDocumentMap:"Toggle document map",ariaLabelMenuParametersArea:"Toggle parameters area",ariaLabelMenuZoomIn:"Zoom in",ariaLabelMenuZoomOut:"Zoom out",ariaLabelMenuPageState:"Toggle FullPage/PageWidth",ariaLabelMenuPrint:"Print",ariaLabelMenuContinuousScroll:"Continuous scrolling",ariaLabelMenuSendMail:"Send an email",ariaLabelMenuExport:"Export",ariaLabelMenuPrintPreview:"Toggle print preview",ariaLabelMenuSearch:"Search in report contents",ariaLabelMenuSideMenu:"Toggle side menu",ariaLabelSendEmailFrom:"From email address",ariaLabelSendEmailTo:"Recipient email address",ariaLabelSendEmailCC:"Carbon Copy email address",ariaLabelSendEmailSubject:"Email subject:",ariaLabelSendEmailFormat:"Report format:",ariaLabelSendEmailSend:"Send email",ariaLabelSendEmailCancel:"Cancel sending email",searchDialogTitle:"Search in report contents",searchDialogSearchInProgress:"searching...",searchDialogNoResultsLabel:"No results",searchDialogResultsFormatLabel:"Result {0} of {1}",searchDialogStopTitle:"Stop Search",searchDialogNavigateUpTitle:"Navigate Up",searchDialogNavigateDownTitle:"Navigate Down",searchDialogMatchCaseTitle:"Match Case",searchDialogMatchWholeWordTitle:"Match Whole Word",searchDialogUseRegexTitle:"Use Regex",searchDialogCaptionText:"Find",searchDialogPageText:"page",sendEmailDialogTitle:"Send Email",sendEmailValidationEmailRequired:"Email field is required",sendEmailValidationEmailFormat:"Email format is not valid",sendEmailValidationSingleEmail:"The field accepts a single email address only",sendEmailValidationFormatRequired:"Format field is required",errorSendingDocument:"Error sending report document (Report = '{0}')."});var Y=Y||{};const X=(window.telerikReportViewer||{}).sr||{},q=$.extend({},Y,X);var J={};function Z(e){var t,n,r,a=!1,i={CONFIRM_KEY:13,CONTENT_AREA_KEY:67,DOCUMENT_MAP_AREA_KEY:68,MENU_AREA_KEY:77,PARAMETERS_AREA_KEY:80};if(!(t=(e=$.extend({},J,e)).controller))throw"No controller (telerikReporting.ReportViewerController) has been specified.";function o(){n||(!function(){(n={})[i.DOCUMENT_MAP_AREA_KEY]=$("div[data-role=telerik_ReportViewer_DocumentMapArea] div[data-role=treeview]"),n[i.MENU_AREA_KEY]=$("ul[data-role=telerik_ReportViewer_MainMenu]"),n[i.CONTENT_AREA_KEY]=s();var e=$("div[data-role=telerik_ReportViewer_ParametersArea] div.trv-parameters-area-content");e&&(n[i.PARAMETERS_AREA_KEY]=e,function(e){if(0===e.length)return;var t=e.parent("div[data-role=telerik_ReportViewer_ParametersArea]");if(!c(t))return;Array.from(e.children()).forEach((e=>{$(e).on("keydown",(e=>{e.which==i.CONFIRM_KEY&&(t.find("button.trv-parameters-area-preview-button").focus(),e.preventDefault())}))}))}(e))}(),$(document.body).off("keydown",l),$(document.body).on("keydown",l))}function s(){return $("div[data-role=telerik_ReportViewer_PagesArea]")}function l(e){if(n&&e.altKey&&e.ctrlKey){var t=n[e.which];if(t&&c(t.parent())){var a="k-focus";r&&r.removeClass(a),t.addClass(a),t.focus(),r=t,e.preventDefault()}}}function c(e){return e&&!(e.hasClass("k-collapsed")||e.hasClass("trv-hidden"))}return t.reportLoadComplete((function(){o();var e=s();e.length>0&&e.focus()})).pageReady((function(e,t){!function(e){if(!e)return;o(),function(e){if(!e)return;var t=e.find("div [data-reporting-action]");if(!t.length>0)return;Array.from(t).forEach((e=>{var t=$(e);t.on("keydown",(e=>{e.which==i.CONFIRM_KEY&&t.trigger("click")}))}))}(n[i.CONTENT_AREA_KEY])}(t),a=!0})).error((function(e,t){!function(){var e=$("div.trv-pages-area div.trv-error-message");if(0===e.length)return;e.attr("tabIndex",0),e.focus()}(),window.setTimeout(o,500)})),t.updateUI((function(e){a&&(function(){var e=document.querySelectorAll(".trv-report-pager"),t=this._controller.getCurrentPageNumber(),n=this._controller.getPageCount();e.forEach((e=>{e.setAttribute("aria-label",u(q.ariaLabelPageNumberSelector,[t,n])),e.querySelectorAll("input[data-role=telerik_ReportViewer_PageNumberInput]").forEach((e=>{e.setAttribute("aria-label",q.ariaLabelPageNumberEditor)}))}))}(),function(){var e=n[i.MENU_AREA_KEY];if(!e)return;Array.from(e).forEach((e=>{var t=$(e).children("li.k-item");Array.from(t).forEach((e=>{var t=$(e);if(!t.hasClass("trv-report-pager")){var n=t.attr("aria-label"),r=u(". {0}",[q.ariaLabelExpandable]),a=t.find("ul").length>0&&n.indexOf(r)<0?r:"",i=u(". {0}",[q.ariaLabelSelected]),o=t.hasClass("k-selected")&&n.indexOf(i)<0?i:"",s=n+a+o;t.attr("aria-label",s),t.hasClass("k-disabled")?t.attr("aria-disabled","true"):t.removeAttr("aria-disabled")}}))}))}())})),{getKeyMap:function(){return i},setKeyMap:function(e){i=e,n=void 0}}}const Q={viewerInstances:[]};class ee{static bind(e,...t){const n=t[0].commands,r=t[1];ee.attachCommands(e,n,r);var a=e.find('[data-role^="telerik_ReportViewer_"]');Array.from(a).forEach((e=>{var n=$(e),r=$.fn[n.attr("data-role")];"function"==typeof r&&r.apply(n,t)}))}static attachCommands(e,t,n){var r='[data-command^="telerik_ReportViewer_"]',a="[data-target-report-viewer]"+r;e.on("click",r,(function(e){var n=$(this).attr("data-command");if(n){var r=n.substring(21),a=t[r];a&&a.enabled()&&a.exec($(this).attr("data-command-parameter")),e.preventDefault()}})),Q.CommandHandlerAttached||($(document.body).on("click",a,(function(e){var t=$(this),n=t.attr("data-command"),r=t.attr("data-target-report-viewer");if(n&&r){var a=n.substring(21),i=$(r).data("telerik_ReportViewer").commands[a];i.enabled()&&i.exec($(this).attr("data-command-parameter")),e.preventDefault()}})),Q.CommandHandlerAttached=!0),Object.entries(t).forEach((([t,r])=>{!function(e,t,n,r){if(t){var a='[data-command="telerik_ReportViewer_'+e+'"]',i='[data-target-report-viewer="'+n.selector+'"]'+a,o=r.find(a),s=$(i);$(t).on("enabledChanged",(function(e){(t.enabled()?$.fn.removeClass:$.fn.addClass).call(o.parent("li"),"k-disabled"),(t.enabled()?$.fn.removeClass:$.fn.addClass).call(s,n.disabledButtonClass)})).on("checkedChanged",(function(e){var r=o.parent("li");(t.checked()?$.fn.addClass:$.fn.removeClass).call(r,function(e){return e.hasClass("trv-menu-toggleable")?"k-selected !k-bg-primary":"k-selected"}(r)),(t.checked()?$.fn.addClass:$.fn.removeClass).call(s,n.checkedButtonClass)}))}}(t,r,n,e)}))}}const te={INTERACTIVE:"INTERACTIVE",PRINT_PREVIEW:"PRINT_PREVIEW"},ne={AUTO_SELECT:"AUTO_SELECT",FORCE_PDF_PLUGIN:"FORCE_PDF_PLUGIN",FORCE_PDF_FILE:"FORCE_PDF_FILE"},re={SINGLE_PAGE:"SINGLE_PAGE",CONTINUOUS_SCROLL:"CONTINUOUS_SCROLL"},ae={FIT_PAGE_WIDTH:"FIT_PAGE_WIDTH",FIT_PAGE:"FIT_PAGE",SPECIFIC:"SPECIFIC"},ie={INTEGER:"System.Int64",FLOAT:"System.Double",STRING:"System.String",DATETIME:"System.DateTime",BOOLEAN:"System.Boolean"},oe={COMBO_BOX:"COMBO_BOX",LIST_VIEW:"LIST_VIEW"},se={RIGHT:"RIGHT",LEFT:"LEFT",TOP:"TOP",BOTTOM:"BOTTOM"},le={RIGHT:"RIGHT",LEFT:"LEFT"};function ce(e){var t=!0,n=!1,r={enabled:function(e){if(0===arguments.length)return t;var n=Boolean(e);return t=n,$(this).trigger("enabledChanged"),r},checked:function(e){if(0===arguments.length)return n;var t=Boolean(e);return n=t,$(this).trigger("checkedChanged"),r},exec:e};return r}var ue={};ue[ae.FIT_PAGE]={scaleMode:ae.FIT_PAGE_WIDTH},ue[ae.FIT_PAGE_WIDTH]={scaleMode:ae.SPECIFIC,scale:1},ue[ae.SPECIFIC]={scaleMode:ae.FIT_PAGE};var de=[.1,.25,.5,.75,1,1.5,2,4,8];function fe(e){var t=e.controller;if(!t)throw"No options.controller.";var n=e.history;if(!n)throw"No options.history.";return{historyBack:new ce((function(){n.back()})),historyForward:new ce((function(){n.forward()})),stopRendering:new ce((function(){t.stopRendering()})),goToPrevPage:new ce((function(){t.navigateToPage(t.getCurrentPageNumber()-1)})),goToNextPage:new ce((function(){t.navigateToPage(t.getCurrentPageNumber()+1)})),goToFirstPage:new ce((function(){t.navigateToPage(1)})),goToLastPage:new ce((function(){t.navigateToPage(t.getPageCount())})),goToPage:new ce((function(e){if(!isNaN(e)){var n=t.getPageCount();return e>n?e=n:e<1&&(e=1),t.navigateToPage(e),e}})),refresh:new ce((function(){t.refreshReport(!0)})),export:new ce((function(e){e&&t.exportReport(e)})),print:new ce((function(){t.printReport()})),pageMode:new ce((function(){t.setPageMode(t.getPageMode()===re.SINGLE_PAGE?re.CONTINUOUS_SCROLL:re.SINGLE_PAGE)})),togglePrintPreview:new ce((function(){t.setViewMode(t.getViewMode()===te.PRINT_PREVIEW?te.INTERACTIVE:te.PRINT_PREVIEW)})),toggleDocumentMap:new ce((function(){var e;t.setDocumentMapVisible({visible:(e={},t.getDocumentMapState(e),!Boolean(e.visible))})})),toggleParametersArea:new ce((function(){var e;t.setParametersAreaVisible({visible:(e={},t.getParametersAreaState(e),!Boolean(e.visible))})})),zoom:new ce((function(e){t.setScale(e)})),zoomIn:new ce((function(){r(1)})),zoomOut:new ce((function(){r(-1)})),toggleSideMenu:new ce((function(){var e;t.setSideMenuVisible({visible:(e={},t.getSideMenuVisible(e),!Boolean(e.visible))})})),toggleZoomMode:new ce((function(e){var n=t.getScale(),r=t.getScaleMode();t.setScale(ue[r].scale||n),t.setScaleMode(ue[r].scaleMode)})),toggleSearchDialog:new ce((function(){var e;t.setSearchDialogVisible({visible:(e={},t.getSearchDialogState(e),!Boolean(e.visible))})})),toggleSendEmailDialog:new ce((function(){var e;t.setSendEmailDialogVisible({visible:(e={},t.getSendEmailDialogState(e),!Boolean(e.visible))})}))};function r(e){t.setScale(function(e,t){for(var n=-1,r=de.length,a=0;a<r;a++){var i=de[a];if(e<i){n=a-.5;break}if(e===i){n=a;break}}n+=t,n=t>=0?Math.round(n-.49):Math.round(n+.49);n<0?n=0:n>r-1&&(n=r-1);return de[n]}(t.getScale(),e))}}function he(){return{hasPdfPlugin:function(){return null!==(e=null,$.each(["AcroPDF.PDF.1","PDF.PdfCtrl.6","PDF.PdfCtrl.5"],(function(t,n){try{if(e=new ActiveXObject(n))return!1}catch(e){}})),e);var e}}}function pe(){return{hasPdfPlugin:function(){return function(){var e=/Firefox[\/\s](\d+\.\d+)/.exec(navigator.userAgent);if(null!==e&&e.length>1&&parseFloat(e[1])>=19)return!1;var t=navigator.mimeTypes["application/pdf"],n=null!==t?t.enabledPlugin:null;if(n){var r=n.description;return-1!==r.indexOf("Adobe")&&(-1===r.indexOf("Version")||parseFloat(r.split("Version")[1])>=6)}return!1}()}}}function ge(e){return{hasPdfPlugin:function(){return t=navigator.plugins,n=!1,$.each(t,(function(r,a){if(t[r].name===e||"Adobe Acrobat"===t[r].name)return n=!0,!1})),n;var t,n}}}var me=function(){if(window.navigator){var e=window.navigator.userAgent.toLowerCase();return e.indexOf("msie")>-1||e.indexOf("mozilla")>-1&&e.indexOf("trident")>-1?he():e.indexOf("firefox")>-1?pe():e.indexOf("edg/")>-1?ge("Microsoft Edge PDF Plugin"):e.indexOf("chrome")>-1?ge("Chrome PDF Viewer"):e.indexOf("safari")>-1?ge("WebKit built-in PDF"):{hasPdfPlugin:function(){return!1}}}return null}(),ve=!!me&&me.hasPdfPlugin(),Ee=function(){var e;function t(){return window.navigator&&window.navigator.msSaveOrOpenBlob}var n=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)?function(e){window.open(e,"_self")}:function(n){var r=null;if(e||((e=document.createElement("iframe")).style.display="none",e.onload=function(){try{e.contentDocument.execCommand("print",!0,null)}catch(e){k(e)}finally{r&&(window.URL||window.webkitURL).revokeObjectURL(r)}}),function(e){var t=window.location,n=document.createElement("a");n.setAttribute("href",e),""==n.host&&(n.href=n.href);return t.hostname===n.hostname&&t.protocol===n.protocol&&t.port===n.port}(n)&&t())return e.src=n,void document.body.appendChild(e);var a=new XMLHttpRequest;a.open("GET",n,!0),a.responseType="arraybuffer",a.onload=function(n){if(200===this.status){var a=new Blob([this.response],{type:"application/pdf"});t()?window.navigator.msSaveOrOpenBlob(a):(r=(window.URL||window.webkitURL).createObjectURL(a),e.src=r,document.body.appendChild(e))}else console.log("Could not retrieve remote PDF document.")},a.send()};return{print:function(e){n(e)},getDirectPrintState:function(){return ve}}}(),be=function(){var e={};function t(e,t,n,r){var a=[].concat(t).map((function(t){return function(e,t,n){if(e.availableValues){if(!Array.from(e.availableValues).some((function(e){return n(t,e.value)}))){if(e.allowNull&&!t)return t;throw q.invalidParameter}}return t}(e,n(t),r)}));if(e.multivalue){if(null==t||0==t.length){if(e.allowNull)return t;throw q.invalidParameter}return a}return a[0]}function n(e,t){return e.allowNull&&-1!=[null,"",void 0].indexOf(t)}return e[ie.STRING]={validate:function(e,n){return t(e,n,(function(t){if(!t){if(e.allowNull)return null;if(e.allowBlank)return"";throw q.parameterIsEmpty}return t}),(function(e,t){return e==t}))}},e[ie.FLOAT]={validate:function(e,r){return t(e,r,(function(t){var r=h(t);if(isNaN(r)){if(n(e,t))return null;throw q.parameterIsEmpty}return r}),(function(e,t){return h(e)==h(t)}))}},e[ie.INTEGER]={validate:function(e,r){return t(e,r,(function(t){var r=f(t);if(isNaN(r)){if(n(e,t))return null;throw q.parameterIsEmpty}return r}),(function(e,t){return f(e)==h(t)}))}},e[ie.DATETIME]={validate:function(e,n){return t(e,n,(function(t){if(e.allowNull&&(null===t||""===t||void 0===t))return null;if(!isNaN(Date.parse(t)))return e.availableValues?t:p(t);throw q.invalidDateTimeValue}),(function(e,t){return e=p(e),t=p(t),e.getTime()==t.getTime()}))}},e[ie.BOOLEAN]={validate:function(e,r){return t(e,r,(function(t){if(-1!=["true","false"].indexOf(String(t).toLowerCase()))return Boolean(t);if(n(e,t))return null;throw q.parameterIsEmpty}),(function(e,t){return Boolean(e)==Boolean(t)}))}},{validate:function(t,n){var r=e[t.type];if(!r)throw u(q.cannotValidateType,t);return r.validate(t,n)}}}();function Pe(e){return 1e3*e}function Te(e,t,n){if(!e)throw q.noServiceClient;if("number"!=typeof(r=n)||!isFinite(r))throw"sessionTimeoutSeconds must a number and must be finite";var r,a,i;function o(){i<=0||(a=setInterval((function(){e.keepClientAlive(t)}),i))}function s(){a&&(clearInterval(a),a=null)}return i=n<=120?Pe(n)/2:Pe(n-60),{start:o,restart:function(){s(),o()},stop:s}}var Se=Object.defineProperty,_e=(e,t,n)=>(((e,t,n)=>{t in e?Se(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);class Ce extends EventTarget{constructor(){super(),_e(this,"_events"),_e(this,"_eventsCount"),this._events={},this._eventsCount=0}addListener(e,t){if("function"!=typeof t)throw new TypeError("listener must be a function");function n(e){t.call(this,e,...e.detail)}return this._events[e]||(this._events[e]=[]),n.listener=t,this._events[e].push(n),this._eventsCount++,this.addEventListener(e,n.bind(this)),this}on(e,t){return this.addListener(e,t)}trigger(e,...t){if(!this._events[e])return;const n=new CustomEvent(e,{detail:t,cancelable:!0});return this.dispatchEvent(n)}emit(e,...t){return this.trigger(e,...t)}removeListener(e,t){return this._events[e]?(this._events[e]=this._events[e].filter((n=>n.listener!==t||(this.removeEventListener(e,n),!1))),0===this._events[e].length&&(delete this._events[e],this._eventsCount--),this):this}removeAllListeners(e){return void 0===e?(Object.keys(this._events).forEach((e=>{this.removeAllListeners(e)})),this):(this._events[e]&&(this._events[e].forEach((t=>{this.removeEventListener(e,t)})),delete this._events[e],this._eventsCount--),this)}off(e,t){return void 0===e?this.removeAllListeners():void 0===t?this.removeAllListeners(e):this.removeListener(e,t)}}var Ie={pagePollIntervalMs:500,documentInfoPollIntervalMs:2e3};function we(e){var t,n,r,a,i,o,s,l,c,h,p,g,m,v,E,b={},I=te.INTERACTIVE,w=re.CONTINUOUS_SCROLL,y=ne.AUTO_SELECT,N=!1,D=be,k=new Ce;H();var x=(e=$.extend({},Ie,e)).settings;"function"==typeof x.getPrintMode&&(y=x.getPrintMode());var L=e.serviceClient;if(!L)throw q.noServiceClient;function O(){t=null,a=null,F(),E=null,x.setClientId(null)}function V(){if("function"!=typeof x.getKeepClientAlive)throw new Error("Required settings.getKeepClientAlive() is not supplied for ReportViewerController");if(x.getKeepClientAlive()&&t)return L.getClientsSessionTimeoutSeconds().then((function(e){(E=new Te(L,t,e)).start()}))}function F(){x.getKeepClientAlive()&&E&&E.stop()}function G(e,t,n){var r="";if(!e.xhr)throw r=e,b.raiseError(X({responseText:r},null,null,null)),r;var a=e.xhr;_(a)&&(N=!0,b.clientExpired());var i=X(a,e.status,T(e.error)?"":e.error,t);if(b.raiseError(i),!n){if(C(a)){var o=M(a);if(o)throw o}throw a.responseJSON&&a.responseJSON.exceptionMessage?a.responseJSON.exceptionMessage:q.promisesChainStopError}}function U(){return a||(a=L.registerClient().catch((function(e){G(e,q.errorRegisteringViewer)})).then((function(e){t=e,F(),x.setClientId(t),V()})).catch(O)),a}function B(){var e,r;return i||(i=(e=s,r=l,ie(),L.createReportInstance(t,e,r).catch((function(t){G(t,u(q.errorCreatingReportInstance,[d(e)]))}))).then((function(e){n=e}))).catch((function(e){i=null})),i}function H(){r=null,n=null,i=null,z()}function z(){h=p=0}function W(e,r,a,i,o){return ie(),oe(),L.createReportDocument(t,n,e,r,a,i,o).catch((function(t){G(t,u(q.errorCreatingReportDocument,[d(s),d(e)]))}))}function j(e,t,r,a){return a.isCanceled||t!==n?Promise.reject():L.getDocumentInfo(e,t,r).catch(G).then((function(n){return n&&n.documentReady||(n.promise=new Promise((function(e,t){window.setTimeout(e,a.documentInfoPollIntervalMs)})).then((function(){return j(e,t,r,a)}))),n}))}function K(a,i,o,s){var l,c={};function u(e){a&&(r=e,a&&a.beginLoadReport(),ie(),oe(),se(),d(j(t,n,r,c)))}function d(e){e.then((function(e){e.documentReady?function(e){a&&a.onReportLoadComplete(e)}(e):(!function(e){a&&(p=e.pageCount,a.reportLoadProgress(e))}(e),d(e.promise))}))}function f(a){return new Promise((function(i,o){var s=function(){L.getPage(t,n,r,a).catch(G).then((function(t){t.pageReady?i(t):window.setTimeout(s,e.pagePollIntervalMs)}))};s()}))}function h(){if(!l){var t=I===te.PRINT_PREVIEW?"HTML5":"HTML5Interactive",n=function(){var e=Y();return e.ContentOnly=!0,e.UseSVG=P(),e}();r={deviceInfo:n},c.documentInfoPollIntervalMs=e.pagePollIntervalMs,a&&a.beforeLoadReport(r),l=U().then(B).then((function(){return W(t,n,i,o,s)})).then(u)}var r;return l}return{beginLoad:function(){h()},beginGetPage:function(t){ie(),h().then((function(){return function(e){a&&a.beginLoadPage(e)}(t),f(t)})).then((function(t){c.documentInfoPollIntervalMs=e.documentInfoPollIntervalMs,a&&a.pageReady(t)}))},getPageData:function(e){return ie(),h().then((function(){return f(e)}))},dispose:function(){a=null},cancel:function(){c.isCanceled=!0}}}function Y(){var e={};x.getEnableAccessibility()&&(e.enableAccessibility=!0,e.contentTabIndex=x.contentTabIndex);var t={};b.getSearchDialogState(t);var n=t.visible,r=!x.getSearchMetadataOnDemand()||n;return e.enableSearch=r,e}function X(e,t,n,r){var a,i=A(e.responseText),o="";if(i){var s=R(i.exceptionType||i.error,a="InvalidParameterException","Telerik.Reporting.Services.Engine."+a)?q.missingOrInvalidParameter:"";if(s)return s;o=d(i.message);var l=d(i.exceptionMessage||i.error_description);l&&(o?o+=" "+l:o=l)}else o=d(e.responseText);return(r||n)&&(o&&(o=" "+o),o=d(r||n)+o),_(e)&&(o+="<br />"+q.clientExpired),o}function J(){le();var e={ImmediatePrint:!0},t={deviceInfo:e,handled:!1};if(b.printStarted(t),!t.handled){b.setUIState({operationName:"PrintInProgress",inProgress:!0}),b.showNotification({stringResources:"preparingPrint"});var n="response-content-disposition="+(function(){switch(y){case ne.FORCE_PDF_FILE:case!1:return!1;case ne.FORCE_PDF_PLUGIN:case!0:return!0;default:return Ee.getDirectPrintState()}}()?"inline":"attachment");Q("PDF",e).then((function(e){var t=L.formatDocumentUrl(e.clientId,e.instanceId,e.documentId,n),r={url:t,handled:!1};b.printReady(r),b.hideNotification(),b.setUIState({operationName:"PrintInProgress",inProgress:!1}),r.handled||Ee.print(t)}))}}function Z(e){le(),e.deviceInfo||(e.deviceInfo=Y());var r={deviceInfo:e.deviceInfo,handled:!1,format:e.format};b.sendEmailStarted(r);r.handled||Q(e.format,e.deviceInfo).then((function(r){var a=L.formatDocumentUrl(r.clientId,r.instanceId,r.documentId,"response-content-disposition=attachment");e.url=a,e.handled=!1,b.sendEmailReady(e),delete e.deviceInfo,e.handled||function(e,r){ie(),oe(),L.sendDocument(t,n,e,r).catch((function(e){G(e,u(q.errorSendingDocument,[d(s)]))}))}(r.documentId,e)}))}function Q(a,i){return le(),U().then(B).then((function(){return W(a,i,!0,r)})).then((function(r){return function(e,t,n,r){return new Promise((function(a,i){var o=function(r){r.then((function(r){r.documentReady?a({clientId:e,instanceId:t,documentId:n}):o(r.promise)}))};o(j(e,t,n,r))}))}(t,n,r,e)}))}function ee(e){le(),oe(),se(),ge(),b.refreshReportCore(!1,r,e)}function ie(){if(!t)throw q.controllerNotInitialized}function oe(){if(!n)throw q.noReportInstance}function se(){if(!r)throw q.noReportDocument}function le(){if(!s)throw q.noReport}function ce(e,t){return"function"==typeof t[0]?k.on(e,t[0]):k.trigger(e,...t),b}function ue(e,t){if(e)for(var n=0,r=e.length;n<r;n++){var a=e[n];if(a.id===t)return a.page;var i=ue(a.items,t);if(i)return i}return null}function de(e){fe(e),b.reportSourceChanged()}function fe(e){"function"==typeof x.setReportSource&&x.setReportSource(e)}t=x.getClientId(),V();var he={sorting:function(e){ee(e.Id)},toggleVisibility:function(e){ee(e.Id)},navigateToReport:function(e){var t,n,r=e.Value;ge(),b.setReportSource({report:r.Report,parameters:(t=r.ParameterValues,n={},Array.isArray(t)&&t.forEach((function(e){n[e.Key]=e.Value})),n)}),b.refreshReport(!1)},navigateToUrl:function(e){var t=e.Value;window.open(t.Url,t.Target)},navigateToBookmark:function(e){var t=e.Value,n=ue(m,t);b.navigateToPage(n,{type:"bookmark",id:t})},customAction:function(e){}};function pe(e){var t=e.action,n=he[t.Type];"function"==typeof n&&window.setTimeout((function(){!function(e){b.interactiveActionExecuting(e)}(e),e.cancel||n(t)}),0)}function ge(){b.serverActionStarted()}function me(e){if(!S(e.xhr))throw G(e,null,!0),null;throw A(e.xhr.responseText).exceptionMessage}return b.Events={ERROR:"error",EXPORT_STARTED:"exportStarted",EXPORT_DOCUMENT_READY:"exportDocumentReady",PRINT_STARTED:"printStarted",PRINT_DOCUMENT_READY:"printDocumentReady",BEFORE_LOAD_PARAMETERS:"beforeLoadParameters",LOADED_REPORT_CHANGE:"loadedReportChange",BEFORE_LOAD_REPORT:"beforeLoadReport",BEGIN_LOAD_REPORT:"beginLoadReport",REPORT_LOAD_COMPLETE:"reportLoadComplete",REPORT_LOAD_PROGRESS:"reportLoadProgress",REPORT_LOAD_FAIL:"reportLoadFail",BEGIN_LOAD_PAGE:"beginLoadPage",PAGE_READY:"pageReady",VIEW_MODE_CHANGED:"viewModeChanged",PAGE_MODE_CHANGED:"pageModeChanged",PRINT_MODE_CHANGED:"printModeChanged",REPORT_SOURCE_CHANGED:"reportSourceChanged",NAVIGATE_TO_PAGE:"navigateToPage",CURRENT_PAGE_CHANGED:"currentPageChanged",GET_DOCUMENT_MAP_STATE:"trv.GET_DOCUMENT_MAP_STATE",SET_DOCUMENT_MAP_VISIBLE:"trv.SET_DOCUMENT_MAP_VISIBLE",GET_PARAMETER_AREA_STATE:"trv.GET_PARAMETER_AREA_STATE",SET_PARAMETER_AREA_VISIBLE:"trv.SET_PARAMETER_AREA_VISIBLE",SCALE_CHANGED:"scaleChanged",SCALE_MODE_CHANGED:"scaleModeChanged",SERVER_ACTION_STARTED:"serverActionStarted",SET_TOGGLE_SIDE_MENU:"trv.SET_TOGGLE_SIDE_MENU",GET_TOGGLE_SIDE_MENU:"trv.GET_TOGGLE_SIDE_MENU",UPDATE_UI:"trv.UPDATE_UI",CSS_LOADED:"cssLoaded",RELOAD_PARAMETERS:"reloadParameters",INTERACTIVE_ACTION_EXECUTING:"interactiveActionExecuting",INTERACTIVE_ACTION_ENTER:"interactiveActionEnter",INTERACTIVE_ACTION_LEAVE:"interactiveActionLeave",UPDATE_UI_INTERNAL:"trv.UPDATE_UI_INTERNAL",CLIENT_EXPIRED:"clientExpired",TOOLTIP_OPENING:"tooltipOpening",TOOLTIP_CLOSING:"tooltipClosing",PAGE_NUMBER:"trv.PAGE_NUMBER",PAGE_COUNT:"trv.PAGE_COUNT",GET_SEARCH_DIALOG_STATE:"trv.GET_SEARCH_DIALOG_STATE",GET_SEND_EMAIL_DIALOG_STATE:"trv.GET_SEND_EMAIL_DIALOG_STATE",SET_SEARCH_DIALOG_VISIBLE:"trv.SET_SEARCH_DIALOG_VISIBLE",SET_SEND_EMAIL_DIALOG_VISIBLE:"trv.SET_SEND_EMAIL_DIALOG_VISIBLE",SEND_EMAIL_STARTED:"sendEmailStarted",SEND_EMAIL_READY:"sendEmailDocumentReady",SHOW_NOTIFICATION:"trv.SHOW_NOTIFICATION",HIDE_NOTIFICATION:"trv.HIDE_NOTIFICATION",UI_STATE:"trv.UI_STATE",SCROLL_PAGE_READY:"scrollPageReady",UPDATE_SCROLL_PAGE_DIMENSIONS_READY:"trv.UPDATE_SCROLL_PAGE_DIMENSIONS_READY",MISSING_OR_INVALID_PARAMETERS:"missingOrInvalidParameters",RENDERING_STOPPED:"renderingStopped"},$.extend(b,{getPageData:function(e){if(g)return g.getPageData(e)},getReportSource:function(){return null===s?null:{report:s,parameters:$.extend({},l)}},setReportSource:function(e){return null===e?(s=l=null,H(),de(e),this):(s=e.report,l=e.parameters,de(e),this)},updateSettings:function(t){e.settings=$.extend({},t,e.settings)},clearReportSource:function(){return s=l=null,H(),de(void 0),this},getReportDocumentId:function(){return r},setReportDocumentId:function(e){r=e},setParameters:function(e){l=e},setProcessedParameter:function(e){c=e},getPageCount:function(){return p},getCurrentPageNumber:function(){return h},setCurrentPageNumber:function(e){var t,n=f(e);return n!==h&&(h=n,t=n,x.setPageNumber(t),b.currentPageChanged()),this},getScale:function(){return x.getScale()},setScale:function(e){return x.getScale()!==e&&(x.setScale(e),b.scaleChanged(e),b.setScaleMode(ae.SPECIFIC)),b},getScaleMode:function(){return x.getScaleMode()},setScaleMode:function(e){return x.getScaleMode()!==e&&(x.setScaleMode(e),b.scaleModeChanged(e)),b},getViewMode:function(){return I},setViewMode:function(e){return I!==e&&(I=e,b.viewModeChanged(e),s&&b.refreshReportCore(!1,r)),b},getPageMode:function(){return w},setPageMode:function(e){return w!==e&&(w=e,b.pageModeChanged(e),s&&b.refreshReportCore(!1,r)),b},getPrintMode:function(){return y},setPrintMode:function(e){return y!==e&&(y=e,b.printModeChanged(e)),b},previewReport:function(e,t,n){b.loadedReportChange(),b.refreshReportCore(e,t,n)},refreshReportCore:function(e,t,n){!function(e,t,n){s?(g&&(g.dispose(),g=null),H(),(g=new K(b,!e,t,n)).beginLoad()):b.raiseError(q.noReport)}(e,t,n)},stopRendering:function(){le(),oe(),se(),L.deleteReportDocument(t,n,r).catch(G).then((function(){g&&g.cancel(),z(),b.renderingStopped()}))},getReportParameters:function(){var e={};for(var t in c){var n=c[t],r=l[t];n&&n.availableValues?n.multivalue?e[t]=Ae(n,r,t):e[t]=Re(n,r,t):e[t]=r}return e},refreshReport:function(e,t,n){if(b.loadedReportChange(),N&&(N=!1,O()),s){var r=b.loadParameters(null);r.then((function(r){var a={},i=[],o=!1;Array.from(r||[]).forEach((e=>{try{var t=D.validate(e,e.value);a[e.id]=t}catch(t){return o=!0,void i.push(e)}})),o?(b.raiseError(q.missingOrInvalidParameter),function(e){for(var t=document.querySelector(".trv-pages-area .trv-error-message"),n=document.createElement("ul"),r=0;r<e.length;r++){var a=document.createElement("li");a.classList.add(e[r].name),a.innerText=u("{0} ({1})",[e[r].text,e[r].name]),n.appendChild(a)}t.appendChild(n)}(i),b.missingOrInvalidParameters()):(b.setParameters(a),b.refreshReportCore(e,t,n))})),b.reloadParameters(r)}else b.raiseError(q.noReport)},exportReport:function(e,t){!function(e,t){le(),t||(t=Y());var n={format:e,deviceInfo:t,handled:!1};b.exportStarted(n),n.handled||(b.setUIState({operationName:"ExportInProgress",inProgress:!0}),b.showNotification({stringResources:"preparingDownload"}),Q(e,n.deviceInfo).then((function(t){var n=L.formatDocumentUrl(t.clientId,t.instanceId,t.documentId,"response-content-disposition=attachment"),r={url:n,format:e,handled:!1,windowOpenTarget:"_self"};b.exportReady(r),b.hideNotification(),b.setUIState({operationName:"ExportInProgress",inProgress:!1}),r.handled||window.open(n,r.windowOpenTarget)})))}(e,t)},sendReport:function(e){Z(e)},printReport:function(){J()},getReportPage:function(e){var t;t=e,g&&g.beginGetPage(t)},executeReportAction:function(e){pe(e)},reportActionEnter:function(e){!function(e){b.interactiveActionEnter({action:e.action,element:e.element})}(e)},reportActionLeave:function(e){!function(e){b.interactiveActionLeave({action:e.action,element:e.element})}(e)},reportToolTipOpening:function(e){!function(e){b.toolTipOpening(e)}(e)},loadParameters:function(e){return null===s?{}:(b.beforeLoadParameters(null===e),function(e,n){return U().then((function(){return L.getParameters(t,e,n||l||{}).catch((function(e){G(e,q.unableToGetReportParameters)}))}))}(s,e))},getDocumentFormats:function(){return v?Promise.resolve(v):(o||(o=L.getDocumentFormats().catch(G)),o)},getServiceVersion:function(){return L.getServiceVersion().catch(G)},setAuthenticationToken:function(e){L.setAccessToken(e)},clientId:function(){return t},onReportLoadComplete:function(e){p=e.pageCount,m=e.bookmarkNodes,v=e.renderingExtensions,fe(b.getReportSource()),b.reportLoadComplete(e)},raiseError:function(...e){var t=function(e){var t=e.length;return 1===t?e[0]:t>1?u(e[0],Array.prototype.slice.call(e,1)):""}(e);b.error(t)},getSearchResults:function(e,a){return function(e){return e.searchToken&&""!==e.searchToken?L.getSearchResults(t,n,r,e.searchToken,e.matchCase,e.matchWholeWord,e.useRegex).catch(me):Promise.resolve(null)}(e)},on:function(e,t){return k.on(e,t),b},trigger:function(e,...t){return k.trigger(e,...t),b},showNotification:function(...e){return ce(b.Events.SHOW_NOTIFICATION,e)},hideNotification:function(...e){return ce(b.Events.HIDE_NOTIFICATION,e)},setUIState:function(...e){return ce(b.Events.UI_STATE,e)},error:function(...e){return ce(b.Events.ERROR,e)},reloadParameters:function(...e){return ce(b.Events.RELOAD_PARAMETERS,e)},exportStarted:function(...e){return ce(b.Events.EXPORT_STARTED,e)},exportReady:function(...e){return ce(b.Events.EXPORT_DOCUMENT_READY,e)},sendEmailStarted:function(...e){return ce(b.Events.SEND_EMAIL_STARTED,e)},sendEmailReady:function(...e){return ce(b.Events.SEND_EMAIL_READY,e)},printStarted:function(...e){return ce(b.Events.PRINT_STARTED,e)},printReady:function(...e){return ce(b.Events.PRINT_DOCUMENT_READY,e)},beforeLoadParameters:function(...e){return ce(b.Events.BEFORE_LOAD_PARAMETERS,e)},loadedReportChange:function(...e){return ce(b.Events.LOADED_REPORT_CHANGE,e)},beforeLoadReport:function(...e){return ce(b.Events.BEFORE_LOAD_REPORT,e)},beginLoadReport:function(...e){return ce(b.Events.BEGIN_LOAD_REPORT,e)},reportLoadComplete:function(...e){return ce(b.Events.REPORT_LOAD_COMPLETE,e)},reportLoadProgress:function(...e){return ce(b.Events.REPORT_LOAD_PROGRESS,e)},reportLoadFail:function(...e){return ce(b.Events.REPORT_LOAD_FAIL,e)},beginLoadPage:function(...e){return ce(b.Events.BEGIN_LOAD_PAGE,e)},pageReady:function(...e){return ce(b.Events.PAGE_READY,e)},viewModeChanged:function(...e){return ce(b.Events.VIEW_MODE_CHANGED,e)},pageModeChanged:function(...e){return ce(b.Events.PAGE_MODE_CHANGED,e)},printModeChanged:function(...e){return ce(b.Events.PRINT_MODE_CHANGED,e)},reportSourceChanged:function(...e){return ce(b.Events.REPORT_SOURCE_CHANGED,e)},navigateToPage:function(...e){return ce(b.Events.NAVIGATE_TO_PAGE,e)},currentPageChanged:function(...e){return ce(b.Events.CURRENT_PAGE_CHANGED,e)},getDocumentMapState:function(...e){return ce(b.Events.GET_DOCUMENT_MAP_STATE,e)},setDocumentMapVisible:function(...e){return ce(b.Events.SET_DOCUMENT_MAP_VISIBLE,e)},getParametersAreaState:function(...e){return ce(b.Events.GET_PARAMETER_AREA_STATE,e)},setParametersAreaVisible:function(...e){return ce(b.Events.SET_PARAMETER_AREA_VISIBLE,e)},setSideMenuVisible:function(...e){return ce(b.Events.SET_TOGGLE_SIDE_MENU,e)},getSideMenuVisible:function(...e){return ce(b.Events.GET_TOGGLE_SIDE_MENU,e)},scaleChanged:function(...e){return ce(b.Events.SCALE_CHANGED,e)},scaleModeChanged:function(...e){return ce(b.Events.SCALE_MODE_CHANGED,e)},serverActionStarted:function(...e){return ce(b.Events.SERVER_ACTION_STARTED,e)},cssLoaded:function(...e){return ce(b.Events.CSS_LOADED,e)},interactiveActionExecuting:function(...e){return ce(b.Events.INTERACTIVE_ACTION_EXECUTING,e)},interactiveActionEnter:function(...e){return ce(b.Events.INTERACTIVE_ACTION_ENTER,e)},interactiveActionLeave:function(...e){return ce(b.Events.INTERACTIVE_ACTION_LEAVE,e)},updateUI:function(...e){return ce(b.Events.UPDATE_UI,e)},updateUIInternal:function(...e){return ce(b.Events.UPDATE_UI_INTERNAL,e)},toolTipOpening:function(...e){return ce(b.Events.TOOLTIP_OPENING,e)},pageNumberChange:function(...e){return ce(b.Events.PAGE_NUMBER,e)},pageCountChange:function(...e){return ce(b.Events.PAGE_COUNT,e)},getSearchDialogState:function(...e){return ce(b.Events.GET_SEARCH_DIALOG_STATE,e)},getSendEmailDialogState:function(...e){return ce(b.Events.GET_SEND_EMAIL_DIALOG_STATE,e)},setSearchDialogVisible:function(...e){return ce(b.Events.SET_SEARCH_DIALOG_VISIBLE,e)},setSendEmailDialogVisible:function(...e){return ce(b.Events.SET_SEND_EMAIL_DIALOG_VISIBLE,e)},scrollPageReady:function(...e){return ce(b.Events.SCROLL_PAGE_READY,e)},updatePageDimensionsReady:function(...e){return ce(b.Events.UPDATE_SCROLL_PAGE_DIMENSIONS_READY,e)},missingOrInvalidParameters:function(...e){return ce(b.Events.MISSING_OR_INVALID_PARAMETERS,e)},renderingStopped:function(...e){return ce(b.Events.RENDERING_STOPPED,e)},clientExpired:function(...e){return ce(b.Events.CLIENT_EXPIRED,e)},dispose:function(){F(),this.serviceClientSentinel=null}}),b}function Re(e,t,n){try{var r=e.availableValues.find((e=>e.value===t));if(!r)throw new Error(`The available values of parameter ${n} do not contain Value property that equals ${t}`);return{valueMember:t,displayMember:r.name}}catch(e){k(e)}}function Ae(e,t,n){var r=[];for(var a in t)r.push(Re(e,t[a],n));return r}const Me={EXPORT_BEGIN:"EXPORT_BEGIN",EXPORT_END:"EXPORT_END",PRINT_BEGIN:"PRINT_BEGIN",PRINT_END:"PRINT_END",RENDERING_BEGIN:"RENDERING_BEGIN",RENDERING_END:"RENDERING_END",PAGE_READY:"PAGE_READY",ERROR:"ERROR",UPDATE_UI:"UPDATE_UI",INTERACTIVE_ACTION_EXECUTING:"INTERACTIVE_ACTION_EXECUTING",INTERACTIVE_ACTION_ENTER:"INTERACTIVE_ACTION_ENTER",INTERACTIVE_ACTION_LEAVE:"INTERACTIVE_ACTION_LEAVE",VIEWER_TOOLTIP_OPENING:"VIEWER_TOOLTIP_OPENING",SEND_EMAIL_BEGIN:"SEND_EMAIL_BEGIN",SEND_EMAIL_END:"SEND_EMAIL_END"};function ye(e){var t=e.controller;if(!t)throw"No controller (telerikReporting.reportViewerController) has been specified.";var n=e.settings,r=n.getHistory()||{records:[],position:-1};function a(){var e=r.records;return e.length>0?e[r.position]:null}function i(){n.setHistory(r)}function o(e){!function(){var e=r.records.length-1;for(;e>=0&&!0===r.records[e].temp;)r.records.splice(e,1),r.position>=e&&r.position--,e--}();var n,o,s,l=a(),c=t.getReportSource();l&&E(l.reportSource,c)||(n={reportSource:c,pageNumber:1,temp:e},o=r.records,s=r.position,(o=Array.prototype.slice.call(o,0,s+1)).push(n),r.records=o,r.position=o.length-1,i())}function s(e){t.setReportDocumentId(e.reportDocumentId),t.setViewMode(e.viewMode),t.setReportSource(e.reportSource),t.refreshReport(!1,e.reportDocumentId),t.navigateToPage(e.pageNumber)}function l(e){var t=r.position,n=r.records.length,a=t+e;return 0<=a&&a<n}function c(e){var t=r.position,n=r.records.length,o=t+e;o<0?o=0:o>=n&&(o=n-1),o!=t&&(r.position=o,i(),s(a()))}return t.loadedReportChange((function(){o(!0)})).currentPageChanged((function(){var e;(e=a())&&(e.pageNumber=t.getCurrentPageNumber(),e.viewMode=t.getViewMode(),e.reportDocumentId=t.getReportDocumentId(),i())})).reportLoadComplete((function(e,t){o(!1)})).clientExpired((function(){for(var e=r.records,t=0;t<e.length;t++)e[t].reportDocumentId=null})),{back:function(){c(-1)},forward:function(){c(1)},canMoveBack:function(){return l(-1)},canMoveForward:function(){return l(1)},loadCurrent:function(){var e=a();return e&&s(e),Boolean(e)}}}function Ne(e,t){var n,r;function a(e,n){var r=t[e];"function"==typeof r&&r(n)}!function(e){if("function"==typeof $.fn.kendoTouch)try{$(e).mousedown((function(){r=!0})).mouseup((function(){r=!1})).kendoTouch({multiTouch:!0,enableSwipe:!0,swipe:function(e){r||function(e){a("swipe",e)}(e)},gesturestart:function(e){r||function(e){n=kendo.touchDelta(e.touches[0],e.touches[1]).distance}(e)},gestureend:function(e){},gesturechange:function(e){r||function(e){var t=kendo.touchDelta(e.touches[0],e.touches[1]).distance;(function(e){a("pinch",e)})({distance:t,lastDistance:n}),n=t}(e)},doubletap:function(e){r||function(e){a("doubletap",e)}(e)},touchstart:function(e){r||a("touchstart")}})}catch(e){throw console.error("Instantiation of Kendo Touch threw an exception",e),e}}(e)}var De={controller:{},$placeholder:null,$pageContainer:null,pageContainer:null,$pageWrapper:null,pageWrapper:null,viewMode:null,loadedPage:{},scrollInProgress:!1,enabled:!1,pageCount:0,additionalTopOffset:130,pageDistance:20,oldScrollTopPosition:0,skeletonTemplate:'<div class="trv-report-page trv-skeleton-page trv-skeleton-{0}" style="{1}" data-page="{0}"><div class="trv-skeleton-wrapper" style="{2}"></div></div>',init:function(e,t){var n=this;n.$placeholder=$("[data-selector='"+t.viewerSelector+"']").find(e),n.$pageContainer=this.$placeholder.find(".trv-page-container"),n.pageContainer=this.$pageContainer[0],n.$pageWrapper=this.$placeholder.find(".trv-page-wrapper"),n.pageWrapper=this.$pageWrapper[0],n.controller=t.controller,n.viewMode=null,n.loadedPage={},n.scrollInProgress=!1,n.enabled=!1,n.pageCount=0,n.controller.scaleChanged((function(e,t){n.enabled&&setTimeout((function(){n._loadMorePages(),n._keepCurrentPageInToView()}),100)})).loadedReportChange((function(e){n.enabled&&(n.disable(),"loadedReportChange"!==e.type&&setTimeout((function(){n.controller.getPageData(1).then((function(e){n.renderPage(e)}))})))})).viewModeChanged((function(e){n.enabled&&n.disable()})).interactiveActionExecuting((function(e,t){var r=t.action.Type;!n.enabled||"sorting"!==r&&"toggleVisibility"!==r||n.disable()})).updatePageDimensionsReady((function(e,t){n.enabled&&n._currentPageNumber()>0&&n._keepCurrentPageInToView()})).pageCountChange((function(e,t){n.enabled&&n.pageCount!==t&&(n._currentPageNumber()>0&&!n.scrollInProgress&&n._loadMorePages(),t>1&&n._initEvents(),n.pageCount=t)}))},isEnabled:function(){return this.enabled},disable:function(){this.$pageWrapper.empty(),this.enabled=!1,this.loadedPage={},this.pageCount=0,this.$placeholder.removeClass("scrollable"),this._unbind()},enable:function(){this.enabled=!0,this.$placeholder.addClass("scrollable"),this._initEvents()},renderPage:function(e){var t=this,n=t.controller.getViewMode(),r=t.$placeholder.find('[data-page="'+e.pageNumber+'"]');t.enabled?(n===t.viewMode&&r.length?t._navigateToPage(e,r):t._updatePageArea(e),t.viewMode=t.controller.getViewMode()):(t.enabled=!0,t.$placeholder.addClass("scrollable"),n===t.viewMode&&r.length?(t._render(e,!0),this.$pageContainer.scrollTop(3),t._setCurrentPage(e.pageNumber)):t._updatePageArea(e),t.viewMode=t.controller.getViewMode(),t._loadMorePages())},navigateToElement:function(e,t){var n=this;n.scrollInProgress=!0,n._isSkeletonScreen(null,t)?n.controller.getPageData(t).then((function(r){n._render(r,!1),n.$pageContainer.animate({scrollTop:e},500,(function(){n._setCurrentPage(t),setTimeout((function(){n.scrollInProgress=!1}),100)}))})):n.$pageContainer.animate({scrollTop:e},500,(function(){n._setCurrentPage(t),setTimeout((function(){n.scrollInProgress=!1}),100)}))},_setCurrentPage:function(e){var t=this;e!==t._currentPageNumber()&&t.controller.setCurrentPageNumber(e),t.controller.getPageCount()>1&&(t.$placeholder.find(".k-state-default").removeClass("k-state-default"),t.$placeholder.find('[data-page="'+e+'"]').addClass("k-state-default")),t._loadNextPreviousPage(e)},_updatePageArea:function(e){var t=this,n=0,r=e.pageNumber;t.scrollInProgress=!0,r>1&&t._generateSkeletonScreens(r),t._render(e,!1),t._setCurrentPage(e.pageNumber),setTimeout((function(){n=r>1?t.$placeholder.find('[data-page="'+r+'"]').position().top:0,t.$pageContainer.animate({scrollTop:n},0,(function(){t.scrollInProgress=!1}))}),100)},_navigateToPage:function(e,t){var n=this;n.scrollInProgress=!0;var r=t.position().top,a=n.$placeholder.find(".trv-report-page"),i=e.pageNumber;$(a[0]).height(),n._isSkeletonScreen(t,i)?n.controller.getPageData(i).then((function(e){n._render(e,!1),n.$pageContainer.animate({scrollTop:r},500,(function(){setTimeout((function(){n._setCurrentPage(e.pageNumber),n.scrollInProgress=!1}))}))})):(n._updatePageContent(e,t),n.$pageContainer.animate({scrollTop:r},500,(function(){setTimeout((function(){n._setCurrentPage(e.pageNumber),n.scrollInProgress=!1}))})))},_updatePageContent:function(e,t){this._updatePageStyle(e);var n=e.pageNumber,r=$($.parseHTML(e.pageContent)).find("div.sheet"),a=this.$placeholder.find('[data-page="'+n+'"]');r.css("margin",0),a.append(r).append($('<div class="trv-page-overlay"></div>')),t.replaceWith(a),this.controller.scrollPageReady({page:e,target:a})},_currentPageNumber:function(){return this.controller.getCurrentPageNumber()},_isSkeletonScreen:function(e,t){return e||(e=this.$placeholder.find('[data-page="'+t+'"]')),e.hasClass("trv-skeleton-"+t)},_addSkeletonScreen:function(e,t){var n=this,r=t?parseInt(e+1):parseInt(e-1),a=n.$placeholder.find('[data-page="'+r+'"]'),i=a.attr("style"),o=a.find("sheet").attr("style"),s=u(n.skeletonTemplate,[e,i,o]);t?n.$pageWrapper.prepend(s):n.$pageWrapper.append(s)},_generateSkeletonScreens:function(e){for(var t=this,n="",r=this.$placeholder.find('[data-page="1"]'),a=r.attr("style"),i=r.find("sheet").attr("style"),o=t.$placeholder.find(".trv-report-page").last().attr("data-page"),s=o?parseInt(o)+1:1;s<e;s++)n+=u(t.skeletonTemplate,[s,a,i]);t.$pageWrapper.append($(n))},_loadMorePages:function(){var e=this,t=e.controller.getPageCount(),n=e.$pageContainer.innerHeight()>e.$pageWrapper.innerHeight();if(t>1)if(n){e.scrollInProgress=!0;var r=parseInt(e.$placeholder.find(".trv-report-page").last().attr("data-page"))+1;r<=t&&e.controller.getPageData(r).then((function(t){e._render(t,!1),e._loadMorePages(),e.scrollInProgress=!1}))}else e._loadVisiblePages(),e.scrollInProgress=!1},_loadVisiblePages:function(){var e=this,t=e.$placeholder.find(".trv-report-page");Array.from(t).forEach((t=>{var n=$(t),r=parseInt(n.attr("data-page"));e._scrolledInToView(n)&&e._isSkeletonScreen(n,r)&&e.controller.getPageData(r).then((t=>{e._render(t,!1)}))}))},_scrolledInToView:function(e){var t=e[0].getBoundingClientRect(),n=e.closest(".trv-pages-area")[0].getBoundingClientRect(),r=n.top,a=n.top+n.height,i=t.top,o=i+e.outerHeight(!0),s=this.additionalTopOffset+r;return i>0&&i<a||o<a&&o>s},_render:function(e,t){var n=this,r=e.pageNumber,a=n.$placeholder.find('[data-page="'+r+'"]');if(t||!a||!a.length||n._isSkeletonScreen(a,r)){n.loadedPage[r]=e,n._updatePageStyle(e);var i=$($.parseHTML(e.pageContent)).find("div.sheet"),o=$('<div class="trv-report-page" data-page="'+r+'"></div>');i.css("margin",0),o.append(i).append($('<div class="trv-page-overlay"></div>')),t&&n.$pageWrapper.empty(),n.$pageWrapper.removeData().data("pageNumber",r);var s=n.$placeholder.find(".trv-skeleton-"+r);s.length?s.replaceWith(o):n.$pageWrapper.append(o),n.controller.scrollPageReady({page:e,target:o})}},_updatePageStyle:function(e){var t,n=this,r=n.loadedPage[n._lastLoadedPage()]||e,a="trv-"+n.controller.clientId()+"-styles";$("#"+a).remove(),(t=$("<style id="+a+"></style>")).append(r.pageStyles),t.appendTo("head")},_lastLoadedPage:function(){var e;for(var t in this.loadedPage)this.loadedPage.hasOwnProperty(t)&&(e=t);return e},_loadNextPreviousPage:function(e){var t,n,r,a,i=this;e<i.controller.getPageCount()&&(t=e+1,r=i.$placeholder.find('[data-page="'+t+'"]')),e>1&&(n=e-1,a=i.$placeholder.find('[data-page="'+n+'"]')),a&&a.length&&i._isSkeletonScreen(a,n)&&i.controller.getPageData(n).then((function(e){i._render(e,!1)})),r&&r.length&&i._isSkeletonScreen(r,t)&&i.controller.getPageData(t).then((function(e){i._render(e,!1)}))},_clickPage:function(e){var t=this,n=t._currentPageNumber(),r=parseInt(e.attr("data-page"));n!==r&&(t._isSkeletonScreen(e,r)?t.controller.getPageData(r).then((function(e){t._render(e,!1,!0),t._setCurrentPage(e.pageNumber)})):t._setCurrentPage(r))},_initEvents:function(){var e=this;e.$pageContainer.off("click",".trv-report-page").on("click",".trv-report-page",(function(t){e._clickPage($(t.currentTarget))})),e.$pageContainer.scroll((function(){var t=e.$placeholder.find(".trv-report-page"),n=parseInt((e.$pageContainer.scrollTop()+e.$pageContainer.innerHeight()).toFixed(0));e.scrollInProgress||e.oldScrollTopPosition===n||(e.oldScrollTopPosition>n?e._scrollUp(t):e._scrollDown(t,n)),e.oldScrollTopPosition=n})),e.$pageContainer.scroll((function(){var t=e.$placeholder.find(".trv-report-page"),n=parseInt((e.$pageContainer.scrollTop()+e.$pageContainer.innerHeight()).toFixed(0));!e.scrollInProgress&&t.length&&e.oldScrollTopPosition!==n&&e._advanceCurrentPage(t)}))},_unbind:function(){this.$pageContainer.off("click",".trv-report-page"),this.$pageContainer.off("scroll")},_advanceCurrentPage:function(e){var t,n=this,r=n._findNewCurrentPage(e),a=n._currentPageNumber(),i=n._scrolledInToView(n.$placeholder.find('[data-page="'+a+'"]'));-1!==r?(r=$(r),a===(t=parseInt(r.attr("data-page")))||i||(n._isSkeletonScreen(r,t)?n.controller.getPageData(t).then((function(e){n._render(e,!1,!0),n._setCurrentPage(e.pageNumber)})):n._setCurrentPage(t))):console.log("Page not found - ",r)},_findNewCurrentPage:function(e){var t=this,n=Math.floor(e.length/2),r=t._findPageInViewPort(n,e);return 1===e.length?e[0]:0===r?e[n]:r<0&&e.length>1?t._findNewCurrentPage(e.splice(n,Number.MAX_VALUE)):r>0&&e.length>1?t._findNewCurrentPage(e.splice(0,n)):-1},_findPageInViewPort:function(e,t){var n=this.$placeholder.find(t[e]),r=n[0].getBoundingClientRect(),a=n.closest(".trv-pages-area")[0].getBoundingClientRect(),i=a.top;a.top,a.height;var o=r.top,s=o+n.outerHeight(!0),l=this.additionalTopOffset+i;return o<=l&&l<s?0:s<l?-1:1},_scrollDown:function(e,t){var n=this;if(t>=n.pageContainer.scrollHeight-5){var r=parseInt($(e[e.length-1]).attr("data-page"))+1;n._currentPageNumber()<r&&r<=n.controller.getPageCount()&&(n._addSkeletonScreen(r,!1),n.controller.getPageData(r).then((function(e){n._render(e,!1)})))}else n._advanceCurrentPage(e),n._loadVisiblePages()},_scrollUp:function(e){var t=this;if(0===t.$pageContainer.scrollTop()){var n=$(e[0]),r=parseInt(n.attr("data-page"))-1;t._currentPageNumber()>r&&r>=1&&(t._addSkeletonScreen(r,!0),t.controller.getPageData(r).then((function(e){t._render(e,!1),t.$pageContainer.scrollTop(3)})))}else t._advanceCurrentPage(e),t._loadVisiblePages()},_keepCurrentPageInToView:function(){var e=this,t=e.$placeholder.find('[data-page="'+e._currentPageNumber()+'"]'),n=t.position().top,r=t.innerHeight(),a=e.$pageContainer.innerHeight();e.scrollInProgress=!0,r<a&&(n=parseInt(n-(a-r)/2)),e.$pageContainer.animate({scrollTop:n},0,(function(){setTimeout((function(){e.scrollInProgress=!1}),100)}))}},$e={$placeholder:null,$scrollableContainer:null,itemsInitialState:{},xFrozenAreasBounds:{},yFrozenAreasBounds:{},freezeMaxZIndex:{},zIndex:1,freezeBGColor:{},currentlyFrozenContainer:{vertical:{},horizontal:{}},isInitialize:!1,scaleFactor:null,init:function(e){this.$placeholder=e,this.$scrollableContainer=e.find(".trv-page-container"),this.isInitialize&&this.reset(e),this._attachToScrollEvent(),this.isInitialize=!0},reset:function(e){this.$placeholder=e,this.$scrollableContainer=e.find(".trv-page-container"),this.itemsInitialState={},this.xFrozenAreasBounds={},this.yFrozenAreasBounds={},this.currentlyfreezedContainer={vertical:{},horizontal:{}}},setScaleFactor:function(e){this.scaleFactor=e},_attachToScrollEvent:function(){var e=this;this.$scrollableContainer.scroll((function(){var t=e.$scrollableContainer.find("div[data-sticky-id]");if(t.length)for(var n=t.map((function(e,t){return $(t).attr("data-sticky-id")})).get(),r=n.filter((function(e,t){return t===n.indexOf(e)})),a=e.$scrollableContainer.scrollTop(),i=e.$scrollableContainer.scrollLeft(),o=0;o<r.length;o++){var s=r[o];e.itemsInitialState[s]||e._saveFreezeItemsInitialState(s),e._updateFreezeItemsOnScroll(s,a,i)}}))},_saveFreezeItemsInitialState:function(e){var t,n,r=$("[data-sticky-direction][data-sticky-id='"+e+"']"),i=$("[data-reporting-action][data-sticky-id='"+e+"']");this.itemsInitialState[e]={},this.freezeBGColor[e]=$("[data-id='"+e+"']").attr("data-sticky-bg-color");for(var o=0;o<r.length;o++){var s=$(r[o]),l=s.attr("data-sticky-direction"),c=s.attr("data-id"),u=s.position(),d={top:u.top/this.scaleFactor,left:u.left/this.scaleFactor},f=a(d.left,d.top,s.outerWidth(!0)*this.scaleFactor,s.outerHeight(!0)*this.scaleFactor);switch(l){case"Vertical":t=t?t.union(f):f;break;case"Horizontal":n=n?n.union(f):f}this._saveFreezeItemInitialState(e,s,c,d)}this.freezeMaxZIndex[e]=i.length?i.css("zIndex"):this.zIndex,this.yFrozenAreasBounds[e]=t,this.xFrozenAreasBounds[e]=n},_saveFreezeItemInitialState:function(e,t,n,r){var a=t.css("background-color"),i=this._hasSetBgColor(a),o={top:r.top,left:r.left,zIndex:t.css("zIndex"),hasBgColor:i};this.itemsInitialState[e][n]=o},_updateFreezeItemsOnScroll:function(e,t,n){var r=$("div[data-id='"+e+"']");if(this._isInScrollVisibleArea(r)){var a=r.closest(".trv-report-page"),i=a.position(),o=parseFloat(a.css("margin-top")),s=parseFloat(a.css("padding-top")),l=parseFloat(a.css("padding-left")),c=parseFloat(a.css("border-top-width")),u=parseFloat(a.css("border-left-width")),d=$("[data-sticky-direction*='Horizontal'][data-sticky-id='"+e+"']"),f=$("[data-sticky-direction*='Vertical'][data-sticky-id='"+e+"']"),h=d.length>0,p=f.length>0,g=r.position(),m=g.top+i.top+o+s+c,v=g.left+l+u,E=t-m,b=n-v;p&&E>0?t<=r.outerHeight()*this.scaleFactor+m-this.yFrozenAreasBounds[e].height&&(this.currentlyFrozenContainer.vertical[e]=!0,this._updateUIElementsPosition(f,"top",E/this.scaleFactor,e)):this.currentlyFrozenContainer.vertical[e]&&(delete this.currentlyFrozenContainer.vertical[e],this._updateUIElementsPosition(f,"top",-1,e)),h&&b>0?n<=r.outerWidth()*this.scaleFactor+v-this.xFrozenAreasBounds[e].width&&(this.currentlyFrozenContainer.horizontal[e]=!0,this._updateUIElementsPosition(d,"left",b/this.scaleFactor,e)):this.currentlyFrozenContainer.horizontal[e]&&(delete this.currentlyFrozenContainer.horizontal[e],this._updateUIElementsPosition(d,"left",-1,e))}else(this.currentlyFrozenContainer.horizontal[e]||this.currentlyFrozenContainer.vertical[e])&&this._resetToDefaultPosition(e)},_resetToDefaultPosition:function(e){var t=$("[data-sticky-direction*='Horizontal'][data-sticky-id='"+e+"']"),n=$("[data-sticky-direction*='Vertical'][data-sticky-id='"+e+"']");this._updateUIElementsPosition(n,"top",-1,e),this._updateUIElementsPosition(t,"left",-1,e),delete this.currentlyFrozenContainer.horizontal[e],delete this.currentlyFrozenContainer.vertical[e]},_updateUIElementsPosition:function(e,t,n,r){for(var a=0;a<e.length;a++){var i=$(e[a]),o=i.attr("data-sticky-direction").indexOf(",")>0,s=i.attr("data-id"),l=this.itemsInitialState[r][s],c=l[t],u=l.zIndex,d=l.hasBgColor,f=1,h=this.freezeMaxZIndex[r]?this.freezeMaxZIndex[r]:f,p={"z-index":f=o?"auto"!==u?u:h+2:"auto"!==u?u+1:h};n>=0?c+=n:p["z-index"]=u,d||this._applyBgColorOnScroll(i,o,d,n>=0,r),p[t]=c+"px",i.css(p)}},_applyBgColorOnScroll:function(e,t,n,r,a){return!!e.is("img")||(t&&this._isFrozen(a)&&!n?(e.css("background-color",this.freezeBGColor[a]),!0):void(r?e.css("background-color",this.freezeBGColor[a]):e.css("background-color","initial")))},_hasSetBgColor:function(e){return O(e)>0},_isFrozen:function(e){return this.currentlyFrozenContainer.horizontal[e]||this.currentlyFrozenContainer.vertical[e]},_isInScrollVisibleArea:function(e){var t=e.closest(".trv-report-page"),n=e.position();return this._isVisibleVertically(e,t,n)&&this._isVisibleHorizontally(e,t,n)},_isVisibleHorizontally:function(e,t,n){var r=parseFloat(t.css("padding-left")),a=this.$scrollableContainer.scrollLeft(),i=this.$scrollableContainer.width(),o=e.outerWidth(!0)*this.scaleFactor,s=n.left+r;return s>a-o&&s<a+o+i},_isVisibleVertically:function(e,t,n){var r=parseFloat(t.css("padding-top")),a=t.position(),i=this.$scrollableContainer.scrollTop(),o=this.$scrollableContainer.height(),s=e.outerHeight(!0)*this.scaleFactor,l=n.top+r+a.top;return l>i-s&&l<i+s+o}},ke={};function xe(e,t,n){var r=(t=$.extend({},ke,t,n)).controller;if(!r)throw"No controller (telerikReportViewer.reportViewerController) has been specified.";var a,i,o,s,l,c,h,p,g,m=$(e),v=m.find(".trv-page-container"),E=v[0],b=m.find(".trv-page-wrapper"),P=b[0],T=m.find(".trv-error-message"),S=r.getScaleMode(),_=r.getScale(),C=.1,I=8,w=!0,R=!1,A=!1,M='.trv-page-container {background: #ffffff url("{0}") no-repeat center 50px}',y="trv-initial-image-styles",N=$.extend({},De),D=null;function k(){V(l),l=!1}function x(){return-1!==[ae.FIT_PAGE,ae.FIT_PAGE_WIDTH].indexOf(S)}function L(){for(var e=0,t=v.find(".trv-report-page"),n=t.length;e<n;e++){var a=parseInt($(t[e]).attr("data-page"));J(t[e],S,_,a)}r.updatePageDimensionsReady()}function O({scale:e,scaleMode:t}){_=e||_,S=t||S,_=Math.max(C,Math.min(I,_)),L()}function V(e){v.off("click","[data-reporting-action]",Z),v.off("mouseenter","[data-reporting-action]",Q),v.off("mouseleave","[data-reporting-action]",ee),v.off("mouseenter","[data-tooltip-title],[data-tooltip-text]",ie),v.off("mouseleave","[data-tooltip-title],[data-tooltip-text]",se),i=void 0,e&&b.empty(),Y()}function F(e){var t=v.find(".trv-report-page");return r.getPageMode()===re.SINGLE_PAGE?Array.from(t).find((t=>X(t)===e)):Array.from(t).find((t=>parseInt($(t).attr("data-page"))===e))}function G(e,t){w?function(e,t){var n=F(e);n?(t&&U(t,e),N.isEnabled()&&!t&&N.navigateToElement(n.offsetTop,e)):(i=t,function(e){K(!0),window.setTimeout(r.getReportPage.bind(r,e),1),o=null}(e))}(e,t):function(e,t){o=e,s=t}(e,t)}function U(e,n){if(e){var r=v.find("[data-"+e.type+"-id="+e.id+"]")[0];if(r){if(t.enableAccessibility){var a=j($(r));a&&a.focus()}for(var i=v[0],o=0,s=0;r&&r!==i;){if($(r).is(".trv-page-wrapper")){var l=$(r).data("pageScale");"number"==typeof l&&(o*=l,s*=l)}o+=r.offsetTop,s+=r.offsetLeft,r=r.offsetParent}N.isEnabled()&&n?N.navigateToElement(o,n):(i.scrollTop=o,i.scrollLeft=s)}else N.isEnabled()&&n&&N.navigateToElement(m.find('[data-page="'+n+'"]')[0].offsetTop,n)}}function j(e){if(!e||0===e.length)return null;var t=f(e.attr("tabindex"));return!isNaN(t)&&t>-1?e:j(e.next())}function K(e){(e?$.fn.addClass:$.fn.removeClass).call(m,"trv-loading")}function Y(e){T.text(e),(e?$.fn.addClass:$.fn.removeClass).call(m,"trv-error")}function X(e,t){var n=e.$?e:$(e),r="pageNumber";return void 0===t?n.data(r):(n.data(r,t),e)}function J(e,t,n,r){var a=$(e),i=r?a:a.find("div.trv-report-page"),o=i.find("div.sheet"),s=i.find("div.trv-skeleton-wrapper"),l=o[0]||s[0],c=s[0];if(l){var u,d,f=a.data("box");if(!f){var h=B(a),p=z(i),g=H(i);f={padLeft:h.left+p.left+g.left,padRight:h.right+p.right+g.right,padTop:h.top+p.top+g.top,padBottom:h.bottom+p.bottom+g.bottom},a.data("box",f)}void 0===a.data("pageWidth")?(u=l.offsetWidth,d=l.offsetHeight,a.data("pageWidth",u),a.data("pageHeight",d)):(u=a.data("pageWidth"),d=a.data("pageHeight"));var m=d>u&&t===ae.FIT_PAGE_WIDTH?20:0,v=(E.clientWidth-m-f.padLeft-f.padRight)/u,b=(E.clientHeight-1-f.padTop-f.padBottom)/d;t===ae.FIT_PAGE_WIDTH?n=v:n&&t!==ae.FIT_PAGE||(n=Math.min(v,b)),D&&D.setScaleFactor(n),a.data("pageScale",n),i.data("pageScale",n),c||W(o,n,n),i.css({height:n*d,width:n*u})}}function Z(e){var t=ne($(this).attr("data-reporting-action"));t&&(o=function(e,t){if(N.isEnabled()&&("sorting"===t||"toggleVisibility"===t))return $(e.target).closest(".trv-report-page").attr("data-page")||r.getCurrentPageNumber();return r.getCurrentPageNumber()}(e,t.Type),r.executeReportAction({element:e.currentTarget,action:t,cancel:!1})),e.stopPropagation()}function Q(e){var t=ne($(this).attr("data-reporting-action"));null!==t&&e.currentTarget===this&&r.reportActionEnter({element:e.currentTarget,action:t})}function ee(e){var t=ne($(this).attr("data-reporting-action"));null!==t&&e.currentTarget===this&&r.reportActionLeave({element:e.currentTarget,action:t})}function ne(e){return a?Array.from(a).find((function(t){return t.Id===e})):null}function ie(e){var n=$(this),a=n.attr("data-tooltip-title"),i=n.attr("data-tooltip-text");if(a||i){var o={element:e.currentTarget,toolTip:{title:a||"",text:i||""},cancel:!1};if(r.reportToolTipOpening(o),!o.cancel){var s,l,c,u,d=function(e){var n=t.templates["trv-pages-area-kendo-tooltip"],r=$(n),a=r.find(".trv-pages-area-kendo-tooltip-title"),i=r.find(".trv-pages-area-kendo-tooltip-text");return a.html(oe(e.toolTip.title)),i.html(oe(e.toolTip.text)),r.clone().wrap("<p>").parent().html()}(o),f=e.currentTarget.viewportElement,h=function(e,t){var n=e.data("kendoTooltip");if(!n)try{n=e.kendoTooltip({content:t,autohide:!0,callout:!1}).data("kendoTooltip")}catch(e){throw console.error("Instantiation of Kendo Tooltip threw an exception",e),e}return n}(n,d);h.show(n),f&&"svg"===f.nodeName&&(s=h,c=(l=e).pageX,u=l.pageY,s.popup.element.closest("[role=region]").css({left:c+10,top:u+5}))}}}function oe(e){return e=(e=(e=d(e)).replaceAll("\r\n","<br>")).replaceAll("\n","<br>")}function se(e){var t=$(this).data("kendoTooltip");t&&t.hide()}function le(){$("#"+y).remove()}(h=m).attr("aria-label",q[h.attr("aria-label")]),N&&N.init(e,t),$(window).on("resize",(function(e,t){x()&&L()})),Ne(m,{swipe:function(e){var t=r.getCurrentPageNumber();p&&"left"===e.direction?t<r.getPageCount()&&r.navigateToPage(t+1):g&&"right"===e.direction&&t>1&&r.navigateToPage(t-1)},pinch:function(e){var t=F(r.getCurrentPageNumber());O({scale:($(t).data("pageScale")||_)*(e.distance/e.lastDistance),scaleMode:ae.SPECIFIC})},doubletap:function(e){t.commands.toggleZoomMode.exec()},touchstart:function(e){var t=P;g=0===t.scrollLeft,p=t.scrollWidth-t.offsetWidth===t.scrollLeft}}),r.pageModeChanged((function(){r.getPageMode()===re.CONTINUOUS_SCROLL?N.enable():N.disable(),r.refreshReport(!0)})).reportSourceChanged((function(){l=!0,o=null,s=null,w=!1})).beforeLoadParameters((function(e,t){t&&Y(q.loadingReport)})).beforeLoadReport((function(){w=!1,o||(o=1),c&&window.clearTimeout(c),V(),K(!0),Y(q.loadingReport)})).beginLoadReport((function(e,t){var n;w=!0,(n=F(o))&&X(n,-1)})).reportLoadProgress((function(e,t){var n,r;n=o,r=t.pageCount,n&&n<=r&&G(n,s),Y(u(q.loadingReportPagesInProgress,[t.pageCount]))})).reportLoadComplete((function(e,t){var n,a;0===t.pageCount?(k(),Y(q.noPageToDisplay)):(n=o,a=t.pageCount,n&&G(n=Math.min(n,a),s),Y(u(q.loadedReportPagesComplete,[t.pageCount])),c=window.setTimeout(Y,2e3),v.on("click","[data-reporting-action]",Z),v.on("mouseenter","[data-reporting-action]",Q),v.on("mouseleave","[data-reporting-action]",ee),v.on("mouseenter","[data-tooltip-title],[data-tooltip-text]",ie),v.on("mouseleave","[data-tooltip-title],[data-tooltip-text]",se)),t.containsFrozenContent&&!D&&(D=$.extend({},$e),r.getViewMode()===te.INTERACTIVE&&D.init(m))})).navigateToPage((function(e,t,n){G(t,n)})).pageReady((function(e,t){r.getPageMode()===re.SINGLE_PAGE?(N.isEnabled()&&N.disable(),function(e){a=JSON.parse(e.pageActions),function(e){var t="trv-"+r.clientId()+"-styles";$("#"+t).remove();var n=$("<style id="+t+"></style>");n.append(e.pageStyles),n.appendTo("head")}(e);var t=e.pageNumber,n=$($.parseHTML(e.pageContent)),o=n.find("div.sheet"),s=$('<div class="trv-report-page" data-page="'+t+'"></div>');o.css("margin",0),s.append(o).append($('<div class="trv-page-overlay"></div>'));var l=b.empty().removeData().data("pageNumber",t).append(s);r.setCurrentPageNumber(t),r.getViewMode()===te.INTERACTIVE?(m.removeClass("printpreview"),m.addClass("interactive")):(m.removeClass("interactive"),m.addClass("printpreview"));J(l,S,_),v.scrollTop(0),v.scrollLeft(0),U(i)}(t)):N.renderPage(t),A||(A=!0),R&&le(),r.getViewMode()===te.INTERACTIVE&&D&&D.init(m),K(!1)})).error((function(e,t){K(!1),k(),Y(t)})).showNotification((function(e,t){Y(q[t.stringResources])})).hideNotification((function(e,t){Y()})).scaleChanged((function(e,t){O({scale:t,scaleMode:r.getScaleMode()})})).scaleModeChanged((function(e,t){O({scale:r.getScale(),scaleMode:t})})).serverActionStarted((function(){K(!0),Y(q.loadingReport)})).scrollPageReady((function(e,t){!function(e){var t=JSON.parse(e.page.pageActions);a=a?a.concat(t):t;r.getViewMode()===te.INTERACTIVE?(m.removeClass("printpreview"),m.addClass("interactive")):(m.removeClass("interactive"),m.addClass("printpreview"));J(e.target,S,_,e.page.pageNumber)}(t)})).missingOrInvalidParameters((function(e,n){var r;t.initialPageAreaImageUrl&&!A&&(k(),r=$("<style id="+y+"></style>"),le(),r.append(u(M,[t.initialPageAreaImageUrl])),r.appendTo("head"),R=!0)})).renderingStopped((function(){V(!0),Y(q.renderingCanceled)})),r.setDocumentMapVisible((function(){x()&&setTimeout((function(){L()}))})).setParametersAreaVisible((function(){x()&&setTimeout((function(){L()}))}))}var Le,Oe={MultiSelect:function(e,t){return Boolean(e.availableValues)&&e.multivalue&&(!t||!t.multiSelect||t.multiSelect!==oe.COMBO_BOX)},MultiSelectCombo:function(e,t){return Boolean(e.availableValues)&&e.multivalue&&t&&t.multiSelect&&t.multiSelect===oe.COMBO_BOX},SingleSelect:function(e,t){return Boolean(e.availableValues)&&!e.multivalue&&(!t||!t.singleSelect||t.singleSelect!==oe.COMBO_BOX)},SingleSelectCombo:function(e,t){return Boolean(e.availableValues)&&!e.multivalue&&t&&t.singleSelect&&t.singleSelect===oe.COMBO_BOX},MultiValue:function(e){return Boolean(e.multivalue)},DateTime:function(e){return e.type===ie.DATETIME},String:function(e){return e.type===ie.STRING},Number:function(e){switch(e.type){case ie.INTEGER:case ie.FLOAT:return!0;default:return!1}},Boolean:function(e){return e.type===ie.BOOLEAN},Default:function(e){return!0}},Ve={formatValue:function(e){var t="";return e&&[].concat(e).forEach((function(e){t.length>0&&(t+="\n"),t+=e})),t},parseValues:function(e){return(""+e).split("\n")}};function Fe(e){function t(t){return!!r(t.keyCode)||(n=$(e).val()+String.fromCharCode(t.charCode),/^(\-|\+)?([0-9]*)$/.test(n));var n}function n(e){}return $(e).on("keypress",t).on("paste",n),{dispose:function(){!function(e){$(e).off("keypress",t).off("paste",n)}(e)}}}function Ge(e){function t(t){return!!r(t.keyCode)||(n=$(e).val()+String.fromCharCode(t.charCode),/^(\-|\+)?([0-9]*(\.[0-9]*)?)$/.test(n));var n}function n(e){}return $(e).on("keypress",t).on("paste",n),{dispose:function(){!function(e){$(e).off("keypress",t).off("paste",n)}(e)}}}function Ue(e,t,n){(e?$.fn.addClass:$.fn.removeClass).call(n,t)}function Be(e,t){Ue(!t,"k-disabled",e)}function He(e,t,n,r,a){r||(r="");var i=u("{0}. {1} {2}. {3}",[n,t,q.ariaLabelParameter,r]);e.attr("aria-label",i),je(e,a)}var ze=0;function We(e){if(!Le){var t=$("div.trv-parameters-area-content");if(t.length>0){var n=t.attr("tabIndex");n&&(Le=f(n))}Le&&!isNaN(Le)||(Le=300)}var r=e.closest(".trv-parameter-value"),a=r.find(".trv-select-all"),i=r.find(".trv-select-none"),o=e.closest(".k-widget").find(".k-input"),s=o&&o.length;a&&a.length&&a.attr("tabindex",Le+ ++ze),i&&i.length&&i.attr("tabindex",Le+ ++ze),s?o.attr("tabindex",Le+ ++ze):e.attr("tabindex",Le+ ++ze)}function je(e,t){var n=u(" {0}:",[q.ariaLabelErrorMessage]),r=e.attr("aria-label");if(r){var a=r.indexOf(n);a>-1&&(r=r.substring(0,a)),t&&""!==t?(e.attr("aria-required",!0),e.attr("aria-invalid",!0),r+=n+t):e.removeAttr("aria-invalid"),e.attr("aria-label",r)}}function Ke(e){return kendo.version>="2017.3.1018"||e}var Ye=[{match:Oe.MultiSelect,createEditor:function(e,t){var n=$(e),r=!0;n.html(t.templates["trv-parameter-editor-available-values-multiselect"]);var a,i,o,s,l=n.find(".trv-list"),c=n.find(".trv-select-all"),d=n.find(".trv-select-none"),f=t.parameterChanged;function h(e){s&&(function(e){var t=l.find(".trv-listviewitem");Array.from(t).forEach((t=>{var n=$(t),r=e.filter(n).length>0;n.attr("aria-selected",r)}))}(e),function(e){var t=i.availableValues,n=$.map(e,(function(e){return t[$(e).index()].value}));g();var r=!i.autoRefresh&&!i.childParameters;o=window.setTimeout((function(){b(i.value,n)||f(i,n),o=null}),r?0:1e3)}(e))}function g(){o&&window.clearTimeout(o)}function m(){return $(a.element).find(".k-selected")}function E(e){if(r){var t=$(e.target),n=a.select();t.hasClass("k-selected")?n.splice($.inArray(t[0],n),1):n.push(t),a.clearSelection(),a.select(n),a.trigger("change")}}function P(e){h(m())}function T(e){if(r&&32===e.which){var t=a.element.find(".k-focus");t.length>0&&(t.toggleClass("k-selected"),h(m()),e.preventDefault())}}function S(e){!function(e){Array.isArray(e)||(e=[e]);var t=l.find(".trv-listviewitem");$.each(i.availableValues,((n,r)=>{var a,i,o=!1;$.each(e,((e,t)=>{var n=r.value;return t instanceof Date&&(n=p(r.value)),!(o=v(t,n))})),a=$(t[n]),Ue(i=o,"k-selected",a),a.attr("aria-selected",i)}))}(e),h(m())}return c.text(q[c.text()]),c.click((function(e){e.preventDefault(),r&&S(i.availableValues.map((function(e){return e.value})))})),d.text(q[d.text()]),d.click((function(e){e.preventDefault(),r&&S([])})),{beginEdit:function(e){s=!1,a&&(a.element.off("touch click",".trv-listviewitem",E),a.element.off("keydown",T)),i=e;try{a=l.kendoListView({template:kendo.template('<div class="trv-listviewitem" style="cursor: pointer">${name}</div>'),dataSource:{data:i.availableValues},selectable:"MULTIPLE",navigatable:Ke(t.enableAccessibility),change:P}).data("kendoListView")}catch(e){throw console.error("Instantiation of Kendo ListView as MultiSelect parameter editor threw an exception",e),e}We(l),S(i.value),a.element.off().on("touch click",".trv-listviewitem",E),a.element.on("keydown",T),s=!0},enable:function(e){Be(l,r=e)},clearPendingChange:g,addAccessibility:function(e){var t=u(q.ariaLabelParameterInfo,[e.availableValues.length]);He(l,q.ariaLabelMultiSelect,e.text,t,e.Error),l.attr("aria-multiselectable","true");var n=l.find(".trv-listviewitem");Array.from(n).forEach((e=>{$(e).attr("aria-label",e.innerText)}))},setAccessibilityErrorState:function(e){je(l,e.Error)},destroy:function(){a.destroy()}}}},{match:Oe.MultiSelectCombo,createEditor:function(e,t){var n,r,a,i,o,s,l=$(e),c=!0,d=t.parameterChanged,f=!0;function h(e){!function(e){p();var t=!s.autoRefresh&&!s.childParameters;o=window.setTimeout((function(){b(s.value,e)||d(s,e),o=null}),t?0:1e3)}(e)}function p(){o&&window.clearTimeout(o)}function g(){f&&h(i.value())}return l.html(t.templates["trv-parameter-editor-available-values-multiselect-combo"]),n=l.find(".trv-combo"),(r=l.find(".trv-select-none"))&&(r.text(q[r.text()]),r.click((function(e){e.preventDefault(),i.value([]),i.trigger("change")}))),(a=l.find(".trv-select-all"))&&(a.text(q[a.text()]),a.click((function(e){if(e.preventDefault(),c){var t=$.map(s.availableValues,(function(e){return e.value}));i.value(t),i.trigger("change")}}))),{beginEdit:function(e){i&&i.unbind("change",g),s=e;try{i=n.kendoMultiSelect({itemTemplate:'<div class="trv-editoritem">${name}</div>',dataSource:s.availableValues,dataTextField:"name",dataValueField:"value",value:s.value,filter:"contains",autoClose:!1,open:function(){f=!1},close:function(e){f=!0,g()},autoWidth:!0,clearButton:!1}).data("kendoMultiSelect")}catch(e){throw console.error("Instantiation of Kendo MultiSelect as MultiSelectCombo parameter editor threw an exception",e),e}We(n),i.bind("change",g)},enable:function(e){c=e,i.enable(e)},clearPendingChange:p,addAccessibility:function(e){var t=i.input,n=u(q.ariaLabelParameterInfo,[e.availableValues.length]);He(t,q.ariaLabelMultiSelect,e.text,n,e.Error);var r=i.items();Array.from(r).forEach((e=>{$(e).attr("aria-label",e.innerText)}))},setAccessibilityErrorState:function(e){je(n,e.Error)},destroy:function(){i.destroy()}}}},{match:Oe.SingleSelect,createEditor:function(e,t){var n=$(e),r=!0;n.html(t.templates["trv-parameter-editor-available-values"]);var a,i,o=n.find(".trv-list"),s=n.find(".trv-select-none"),l=t.parameterChanged;function c(e){!function(e){var t=i.availableValues,n=$.map(e,(function(e){return t[$(e).index()].value}));Array.isArray(n)&&(n=n[0]);l(i,n)}(e)}function d(){c(a.select())}function f(){var e,t;We(o),e=i.value,t=o.find(".trv-listviewitem"),$.each(i.availableValues,((n,r)=>{var i=r.value;return e instanceof Date&&(i=p(r.value)),!v(e,i)||(a.select(t[n]),!1)})),a.bind("change",d)}return s&&(s.text(q[s.text()]),s.click((function(e){e.preventDefault(),a.clearSelection(),a.trigger("change")}))),{beginEdit:function(e){a&&a.unbind("change",d),i=e;try{a=o.kendoListView({template:'<div class="trv-listviewitem">${name}</div>',dataSource:{data:i.availableValues},selectable:!0,navigatable:Ke(t.enableAccessibility)}).data("kendoListView")}catch(e){throw console.error("Instantiation of Kendo ListView as SingleSelect parameter editor threw an exception",e),e}f()},enable:function(e){Be(o,r=e),r?(a.bind("change",d),o.addClass("k-selectable")):(a.unbind("change",d),o.removeClass("k-selectable"))},addAccessibility:function(e){var t=u(q.ariaLabelParameterInfo,[e.availableValues.length]);He(o,q.ariaLabelSingleValue,e.text,t,e.Error);var n=o.find(".trv-listviewitem");Array.from(n).forEach((e=>{$(e).attr("aria-label",e.innerText)}))},setAccessibilityErrorState:function(e){je(o,e.Error)},destroy:function(){a.destroy()}}}},{match:Oe.SingleSelectCombo,createEditor:function(e,t){var n,r,a,i,o=$(e),s=t.parameterChanged;function l(e,t){!function(e,t){var n=t||"";!t&&e>=0&&(n=i.availableValues[e].value);s(i,n)}(e,t)}function c(e){l(a.select(),this.value())}return o.html(t.templates["trv-parameter-editor-available-values-combo"]),n=o.find(".trv-combo"),(r=o.find(".trv-select-none"))&&(r.text(q[r.text()]),r.click((function(e){e.preventDefault(),a.value(""),a.trigger("change")}))),{beginEdit:function(e){a&&a.unbind("change",c),i=e;try{a=n.kendoComboBox({template:'<div class="trv-editoritem">${name}</div>',dataSource:i.availableValues,dataTextField:"name",dataValueField:"value",value:i.value,filter:"contains",suggest:!0,clearButton:!1}).data("kendoComboBox")}catch(e){throw console.error("Instantiation of Kendo ComboBox as SingleSelectCombo parameter editor threw an exception",e),e}We(n),a.bind("change",c)},enable:function(e){a.enable(e)},addAccessibility:function(e){var t=a.input,n=u(q.ariaLabelParameterInfo,[e.availableValues.length]);He(t,q.ariaLabelSingleValue,e.text,n,e.Error);var r=a.items();Array.from(r).forEach((e=>{$(e).attr("aria-label",e.innerText)}))},setAccessibilityErrorState:function(e){je(n,e.Error)},destroy:function(){a.destroy()}}}},{match:Oe.MultiValue,createEditor:function(e,t){var n,r=$(e);r.html(t.templates["trv-parameter-editor-multivalue"]);var a=r.find("textarea").on("change",(function(){t.parameterChanged&&t.parameterChanged(n,Ve.parseValues(this.value))}));return{beginEdit:function(e){var t;n=e,t=e.value,n.value=t,a.val(Ve.formatValue(t)),We(a)},enable:function(e){Be(a,e),a.prop("disabled",!e)},addAccessibility:function(e){He(a,q.ariaLabelMultiValue,e.text,null,e.Error)},setAccessibilityErrorState:function(e){je(a,e.Error)}}}},{match:Oe.DateTime,createEditor:function(e,t){var n,r=$(e);r.html(t.templates["trv-parameter-editor-datetime"]);try{var a=r.find("input[type=datetime]").kendoDatePicker({change:function(){var e=t.parameterChanged;if(e){var r=this.value();null!==r&&(r=g(r)),e(n,r)}}}),i=a.data("kendoDatePicker")}catch(e){throw console.error("Instantiation of Kendo DatePicker as DateTime parameter editor threw an exception",e),e}return{beginEdit:function(e){n=e,function(e){n.value=e;var t=null;try{e&&(t=m(e))}catch(e){t=null}i.value(t)}(e.value),We(a)},enable:function(e){i.enable(e),Be(a,e)},addAccessibility:function(e){He(a,q.ariaLabelParameterDateTime,e.text,null,e.Error),a.attr("aria-live","assertive")},setAccessibilityErrorState:function(e){je(a,e.Error)},destroy:function(){i.destroy()}}}},{match:Oe.String,createEditor:function(e,t){var n,r=$(e);r.html(t.templates["trv-parameter-editor-text"]);var a=r.find('input[type="text"]').change((function(){t.parameterChanged&&t.parameterChanged(n,a.val())}));return{beginEdit:function(e){var t;n=e,t=e.value,n.value=t,a.val(t),We(a)},enable:function(e){a.prop("disabled",!e),Be(a,e)},addAccessibility:function(e){He(a,q.ariaLabelParameterString,e.text,null,e.Error),a.attr("aria-live","assertive")},setAccessibilityErrorState:function(e){je(a,e.Error)}}}},{match:Oe.Number,createEditor:function(e,t){var n,r,a=$(e);a.html(t.templates["trv-parameter-editor-number"]);var i=a.find("input[type=number]").on("change",(function(){t.parameterChanged&&t.parameterChanged(n,i.val())}));return{beginEdit:function(e){r&&r.dispose(),n=e,i.val(n.value),r=n.type===ie.INTEGER?Fe(i):Ge(i),We(i)},enable:function(e){i.prop("disabled",!e),Be(i,e)},addAccessibility:function(e){He(i,q.ariaLabelParameterNumerical,e.text,null,e.Error),i.attr("aria-live","assertive")},setAccessibilityErrorState:function(e){je(i,e.Error)}}}},{match:Oe.Boolean,createEditor:function(e,t){var n,r=$(e);r.html(t.templates["trv-parameter-editor-boolean"]);var a=r.find("input[type=checkbox]").on("change",(function(){t.parameterChanged&&t.parameterChanged(n,this.checked)}));return{beginEdit:function(e){var t;n=e,t=e.value,n.value=t,a[0].checked=!0===t,We(a)},enable:function(e){Be(a,e),a.attr("disabled",!e)},addAccessibility:function(e){He(a,q.ariaLabelParameterBoolean,e.text,null,e.Error),a.attr("aria-live","assertive")},setAccessibilityErrorState:function(e){je(a,e.Error)}}}},{match:Oe.Default,createEditor:function(e,t){var n=$(e);return n.html('<div class="trv-parameter-editor-generic"></div>'),{beginEdit:function(e){n.find(".trv-parameter-editor-generic").text(e.Error?"(error)":e.value)},enable:function(e){}}}}];function Xe(e,t){var n,r=!!e.querySelectorAll&&e.querySelectorAll(".trv-menu-small")[0],a={small:{documentMapVisible:!1,parametersAreaVisible:!1,onDocumentMapVisibleChanged:function(e,n){n.visible&&t.setParametersAreaVisible({visible:!1})},onParameterAreaVisibleChanged:function(e,n){n.visible&&t.setDocumentMapVisible({visible:!1})},onBeforeLoadReport:function(){t.setParametersAreaVisible({visible:!1}),t.setDocumentMapVisible({visible:!1})},onNavigateToPage:function(){t.setParametersAreaVisible({visible:!1}),t.setDocumentMapVisible({visible:!1})}},large:{documentMapVisible:!0,parametersAreaVisible:!0}};function i(e){var t,r=p();if(r!==n){var i=a[n],o=a[r];n=r,e&&e.call(void 0,i,o),m((t=o).documentMapVisible),v(t.parametersAreaVisible)}}function o(e,t){h("onDocumentMapVisibleChanged",arguments)}function s(e,t){h("onParameterAreaVisibleChanged",arguments)}function l(){h("onBeforeLoadReport",arguments)}function c(){h("onNavigateToPage",arguments)}function u(){h("onReportLoadComplete",arguments)}function d(){i((function(e,t){g(e)}))}function f(){i(null)}function h(e,t){var r=a[n],i=r[e];"function"==typeof i&&i.apply(r,t)}function p(){var e=$(window).width()/parseFloat($("body").css("font-size"));return r&&e<=40.5?"small":"large"}function g(e){e.documentMapVisible=m(),e.parametersAreaVisible=v()}function m(){if(0===arguments.length){var e={};return t.getDocumentMapState(e),e.visible}return t.setDocumentMapVisible({visible:Boolean(arguments[0])}),this}function v(){if(0===arguments.length){var e={};return t.getParametersAreaState(e),e.visible}return t.setParametersAreaVisible({visible:Boolean(arguments[0])}),this}return n=p(),g(a.large),{attach:function(){window.addEventListener("resize",d),t.setDocumentMapVisible(o),t.setParametersAreaVisible(s),t.beforeLoadReport(l),t.navigateToPage(c),t.reportLoadComplete(u),t.cssLoaded(f)},dispose:function(){window.removeEventListener("resize",d)}}}var qe=Object.defineProperty,Je=Object.getOwnPropertySymbols,Ze=Object.prototype.hasOwnProperty,Qe=Object.prototype.propertyIsEnumerable,et=(e,t,n)=>t in e?qe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,tt=(e,t)=>{for(var n in t||(t={}))Ze.call(t,n)&&et(e,n,t[n]);if(Je)for(var n of Je(t))Qe.call(t,n)&&et(e,n,t[n]);return e},nt="application/json; charset=UTF-8",rt="application/x-www-form-urlencoded; charset=UTF-8",at="GET",it="POST",ot="DELETE",st={};function lt(e){const t={Accept:"application/json, text/javascript, */*; q=0.01"};return e&&(t.Authorization="Bearer "+e),t}function ct(e){var t,n=c((e=$.extend({},st,e)).serviceUrl||e.baseUrl,"\\/"),r=V;function a(e){if(!e)throw"Invalid clientID"}function i(){if(!t){var n=e.loginInfo;if(n&&n.url&&(n.username||n.password)){const e=n.url;t=r(e,{method:it,data:{grant_type:"password",username:n.username,password:n.password},dataType:"json",contentType:rt}).then((function(e){return e.access_token}))}else t=Promise.resolve()}return t}return{_urlFromTemplate:function(e,t){return u(e,t=$.extend({},{baseUrl:n},t))},registerClient:function(e){const t=`${n}/clients`;return i().then((function(n){return r(t,tt({headers:lt(n),method:it,dataType:"json",data:JSON.stringify({timeStamp:Date.now()})},e))})).then((function(e){if(e.Message)throw e.Message;return e.clientId}))},unregisterClient:function(e,t){a(e);const o=`${n}/clients/${e}`;return i().then((function(e){return r(o,tt({headers:lt(e),method:ot},t))}))},getParameters:function(e,t,o,s){a(e);const l=`${n}/clients/${e}/parameters`;return i().then((function(e){return r(l,tt({headers:lt(e),method:it,contentType:nt,dataType:"json",data:JSON.stringify({report:t,parameterValues:o})},s))}))},createReportInstance:function(e,t,o,s){a(e);const l=`${n}/clients/${e}/instances`;return i().then((function(e){return r(l,tt({headers:lt(e),method:it,contentType:nt,dataType:"json",data:JSON.stringify({report:t,parameterValues:o})},s))})).then((function(e){return e.instanceId}))},deleteReportInstance:function(e,t,o){a(e);const s=`${n}/clients/${e}/instances/${t}`;return i().then((function(e){return r(s,tt({headers:lt(e),method:ot},o))}))},createReportDocument:function(e,t,o,s,l,c,u,d){a(e);const f=`${n}/clients/${e}/instances/${t}/documents`;return i().then((function(e){return(s=s||{}).BasePath=n,r(f,tt({headers:lt(e),method:it,contentType:nt,dataType:"json",data:JSON.stringify({format:o,deviceInfo:s,useCache:l,baseDocumentID:c,actionID:u})},d))})).then((function(e){return e.documentId}))},sendDocument:function(e,t,o,s,l){a(e);const c=`${n}/clients/${e}/instances/${t}/documents/${o}/send`;return i().then((function(e){return r(c,tt({headers:lt(e),method:it,contentType:nt,data:JSON.stringify({from:s.from,to:s.to,cc:s.cc,subject:s.subject,body:s.body})},l))}))},deleteReportDocument:function(e,t,o,s){a(e);const l=`${n}/clients/${e}/instances/${t}/documents/${o}`;return i().then((function(e){return r(l,tt({headers:lt(e),method:ot},s))}))},getDocumentInfo:function(e,t,o,s){a(e);const l=`${n}/clients/${e}/instances/${t}/documents/${o}/info`;return i().then((function(e){return r(l,tt({headers:lt(e),method:at,dataType:"json"},s))}))},getPage:function(e,t,o,s,l){a(e);const c=`${n}/clients/${e}/instances/${t}/documents/${o}/pages/${s}`;return i().then((function(e){return r(c,tt({headers:lt(e),method:at,dataType:"json"},l))}))},get:function(e){return r(e,{method:at})},formatDocumentUrl:function(e,t,r,a){var i=`${n}/clients/${e}/instances/${t}/documents/${r}`;return a&&(i+="?"+a),i},getDocumentFormats:function(e){const t=`${n}/formats`;return i().then((function(n){return r(t,tt({headers:lt(n),method:at,dataType:"json"},e))}))},getServiceVersion:function(e){const t=`${n}/version`;return i().then((function(n){return r(t,tt({headers:lt(n),method:at,dataType:"json"},e))}))},getResource:function(e,t,o,s,l){a(e);const c=`${n}/clients/${e}/instances/${t}/documents/${o}/resources/${s}`;return i().then((function(e){return r(c,tt({headers:lt(e),method:at,dataType:(null==l?void 0:l.dataType)||"json"},l))}))},getSearchResults:function(e,t,o,s,l,c,u,d){a(e);const f=`${n}/clients/${e}/instances/${t}/documents/${o}/search`;return i().then((function(e){return r(f,tt({headers:lt(e),method:it,contentType:nt,dataType:"json",data:JSON.stringify({searchToken:s,matchCase:l,matchWholeWord:c,useRegularExpressions:u})},d))}))},setAccessToken:function(e){t=Promise.resolve(e)},login:i,keepClientAlive:function(e,t){const a=`${n}/clients/keepAlive/${e}`;return i().then((function(e){return r(a,tt({headers:lt(e),method:it},t))}))},getClientsSessionTimeoutSeconds:function(e){const t=`${n}/clients/sessionTimeout`;return i().then((function(n){return r(t,tt({headers:lt(n),method:at},e))})).then((function(e){return e.clientSessionTimeout}))}}}function ut(e){var t={ExportInProgress:1,PrintInProgress:2,RenderInProgress:4};function n(e){return!!(s&e)}function r(e,t){t?s|=e:s&=~e}var a,i=e.controller,o=e.history,s=0,l=e.commands;if(!i)throw"No controller (telerikReporting.ReportViewerController) has been specified.";function c(){a||(a=!0,window.setTimeout((function(){try{e=i.getReportSource(),r=i.getPageCount(),s=i.getCurrentPageNumber(),c=e&&e.report,d=(u=c&&r>0)&&s<r,f=u&&s>1,h=u&&s,T={},i.getDocumentMapState(T),p=T,g=function(){var e={};return i.getParametersAreaState(e),e}(),m=function(){var e={};return i.getSearchDialogState(e),e}(),v=function(){var e={};return i.getSendEmailDialogState(e),e}(),E=n(t.RenderInProgress),b=n(t.PrintInProgress),P=n(t.ExportInProgress),l.goToFirstPage.enabled(f),l.goToPrevPage.enabled(f),l.stopRendering.enabled(c&&E),l.goToLastPage.enabled(d),l.goToNextPage.enabled(d),l.goToPage.enabled(u),l.print.enabled(u&&!E&&!b),l.export.enabled(u&&!E&&!P),l.refresh.enabled(c),l.historyBack.enabled(o&&o.canMoveBack()),l.historyForward.enabled(o&&o.canMoveForward()),l.toggleDocumentMap.enabled(c&&p.enabled).checked(p.enabled&&p.visible),l.toggleParametersArea.enabled(c&&g.enabled).checked(g.enabled&&g.visible),l.togglePrintPreview.enabled(u).checked(i.getViewMode()==te.PRINT_PREVIEW),l.pageMode.enabled(u).checked(i.getPageMode()==re.CONTINUOUS_SCROLL),l.zoom.enabled(h),l.zoomIn.enabled(h),l.zoomOut.enabled(h),l.toggleZoomMode.enabled(h).checked(i.getScaleMode()==ae.FIT_PAGE||i.getScaleMode()==ae.FIT_PAGE_WIDTH),l.toggleSearchDialog.enabled(u).checked(m.visible),l.toggleSendEmailDialog.enabled(u).checked(v.visible),i.updateUI(null),i.pageNumberChange(s),i.pageCountChange(r)}finally{a=!1}var e,r,s,c,u,d,f,h,p,g,m,v,E,b,P,T}),10))}i.setParametersAreaVisible(c),i.setDocumentMapVisible(c),i.updateUIInternal(c),i.setSearchDialogVisible(c),i.setSendEmailDialogVisible(c),i.scaleModeChanged(c),i.currentPageChanged(c),i.beforeLoadReport((function(){r(t.RenderInProgress,!0),c()})),i.reportLoadProgress(c),i.reportLoadComplete((function(){r(t.RenderInProgress,!1),c()})),i.reportSourceChanged(c),i.viewModeChanged(c),i.pageModeChanged((function(){c()})),i.setUIState((function(e,n){r(t[n.operationName],n.inProgress),c()})),i.error((function(){r(t.ExportInProgress,!1),r(t.PrintInProgress,!1),r(t.RenderInProgress,!1),c()})),i.renderingStopped((function(){r(t.RenderInProgress,!1),c()})),c()}var dt={};var ft,ht,pt={},gt="pa.parametersReady",mt="pa.Error";var vt={};function Et(e){if(e){var t,n=e.find(".trv-search-dialog-caption-label"),r=e.find(".trv-search-dialog-search-options"),a=e.find("a[data-command='telerik_ReportViewer_searchDialog_StopSearch']"),i=e.find("a[data-command='telerik_ReportViewer_searchDialog_MatchCase']"),o=e.find("a[data-command='telerik_ReportViewer_searchDialog_MatchWholeWord']"),s=e.find("a[data-command='telerik_ReportViewer_searchDialog_UseRegex']"),l=e.find("a[data-command='telerik_ReportViewer_searchDialog_NavigateUp']"),c=e.find("a[data-command='telerik_ReportViewer_searchDialog_NavigateDown']");Pt(e,"aria-label"),Pt(r,"aria-label"),(t=n)&&t.text(q[t.text()]),bt(a),bt(i),bt(o),bt(s),bt(l),bt(c)}}function bt(e){Pt(e,"title"),Pt(e,"aria-label")}function Pt(e,t){e&&e.attr(t,q[e.attr(t)])}var Tt={};function St(e){if(e){var t=e.find(".trv-replace-string"),n=e.find("[aria-label]"),r=e.find("[title]");t.length&&Array.from(t).forEach((e=>{var t;(t=$(e))&&t.text(q[t.text()])})),n.length&&Array.from(n).forEach((e=>{_t($(e),"aria-label")})),r.length&&Array.from(r).forEach((e=>{_t($(e),"title")}))}}function _t(e,t){e&&e.attr(t,q[e.attr(t)])}var Ct=Object.defineProperty,It=(e,t,n)=>(((e,t,n)=>{t in e?Ct(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);class wt{constructor(){It(this,"_data",{}),this._data={}}get length(){return Object.keys(this._data).length}getItem(e){return this._data[e]||null}setItem(e,t){this._data[e]=t}removeItem(e){delete this._data[e]}key(e){return Object.keys(this._data)[e]||null}clear(){this._data={}}}const Rt=(At={},{load:function(e,t,n){var r=At[e];return r||(At[e]=r=n.get(e).then((function(e){var n={},r=[],a=c(t,"\\/")+"/";e=s(e,"{service}/",a),e=s(e,"{service}",a);var i=$("<div></div>").html(e);return Array.from(i.find("template")).forEach((e=>{var t=$(e);n[t.attr("id")]=o(t.html(),"\n \t")})),Array.from(i.find("link")).forEach((e=>{r.push(o(e.outerHTML,"\n \t"))})),r=D(r),{templates:n,styleSheets:r}}))),r}});var At,Mt=Object.defineProperty,yt=(e,t,n)=>(((e,t,n)=>{t in e?Mt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);class Nt{constructor(e,t,n){yt(this,"_id"),yt(this,"_storage"),yt(this,"_defaults"),this._id=e,this._storage=t,this._defaults=n||{}}formatKey(e){return this._id+"_"+e}getItem(e){var t=this._storage.getItem(this.formatKey(e));if("string"==typeof t)try{t=JSON.parse(t)}catch(e){t=null}return null!=t?t:this._defaults[e]}setItem(e,t){var n=this.formatKey(e);this._storage.setItem(n,JSON.stringify(t))}getViewMode(){return this.getItem("viewMode")}setViewMode(e){this.setItem("viewMode",e)}getPageMode(){return this.getItem("pageMode")}setPageMode(e){this.setItem("pageMode",e)}getPrintMode(){return this.getItem("printMode")}setPrintMode(e){this.setItem("printMode",e)}getScale(){return this.getItem("scale")}setScale(e){this.setItem("scale",e)}getScaleMode(){return this.getItem("scaleMode")}setScaleMode(e){this.setItem("scaleMode",e)}getDocumentMapVisible(){return this.getItem("documentMapVisible")}setDocumentMapVisible(e){this.setItem("documentMapVisible",e)}getParametersAreaVisible(){return this.getItem("parametersAreaVisible")}setParametersAreaVisible(e){this.setItem("parametersAreaVisible",e)}getHistory(){return this.getItem("history")}setHistory(e){this.setItem("history",e)}getClientId(){return this.getItem("clientId")}setClientId(e){this.setItem("clientId",e)}getReportSource(){return this.getItem("reportSource")}setReportSource(e){this.setItem("reportSource",e)}getPageNumber(){return this.getItem("pageNumber")}setPageNumber(e){this.setItem("pageNumber",e)}getEnableAccessibility(){return this.getItem("enableAccessibility")}setEnableAccessibility(e){this.setItem("enableAccessibility",e)}getAccessibilityKeyMap(){return this.getItem("accessibilityKeyMap")}setAccessibilityKeyMap(e){this.setItem("accessibilityKeyMap",e)}getSearchMetadataOnDemand(){return this.getItem("searchMetadataOnDemand")}setSearchMetadataOnDemand(e){this.setItem("searchMetadataOnDemand",e)}getKeepClientAlive(){return this.getItem("keepClientAlive")}setKeepClientAlive(e){this.setItem("keepClientAlive",e)}}var Dt=Object.defineProperty,$t=(e,t,n)=>(((e,t,n)=>{t in e?Dt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);class kt{constructor(e,t){$t(this,"element"),$t(this,"$element"),$t(this,"options"),this.element=e,this.$element=$(e),this.options=t}}var xt=Object.defineProperty,Lt=(e,t,n)=>(((e,t,n)=>{t in e?xt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);var Ot=Object.defineProperty,Vt=(e,t,n)=>(((e,t,n)=>{t in e?Ot(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);const Ft=Q.viewerInstances;function Gt(e,t){var n=t.serviceUrl,r="";t.reportServer&&(r=c(t.reportServer.url,"\\/"),n=r+"/api/reports");var a,o,s,l=$(e),f={},h=t.id||`trv_${e.id}`,p={},g={},m={},v={},E={},b={},P="";if(t.viewerSelector="reportViewer-"+i(),l.attr("data-selector",t.viewerSelector),function(e){if(!e)return l.text("The report viewer configuration options are not initialized."),!1;if(e.reportServer){if(!e.reportServer.url)return l.text("The report server URL is not specified."),!1}else if(!e.serviceUrl)return l.text("The serviceUrl is not specified."),!1;return!0}(t)){var T,S="18.1.24.709";if(t=$.extend({},function(e,t){return{id:null,serviceUrl:null,templateUrl:c(e,"\\/")+"/resources/templates/telerikReportViewerTemplate-"+t+".html/",reportSource:null,reportServer:null,authenticationToken:null,sendEmail:null,scale:1,scaleMode:ae.FIT_PAGE,viewMode:te.INTERACTIVE,pageMode:re.CONTINUOUS_SCROLL,parametersAreaPosition:se.RIGHT,documentMapAreaPosition:le.LEFT,parameters:{editors:{multiSelect:oe.LIST_VIEW,singleSelect:oe.LIST_VIEW}},persistSession:!1,parameterEditors:[],disabledButtonClass:null,checkedButtonClass:null,parametersAreaVisible:!0,documentMapVisible:!0,enableAccessibility:!1,searchMetadataOnDemand:!1,initialPageAreaImageUrl:null,keepClientAlive:!0}}(n,S),t),p=new Nt(h,t.persistSession?window.sessionStorage:new wt,{scale:t.scale,scaleMode:t.scaleMode,printMode:t.printMode?t.printMode:t.directPrint,enableAccessibility:t.enableAccessibility,searchMetadataOnDemand:t.searchMetadataOnDemand,sendEmail:t.sendEmail,parametersAreaPosition:t.parametersAreaPosition,documentMapAreaPosition:t.documentMapAreaPosition,keepClientAlive:t.keepClientAlive}),t.reportServer?(P=c(t.reportServer.url,"\\/"),b.serviceUrl=P+"/api/reports",b.loginInfo={url:P+"/Token",username:t.reportServer.username,password:t.reportServer.password}):b.serviceUrl=t.serviceUrl,o=new ct(b),(g=t.controller)?g.updateSettings(p):g=new we({serviceClient:o,settings:p}),s=new ye({controller:g,settings:p}),v=new fe({controller:g,history:s}),new ut({controller:g,history:s,commands:v}),E={stringResources:q,refreshReport:function(e){return 0===arguments.length&&(e=!0),g.refreshReport(e),E},reportSource:function(e){return e||null===e?(g.setReportSource(e),g.refreshReport(!1),E):g.getReportSource()},clearReportSource:function(){return g.clearReportSource(),E},viewMode:function(e){return e?(g.setViewMode(e),E):g.getViewMode()},pageMode:function(e){return e?(g.setPageMode(e),E):g.getPageMode()},printMode:function(e){return e?(g.setPrintMode(e),E):g.getPrintMode()},scale:function({scale:e,scaleMode:t}={}){return e||t?(g.setScale(e||g.getScale()),g.setScaleMode(t||g.getScaleMode()),E):{scale:g.getScale(),scaleMode:g.getScaleMode()}},currentPage:function(){return g.getCurrentPageNumber()},pageCount:function(){return g.getPageCount()},parametersAreaVisible:function(e){g.setParametersAreaVisible({visible:e})},getReportParameters:function(){return g.getReportParameters()},authenticationToken:function(e){return e&&g.setAuthenticationToken(e),E},bind:function(e,t){_(e,t,!0)},unbind:function(e,t){_(e,t,!1)},accessibilityKeyMap:function(e){if(a)return e?(a.setKeyMap(e),E):a.getKeyMap()},commands:v,dispose:function(){g.dispose(),m&&m.dispose()}},!window.Promise)throw"The current browser does not support the Promise feature which is required for using the Report Viewer.";return function(e){return window.kendo?Promise.resolve():N(c(n,"\\/")+"/resources/js/telerikReportViewer.kendo-"+e+".min.js/").catch((function(e){k("Kendo could not be loaded automatically. Make sure 'options.serviceUrl' / 'options.reportServer.url' is correct and accessible. The error is: "+e.error)}))}(T=S).then((function(){})).then((function(){E.authenticationToken(t.authenticationToken),g.getServiceVersion().catch((function(e){var t=I(e)?e.exceptionMessage:u(q.errorServiceUrl,[d(n)]);return l.text(t),Promise.reject()})).then((function(e){if(e!==T)return l.text(u(q.errorServiceVersion,[e,T])),Promise.reject();Rt.load(t.templateUrl,n,o).catch((function(){return l.text(u(q.errorLoadingTemplates,[d(t.templateUrl)])),Promise.reject()})).then((function(e){return f=e.templates,function(e){if(!e)return Promise.resolve();var t=$("head"),n=t.find("link").map((function(e,t){return t.outerHTML})).toArray(),r=[];return Array.from(e).forEach((e=>{-1===n.indexOf(e)&&r.push(new Promise((function(n,r){var a=$(e);a.on("load",n),a.on("onerror",(function(){k("error loading stylesheet "+e),n()})),t.append(a)})))})),Promise.all(r).then(g.cssLoaded)}(e.styleSheets)})).then(R)}))})),E}function _(e,t,n){"function"==typeof t?n?$(E).on(e,{sender:E},t):$(E).off(e,t):t||n||$(E).off(e)}function C(){var n,r,i,o,s,c,u;l.html(f["trv-report-viewer"]),ee.bind(l,{controller:g,commands:v,templates:f},t),(m=new Xe(e,g)).attach(),function(){var e={max:"500px",min:"50px",size:"210px",collapsible:!0},n=l.find(".trv-parameters-area"),r=[{}],a={max:"500px",min:"50px",size:"210px",collapsible:!0,collapsed:!0},i=l.find(".trv-document-map"),o=[{}],s="horizontal";t.documentMapAreaPosition===le.RIGHT?(i.insertAfter(l.find(".trv-pages-area")),o.push(a)):o.unshift(a);t.parametersAreaPosition!==se.TOP&&t.parametersAreaPosition!==se.BOTTOM||(s="vertical",n.addClass("-vertical"),e.size="130px");t.parametersAreaPosition===se.LEFT||t.parametersAreaPosition===se.TOP?(n.insertBefore(l.find(".trv-document-map-splitter")),r.unshift(e)):r.push(e);try{var c=l.find(".trv-document-map-splitter").kendoSplitter({panes:o,expand:function(e){w(e.pane,!0)},collapse:function(e){w(e.pane,!1)},resize:function(e){}}).data("kendoSplitter")}catch(e){throw console.error("Instantiation of Kendo Splitter as Document Map splitter threw an exception",e),e}try{var u=l.find(".trv-parameters-splitter").kendoSplitter({panes:r,orientation:s,expand:function(e){w(e.pane,!0)},collapse:function(e){w(e.pane,!1)},resize:function(e){}}).data("kendoSplitter")}catch(e){throw console.error("Instantiation of Kendo Splitter as Parameters area splitter threw an exception",e),e}var d={id:t.viewerSelector+"-parameters-splitter",instance:u},f={id:t.viewerSelector+"-document-map-splitter",instance:c};Ft.push(d),Ft.push(f)}(),function(){var e={EXPORT_BEGIN:g.Events.EXPORT_STARTED,EXPORT_END:g.Events.EXPORT_DOCUMENT_READY,PRINT_BEGIN:g.Events.PRINT_STARTED,PRINT_END:g.Events.PRINT_DOCUMENT_READY,RENDERING_BEGIN:g.Events.BEFORE_LOAD_REPORT,RENDERING_END:g.Events.REPORT_LOAD_COMPLETE,PAGE_READY:g.Events.PAGE_READY,ERROR:g.Events.ERROR,UPDATE_UI:g.Events.UPDATE_UI,INTERACTIVE_ACTION_EXECUTING:g.Events.INTERACTIVE_ACTION_EXECUTING,INTERACTIVE_ACTION_ENTER:g.Events.INTERACTIVE_ACTION_ENTER,INTERACTIVE_ACTION_LEAVE:g.Events.INTERACTIVE_ACTION_LEAVE,VIEWER_TOOLTIP_OPENING:g.Events.TOOLTIP_OPENING,SEND_EMAIL_BEGIN:g.Events.SEND_EMAIL_STARTED,SEND_EMAIL_END:g.Events.SEND_EMAIL_READY},t=$(E);for(const[n,r]of Object.entries(e))g.on(r,(function(e,r){t.trigger(n,r)}))}(),_(Me.EXPORT_BEGIN,t.exportBegin,!0),_(Me.EXPORT_END,t.exportEnd,!0),_(Me.PRINT_BEGIN,t.printBegin,!0),_(Me.PRINT_END,t.printEnd,!0),_(Me.RENDERING_BEGIN,t.renderingBegin,!0),_(Me.RENDERING_END,t.renderingEnd,!0),_(Me.PAGE_READY,t.pageReady,!0),_(Me.ERROR,t.error,!0),_(Me.UPDATE_UI,t.updateUi,!0),_(Me.INTERACTIVE_ACTION_EXECUTING,t.interactiveActionExecuting,!0),_(Me.INTERACTIVE_ACTION_ENTER,t.interactiveActionEnter,!0),_(Me.INTERACTIVE_ACTION_LEAVE,t.interactiveActionLeave,!0),_(Me.VIEWER_TOOLTIP_OPENING,t.viewerToolTipOpening,!0),_(Me.SEND_EMAIL_BEGIN,t.sendEmailBegin,!0),_(Me.SEND_EMAIL_END,t.sendEmailEnd,!0),n=p.getViewMode(),r=p.getPageMode(),i=p.getPrintMode(),o=p.getScale(),s=p.getScaleMode(),c=p.getDocumentMapVisible(),u=p.getParametersAreaVisible(),p.getAccessibilityKeyMap(),g.setViewMode(n||t.viewMode),g.setPageMode(r||t.pageMode),g.setPrintMode(i||t.printMode),g.setScale(o||t.scale),g.setScaleMode(s||t.scaleMode),g.setDocumentMapVisible({visible:c||t.documentMapVisible}),g.setParametersAreaVisible({visible:u||t.parametersAreaVisible}),g.printModeChanged((function(){p.setPrintMode(g.getPrintMode())})),g.viewModeChanged((function(){p.setViewMode(g.getViewMode())})),g.pageModeChanged((function(){p.setPageMode(g.getPageMode())})),g.scaleChanged((function(e,t){p.setScale(t)})),g.scaleModeChanged((function(e,t){p.setScaleMode(t)})),g.setSideMenuVisible((function(e,t){window.setTimeout((function(){(t.visible?$.fn.addClass:$.fn.removeClass).call(l,"trv-side-menu-visible")}),1)})),g.setDocumentMapVisible((function(){var e={};g.getDocumentMapState(e),p.setDocumentMapVisible(e.visible)})),g.setParametersAreaVisible((function(){var e={};g.getParametersAreaState(e),p.setParametersAreaVisible(e.visible)})),function(e){if(e.enableAccessibility){a=new Z({controller:g,templates:f});var t=e.accessibilityKeyMap;t&&a.setKeyMap(t),p.contentTabIndex=function(){var e="div.trv-pages-area";try{var t=l.find(e);if(0===t.length)throw"Selector "+e+" did not return a result.";return parseInt(t.attr("tabindex"))}catch(e){return console&&console.log(e),0}}()}}(t)}function w(e,t){switch($(e).attr("data-id")){case"trv-document-map":g.setDocumentMapVisible({visible:t});break;case"trv-parameters-area":g.setParametersAreaVisible({visible:t})}}function R(){var e=!1;C(),g.reportLoadComplete((function(){!1===t.documentMapVisible&&g.setDocumentMapVisible({visible:!1})}));var n=p.getReportSource();if(void 0!==n){g.setReportSource(n);var r=p.getPageNumber();void 0!==r&&g.navigateToPage(r),e=!0}else t.viewMode&&g.setViewMode(t.viewMode),t.pageMode&&g.setPageMode(t.pageMode),t.reportSource&&(g.setReportSource(t.reportSource),e=!0);"function"==typeof t.ready&&t.ready.call(E),e&&g.refreshReport(!1)}}var Ut="telerik_ReportViewer";$.fn[Ut]=function(e){return this.selector&&!e.selector&&(e.selector=this.selector),this.each((function(){$.data(this,Ut)||$.data(this,Ut,new Gt(this,e))}))};const Bt=[{name:"telerik_ReportViewer_DocumentMapArea",constructor:function(e,t,n){var r=(t=$.extend({},dt,t,n)).controller;if(!r)throw"No controller (telerikReporting.reportViewerController) has been specified.";var a,i,o=$(e),s=!1!==t.documentMapVisible,l=t.enableAccessibility,c=null,u=!1;function d(e){var t=this.dataItem(e.node),n=t.page,a=t.id;r.navigateToPage(n,{type:"bookmark",id:a})}function f(e){l&&window.setTimeout((function(){h(e.node)}),100)}function h(e){var t=$(e).find("li");Array.from(t).forEach((e=>{var t=$(e);t.attr("aria-label",t[0].innerText)}))}function p(){g([])}function g(e){var n=e&&!$.isEmptyObject(e),r=a.data("kendoTreeView");if(!r)try{a.kendoTreeView({dataTextField:"text",select:d}),r=a.data("kendoTreeView")}catch(e){throw console.error("Instantiation of Kendo TreeView as Document Map threw an exception",e),e}r.setDataSource(e),l&&function(e){e.bind("expand",f),e.element.attr("aria-label",q.ariaLabelDocumentMap);var n=e.element.find("ul");Array.from(n).forEach((e=>{h(e)})),u&&function(){var e=o.next();t.documentMapAreaPosition===le.RIGHT&&(e=o.prev());e.attr("aria-label",q.ariaLabelDocumentMapSplitter)}()}(r),v(n)}function m(){o.removeClass("trv-loading")}function v(e){var n=Q.viewerInstances.find((e=>e.id===t.viewerSelector+"-document-map-splitter")).instance,r=o.next();t.documentMapAreaPosition===le.RIGHT&&(r=o.prev()),n&&((u?$.fn.removeClass:$.fn.addClass).call(r,"trv-hidden"),n.toggle(".trv-document-map",e))}(a=$('<div id="'+t.viewerSelector+'-documentMap"></div>')).appendTo(e),r.beginLoadReport((function(){o.addClass("trv-loading");var e,t=r.getReportSource().report,n=c!==t||(e={},r.getDocumentMapState(e),!e.visible);c=t,n&&p()})).reportLoadComplete((function(e,t){t.documentMapAvailable?(u=!0,g(t.documentMapNodes),r.setDocumentMapVisible({enabled:!0,visible:s})):v(u=!1),m()})).error((function(e,t){m(),p()})).renderingStopped((function(){u=!1,v(!1)})),r.setDocumentMapVisible((function(e,t){v((s=t.visible)&&u)})).getDocumentMapState((function(e,t){t.enabled=u,t.visible=s})),(i=o.find(".trv-document-map-overlay"))&&i.attr("aria-label",q[i.attr("aria-label")])}},{name:"telerik_ReportViewer_MainMenu",constructor:function(e,t,n){var r,a=$.extend({},t,n),i=$(e).data("kendoMenu"),o=e.childNodes,s=a.controller,l=a.enableAccessibility;if(!s)throw"No controller (telerikReporting.ReportViewerController) has been specified.";function c(t){Array.from($(e).find("ul[data-command-list=export-format-list]")).forEach((e=>{var n,r=$(e),a=r.parents("li"),o=l?a.attr("tabindex"):-1;o||(o=1),r.empty(),Array.from(t).forEach((e=>{var t="<li "+(l?u('aria-label="{localizedName}" ',e):" ")+u('tabindex="'+o+'"><a tabindex="-1" href="#" data-command="telerik_ReportViewer_export" data-command-parameter="{name}"><span>{localizedName}</span></a></li>',e);i.append(t,a)})),l&&(n=a.find("li"),Array.from(n).forEach((e=>{var t=$(e);t.off("keydown"),t.on("keydown",(e=>{switch(e.which){case kendo.keys.ENTER:d(t);break;case kendo.keys.UP:var n=t.prev();n.length>0?n.trigger("focus"):t.parents("li").trigger("focus");break;case kendo.keys.DOWN:var r=t.next();r.length>0?r.trigger("focus"):t.parent().children("li").first().trigger("focus")}}))})))}))}function d(e){if(v(e))n="#trv-main-menu-export-command",$("[data-role='telerik_ReportViewer_MainMenu']").data("kendoMenu").open(n);else if(e&&e.length>0){var t=e.children("a");t.length>0&&t.click()}var n}function h(e){var t,n=$(e.item);t=n,ft&&ft.is(t)&&window.setTimeout((function(){var e=t.find("li");e.length>0&&e[0].focus()}),100)}function p(e){ht=void 0}function g(e){switch(e.which){case kendo.keys.ENTER:if(!l){var t=m();t.length>0&&(v(t)&&ht&&(t=ht),d(t))}break;case kendo.keys.RIGHT:l?function(){var e=m();if(!e||!e.length>0)return;var t=e.next();"none"==t.css("display")&&(t=t.next());!t.length>0&&(t=$(o).filter("li.k-item").first());t.focus()}():function(){var e=i.element.children("li.k-item"),t=e.filter(".k-focus");if(kendo.version>="2017.3.913")return void(r=t);if(t.hasClass("k-disabled"))if(!r||t.is(r)){var n=t.next();!n.length>0&&(n=e.first()),t.toggleClass("k-focus"),n.toggleClass("k-focus"),r=n,i._oldHoverItem=n}else r=t;else i._oldHoverItem=t,r=t}();break;case kendo.keys.LEFT:l?function(){var e=m();if(!e||!e.length>0)return;var t=e.prev();"none"==t.css("display")&&(t=t.prev());!t.length>0&&(t=$(o).filter("li.k-item").last());t.focus()}():(n=i.element.children("li.k-item.k-focus"),r=n);break;case kendo.keys.DOWN:case kendo.keys.UP:l||(ht=function(){var e=i.element.find('li.k-item.k-focus [data-command="telerik_ReportViewer_export"]');if(1===e.length)return e.parent("li");return}())}var n}function m(){var e,t=document.activeElement;if(t&&"li"==t.localName)for(var n=$(o).filter("li.k-item"),r=0;r<n.length;r++){var a=n[r];if(t===a){e=$(a);break}}else t&&"input"==t.localName?e=$(t).closest("li.k-item"):0===(e=i.element.children("li.k-item.k-focus")).length&&(e=i.element.children("li.k-item").first());return e}function v(e){if(0!==e.length){var t=e.attr("id");return"trv-main-menu-export-command"==t||"trv-side-menu-export-command"==t}}i||function(){try{i=$(e).kendoMenu().data("kendoMenu")}catch(e){throw console.error("Instantiation of Kendo Menu as Main Menu threw an exception",e),e}i.bind("activate",h),i.bind("deactivate",p),i.element.off("keydown",g),i.element.on("keydown",g),a.enableAccessibility&&(t=$('[data-role="telerik_ReportViewer_MainMenu"]'),Array.from(t).forEach((e=>{var t=$(e),n=t.find("li"),r=0,a=t.attr("tabIndex");a&&((r=f(a))&&!isNaN(r)||(r=0)),function(e,t){Array.from(e).forEach((e=>{var n=$(e);n.attr("tabindex",t),n.on("focus",(e=>{n.addClass("k-focus")})),n.on("blur",(e=>{n.removeClass("k-focus")}));var r=n.children("a");if(r.length>0){var a=$(r);a.attr("tabindex",-1),n.attr("title",a.attr("title"))}n.off("keydown"),n.on("keydown",(function(e){e.which==kendo.keys.ENTER&&(d(n),ft=n)}))}))}(n,r);var i=n.find('input[data-role="telerik_ReportViewer_PageNumberInput"]');i.length>0&&i.attr("tabindex",r)})));var t;!function(){var e=$("ul[data-role=telerik_ReportViewer_MainMenu]");if(!e)return;Array.from(e).forEach((e=>{var t=$(e),n=t.children("li.k-item");t.attr("aria-label",q[t.attr("aria-label")]),Array.from(n).forEach((e=>{var t=$(e);if(t.attr("aria-label",q[t.attr("aria-label")]),t.hasClass("trv-report-pager"))t.attr("title",q[t.attr("title")]);else{var n=t.find("a");n&&n.attr("title",q[n.attr("title")])}}))}))}()}(),s.reportLoadComplete((function(e,t){l||i&&i._oldHoverItem&&i._oldHoverItem.toggleClass("k-focus"),t.renderingExtensions?c(t.renderingExtensions):s.getDocumentFormats().then(c)}))}},{name:"telerik_ReportViewer_PagesArea",constructor:xe},{name:"telerik_ReportViewer_ParametersArea",constructor:function(e,t,n){t=$.extend({},pt,t,n);var r={},a=$(r),i={},o=t.controller;if(!o)throw"No controller (telerikReporting.reportViewerController) has been specified.";var s,l,c,u=[].concat(t.parameterEditors,Ye),f=void 0,h=$(e),p=h.find(".trv-parameters-area-content"),g=h.find(".trv-error-message"),m=h.find(".trv-parameters-area-preview-button");m.text(q[m.text()]),m.attr("aria-label",q[m.attr("aria-label")]),m.on("click",(function(e){e.preventDefault(),w()&&A()}));var v,E=t.templates["trv-parameter"],b=!1!==t.parametersAreaVisible,P=t.enableAccessibility;function T(e,t){e.style.display=t?"none":""}function S(e){var n=$(E),r=n.find(".trv-parameter-value"),a=n.find(".trv-parameter-title"),o=n.find(".trv-parameter-error"),l=n.find(".trv-parameter-error-message"),f=n.find(".trv-parameter-use-default input"),h=t.parameters&&t.parameters.editors?t.parameters.editors:null,p=function(e,t){var n=Array.from(u).find((n=>n.match(e,t)));return n}(e,h),g=d(e.text),v=!e.isVisible;v&&(g+=" [<b>hidden</b>]"),a.html(g).attr("title",g),l.text(e.Error),(e.Error?$.fn.show:$.fn.hide).call(o);var b=p.createEditor(r,{templates:t.templates,parameterChanged:function(e,t){var n=document.querySelector(".trv-pages-area .trv-error-message ul li."+e.name);try{t=be.validate(e,t),o.hide(),n&&T(n,!0),function(e,t){delete e.Error,e.value=t,s[e.id]=t,void 0!==c?e.id in c&&(s[e.id]=t):s[e.id]=t;if(N(e),e.childParameters)F(y);else{var n=w();if(_(n),n){var r=document.querySelector(".trv-pages-area .trv-error-message");m.is(":visible")&&r&&(r.textContent=q.tryReportPreview),y()}}}(e,t)}catch(t){n&&T(n,!1),e.Error=t,e.value=[],l.text(t),o.show(),_(!1)}finally{!function(e){var t=i[e.id];if(!t||!P)return;t.setAccessibilityErrorState(e)}(e)}},enableAccessibility:P});(i[e.id]=b,b.beginEdit(e),P&&!v&&b.addAccessibility(e),f.length>0)&&(f.on("click",(function(){var t=$(this).is(":checked");t?(delete s[e.id],delete c[e.id],N(e),F(B)):(s[e.id]=e.value,c[e.id]=e.value),b.enable(!t),M()})),null!==c?e.id in c||(f.prop("checked",!0),b.enable(!1)):v&&(f.prop("checked",!0),b.enable(!1)));return n}function _(e){e?(m.prop("disabled",!1),m.removeClass("k-disabled")):(m.prop("disabled",!0),m.addClass("k-disabled"))}function C(e){g.text(e),(e?$.fn.addClass:$.fn.removeClass).call(h,"trv-error")}function I(){(Array.from(l).every((e=>!e.isVisible||e.autoRefresh))?$.fn.removeClass:$.fn.addClass).call(h,"preview")}function w(){return Array.from(l).every((e=>!e.Error))}function R(e){var n;s={},f={},l=e||[],Object.entries(i).forEach((([e,t])=>{"function"==typeof t.destroy&&t.destroy()})),i={};var r=$("<div></div>");Array.from(l).forEach((e=>{try{e.value=be.validate(e,e.value)}catch(t){e.Error=e.Error||t}!Boolean(e.Error)?(s[e.id]=e.value,e.availableValues?f[e.id]={valueMember:e.value,displayMember:e.label,availableValues:e.availableValues,multivalue:e.multivalue}:f[e.id]=e.value):e.Error=q.invalidParameter,(e.isVisible||t.showHiddenParameters)&&(n=S(e))&&r.append(n)})),void 0!==c&&(null===c?(c={},Array.from(l).forEach((e=>{e.isVisible?c[e.id]=e.value:delete s[e.id]}))):Array.from(l).forEach((e=>{e.id in c||delete s[e.id]}))),p.empty(),l.length>0&&(p.append(r.children()),P&&p.attr("aria-label","Parameters area. Contains "+l.length+" parameters.")),I(),_(w()),o.setProcessedParameter($.extend({},f))}function A(){o.setParameters($.extend({},s)),o.previewReport(!1)}function M(){r.parametersReady(s)}function y(){M(),function(){for(var e=!0,t=l.length-1;e&&t>=0;t--){var n=l[t];e=n.id in s&&(Boolean(n.autoRefresh)||!n.isVisible)}return e}()&&A()}function N(e){e.childParameters&&Array.from(e.childParameters).forEach((e=>{var t=function(e){if(l)for(var t=0;t<l.length;t++){var n=l[t];if(n.id===e)return n}return null}(e);t&&N(t),delete s[e],function(e){if(i){var t=i[e];t&&"function"==typeof t.clearPendingChange&&t.clearPendingChange()}}(e)}))}function D(e){return!(!e||null===e)&&Array.from(e).some((e=>e.isVisible))}(v=h.find(".trv-parameters-area-preview-button"))&&(v.attr("aria-label",q[v.attr("aria-label")]),v.text(q[v.text()]));var k=0;function x(){k++,h.addClass("trv-loading")}function L(){k>0&&0==--k&&h.removeClass("trv-loading")}var O=!1;function V(e,n){(O=D(e))||H(!1),R(e),C(""),O&&b&&(H(!0),P&&function(){var e=h.prev(),n=h.find(".trv-parameters-area-content").attr("tabIndex");t.parametersAreaPosition!==se.TOP&&t.parametersAreaPosition!==se.LEFT||(e=h.next());e.attr("aria-label",q.ariaLabelParametersAreaSplitter),e.attr("tabIndex",n)}()),o.updateUIInternal(),"function"==typeof n&&n(),L()}function F(e){G(o.loadParameters(s),e)}function G(e,t){x(),e.then((function(e){V(e,t)})).catch((function(e){L(),z(),h.hasClass("trv-hidden")||C(e),r.error(e)}))}function U(e,t){var n=function(e){var t;return e&&e.length&&(t=e[0]),"function"==typeof t?t:null}(t);return n?a.on(e,n):a.trigger(e,t),o}function B(){null===c&&(c=$.extend({},s)),M()}function H(e){var n=Q.viewerInstances.find((e=>e.id===t.viewerSelector+"-parameters-splitter")).instance,r=h.prev();t.parametersAreaPosition!==se.TOP&&t.parametersAreaPosition!==se.LEFT||(r=h.next()),n&&((O?$.fn.removeClass:$.fn.addClass).call(r,"trv-hidden"),n.toggle(".trv-parameters-area",e))}function z(){R([])}return o.reloadParameters((function(e,t){C(),p.empty(),G(t,B)})).beforeLoadReport((function(){k=0,x()})).error(L).pageReady(L),o.getParametersAreaState((function(e,t){var n=!1;l&&(n=D(l)),t.enabled=n,t.visible=b})).setParametersAreaVisible((function(e,t){b=t.visible,H(t.visible&&D(l))})),$.extend(r,{allParametersValid:function(){return w()},clear:function(){z()},error:function(){return U(mt,arguments)},parametersReady:function(){return U(gt,arguments)},setParameters:function(e){c=null===e?null:$.extend({},e)}}),r}},{name:"telerik_ReportViewer_SearchDialog",constructor:class{constructor(e,t,n){if(this.options=$.extend({},vt,t),this.viewerOptions=n,this.element=e,this.controller=this.options.controller,this.initialized=!1,this.dialogVisible=!1,this.$element,this.$inputBox,this.$searchOptionsPlaceholder,this.searchOptionsMenu,this.$stopSearchPlaceholder,this.stopSearchMenu,this.$navigationPlaceholder,this.navigationMenu,this.$resultsLabel,this.$resultsPlaceholder,this.kendoComboBox,this.kendoSearchDialog,this.stopSearchCommand,this.optionsCommandSet,this.navigationCommandSet,this.searchResults,this.mruList=[],this.inputComboRebinding,this.searchMetadataRequested,this.searchMetadataLoaded,this.pendingHighlightItem,this.windowLocation,this.reportViewerWrapper=$("[data-selector='"+this.viewerOptions.viewerSelector+"']").find(".trv-report-viewer"),this.lastSearch="",this.highlightManager={shadedClassName:"trv-search-dialog-shaded-result",highlightedClassName:"trv-search-dialog-highlighted-result",current:null,elements:[]},!this.controller)throw"No controller (telerikReporting.ReportViewerController) has been specified.";this.controller.pageReady(this.onPageReady.bind(this)).scrollPageReady(this.onPageReady.bind(this)).beginLoadReport(this.closeAndClear.bind(this)).viewModeChanged(this.closeAndClear.bind(this)),this.controller.setSendEmailDialogVisible(((e,t)=>{t.visible&&this.dialogVisible&&this.toggle(!this.dialogVisible)})).getSearchDialogState(((e,t)=>{t.visible=this.dialogVisible})).setSearchDialogVisible(((e,t)=>{this.toggleSearchDialog(t.visible)})),$(window).on("resize",(()=>{this.kendoSearchDialog&&this.kendoSearchDialog.options.visible&&(this.storeDialogPosition(),this.adjustDialogPosition())}))}closeAndClear(){this.searchMetadataRequested||(this.toggle(!1),this.searchMetadataLoaded=!1)}toggleSearchDialog(e){if((this.dialogVisible=e,e)&&(this.viewerOptions.searchMetadataOnDemand&&!this.searchMetadataLoaded))return this.searchMetadataRequested=!0,this.controller.reportLoadComplete(((e,t)=>{this.searchMetadataRequested&&(this.toggle(!0),this.searchMetadataRequested=!1)})),void this.controller.refreshReport(!0);this.toggle(e)}toggle(e){this.dialogVisible=e,e?(this.searchMetadataLoaded=!0,this.ensureInitialized(),this.kendoSearchDialog.open(),this.kendoComboBox.value(""),this.updateResultsUI(null),this.toggleErrorLabel(!1,null)):(this.clearColoredItems(),this.kendoSearchDialog&&this.kendoSearchDialog.options.visible&&this.kendoSearchDialog.close())}ensureInitialized(){if(!this.initialized){this.$element=$(this.element),this.$inputBox=this.$element.find(".trv-search-dialog-input-box"),this.$resultsLabel=this.$element.find(".trv-search-dialog-results-label"),this.$resultsPlaceholder=this.$element.find(".trv-search-dialog-results-area"),this.initResultsArea(),Et(this.$element);try{this.$searchOptionsPlaceholder=this.$element.find(".trv-search-dialog-search-options").kendoMenu(),this.$stopSearchPlaceholder=this.$element.find(".trv-search-dialog-stopsearch-placeholder").kendoMenu(),this.$navigationPlaceholder=this.$element.find(".trv-search-dialog-navigational-buttons").kendoMenu()}catch(e){throw console.error("Instantiation of Kendo Menu for Search Dialog threw an exception",e),e}this.searchOptionsMenu=this.$searchOptionsPlaceholder.data("kendoMenu"),this.stopSearchMenu=this.$stopSearchPlaceholder.data("kendoMenu"),this.navigationMenu=this.$navigationPlaceholder.data("kendoMenu"),this.searchOptionsMenu.element.on("keydown",this.onKeyDown),this.stopSearchMenu.element.on("keydown",this.onKeyDown),this.navigationMenu.element.on("keydown",this.onKeyDown),this.overrideDefaultMenuStyling(".trv-search-dialog-search-options");try{this.kendoComboBox=this.$inputBox.kendoComboBox({dataTextField:"value",dataValueField:"value",dataSource:this.mruList,contentElement:"",change:this.kendoComboBoxSelect.bind(this),ignoreCase:!1,filtering:this.onInputFiltering.bind(this),filter:"startswith",delay:1e3,open:e=>{this.inputComboRebinding&&e.preventDefault()},select:this.processComboBoxEvent.bind(this)}).data("kendoComboBox")}catch(e){throw console.error("Instantiation of Kendo ComboBox as search input threw an exception",e),e}try{this.kendoSearchDialog=this.reportViewerWrapper.find(".trv-search-window").kendoWindow({title:q.searchDialogTitle,height:390,width:310,minWidth:310,minHeight:390,maxHeight:700,scrollable:!1,close:()=>{this.storeDialogPosition(),this.lastSearch=""},open:()=>{this.adjustDialogPosition()},deactivate:()=>{this.controller.setSearchDialogVisible({visible:!1})},activate:()=>{this.kendoComboBox.input.focus()}}).data("kendoWindow")}catch(e){throw console.error("Instantiation of Kendo Window for Search dialog threw an exception",e),e}this.kendoSearchDialog.wrapper.addClass("trv-search"),this.initCommands(),this.initialized=!0}}overrideDefaultMenuStyling(e){for(var t=$(e).find(".k-menu-item"),n=0;n<t.length;n++)$(t[n]).removeClass("k-item")}onKeyDown(e){var t=$(e.target).find(".k-focus");if(13===e.keyCode&&t&&t.length>0){var n=t.children("a");n.length>0&&n.click()}}storeDialogPosition(){var e=this.kendoSearchDialog.element.parent(".k-window");this.windowLocation=e.offset()}adjustDialogPosition(){var e=$(window).innerWidth(),t=$(window).innerHeight(),n=this.kendoSearchDialog.wrapper,r=n.outerWidth(!0),a=n.outerHeight(!0),i=10;if(this.windowLocation){var o=this.windowLocation.left,s=this.windowLocation.top,l=s+a;o+r>e-i&&(o=Math.max(i,e-r-i),n.css({left:o}),this.kendoSearchDialog.setOptions({position:{left:o}})),l>t-i&&(s=Math.max(i,t-a-i),n.css({top:s}),this.kendoSearchDialog.setOptions({position:{top:s}}))}else{var c=this.reportViewerWrapper[0].getBoundingClientRect();n.css({top:c.top+i,left:c.right-r-i}),this.kendoSearchDialog.setOptions({position:{top:c.top+i,left:c.right-r-i}})}}processComboBoxEvent(e){if(window.event||window.event.type){var t=window.event;"keydown"===t.type&&(e.preventDefault(),40===t.keyCode&&this.moveListSelection(1),38===t.keyCode&&this.moveListSelection(-1))}}initCommands(){this.optionsCommandSet={searchDialog_MatchCase:new ce,searchDialog_MatchWholeWord:new ce,searchDialog_UseRegex:new ce},Object.entries(this.optionsCommandSet).forEach((([e,t])=>{t.exec=()=>{this.toggleCommand(t)}})),ee.attachCommands(this.$searchOptionsPlaceholder,this.optionsCommandSet,this.viewerOptions),this.stopSearchCommand=new ce((()=>{this.stopSearch()})),ee.attachCommands(this.$stopSearchPlaceholder,{searchDialog_StopSearch:this.stopSearchCommand},this.viewerOptions),this.navigationCommandSet={searchDialog_NavigateUp:new ce((()=>{this.moveListSelection(-1)})),searchDialog_NavigateDown:new ce((()=>{this.moveListSelection(1)}))},ee.attachCommands(this.$navigationPlaceholder,this.navigationCommandSet,this.viewerOptions)}initResultsArea(){try{this.$resultsPlaceholder.kendoListView({selectable:!0,navigatable:!0,dataSource:{},contentElement:"",template:"<div class='trv-search-dialog-results-row'><span>#: description #</span> <span class='trv-search-dialog-results-pageSpan'>"+q.searchDialogPageText+" #:page#</span></div>",change:e=>{var t=e.sender,n=t.select().index(),r=t.dataSource.view(),a=r[n];this.onSelectedItem(a),this.updateUI(n,r.length)}})}catch(e){throw console.error("Instantiation of Kendo ListView as search result area threw an exception",e),e}}stopSearch(){this.setStopButtonEnabledState(!1)}toggleCommand(e){e.checked(!e.checked()),this.searchForCurrentToken()}setStopButtonEnabledState(e){this.stopSearchCommand.enabled(e)}onPageReady(e,t){this.dialogVisible&&this.colorPageElements(this.searchResults)}onInputFiltering(e){e.preventDefault(),e.filter&&e.filter.value!==this.lastSearch&&(this.lastSearch=e.filter.value,this.searchForToken(this.lastSearch))}kendoComboBoxSelect(e){var t=e.sender.value();t&&this.lastSearch!==t&&(this.lastSearch=t,this.searchForToken(this.lastSearch))}searchForCurrentToken(){this.kendoComboBox&&this.searchForToken(this.kendoComboBox.value())}searchForToken(e){this.onSearchStarted(),this.addToMRU(e),this.controller.getSearchResults({searchToken:e,matchCase:this.optionsCommandSet.searchDialog_MatchCase.checked(),matchWholeWord:this.optionsCommandSet.searchDialog_MatchWholeWord.checked(),useRegex:this.optionsCommandSet.searchDialog_UseRegex.checked()}).then((e=>{this.updateResultsUI(e,null)})).catch((e=>{e&&this.updateResultsUI(null,e)}))}onSearchStarted(){this.$resultsLabel.text(q.searchDialogSearchInProgress),this.clearColoredItems(),this.searchResults=null,this.setStopButtonEnabledState(!0),this.toggleErrorLabel(!1,null)}updateResultsUI(e,t){this.setStopButtonEnabledState(!1),t&&this.toggleErrorLabel(!0,t),this.displayResultsList(e),this.searchResults=e,e&&e.length>0?(this.colorPageElements(e),this.selectFirstElement()):this.updateUI(-1,0)}addToMRU(e){if(e&&""!==e){var t=this.mruList.filter((t=>t.value===e));t&&t.length>0||(this.mruList.unshift({value:e}),this.mruList.length>10&&this.mruList.pop(),this.inputComboRebinding=!0,this.kendoComboBox.dataSource.data(this.mruList),this.kendoComboBox.select((t=>t.value===e)),this.inputComboRebinding=!1)}}displayResultsList(e){e||(e=[]),this.$resultsPlaceholder.data("kendoListView").dataSource.data(e)}colorPageElements(e){if(e&&0!==e.length){var t=this.$element.parent().find(".trv-page-container").find("[data-search-id]");Array.from(e).forEach((e=>{var n=t.filter("[data-search-id="+e.id+"]");n&&(n.addClass(this.highlightManager.shadedClassName),this.highlightManager.elements.push(n))})),this.highlightItem(this.pendingHighlightItem),this.pendingHighlightItem=null}}highlightItem(e){if(e){var t=e.id,n=$(this.highlightManager.elements.filter((e=>e.attr("data-search-id")===t))).first();if(n&&(this.highlightManager.current=n[0],this.highlightManager.current)){var r=$("[data-search-id='"+t+"']");r.removeClass(this.highlightManager.shadedClassName),r.addClass(this.highlightManager.highlightedClassName)}}}selectFirstElement(){var e=this.$resultsPlaceholder.data("kendoListView"),t=e.element.children().first();e.select(t),e.trigger("change")}onSelectedItem(e){e&&(this.highlightManager.current&&(this.highlightManager.current.removeClass(this.highlightManager.highlightedClassName),this.highlightManager.current.addClass(this.highlightManager.shadedClassName)),e.page===this.controller.getCurrentPageNumber()?this.highlightItem(e):this.controller.getPageMode()!==re.CONTINUOUS_SCROLL?this.clearColoredItems():this.highlightItem(e),this.pendingHighlightItem=e,this.controller.navigateToPage(e.page,{type:"search",id:e.id}))}updateUI(e,t){var n=0===t?q.searchDialogNoResultsLabel:u(q.searchDialogResultsFormatLabel,[e+1,t]);this.$resultsLabel.text(n);var r=e>0,a=e<t-1;this.navigationCommandSet.searchDialog_NavigateUp.enabled(r),this.navigationCommandSet.searchDialog_NavigateDown.enabled(a)}clearColoredItems(){this.highlightManager.elements&&this.highlightManager.elements.length>0&&Array.from(this.highlightManager.elements).forEach((e=>{e.removeClass(this.highlightManager.shadedClassName)})),this.highlightManager.current&&this.highlightManager.current.removeClass(this.highlightManager.highlightedClassName),this.highlightManager.elements=[],this.highlightManager.current=null}moveListSelection(e){var t=this.$resultsPlaceholder.data("kendoListView"),n=t.select();if(n){var r=t.select().trigger("change").index(),a=t.dataSource.view(),i=Math.min(a.length-1,Math.max(0,r+e));if(i!==r){var o=a[i],s=t.element.find('[data-uid="'+o.uid+'"]');s&&(t.select(s),t.trigger("change"),this.scrollIfNeeded(s[0],t.element[0]))}}else n=t.element.children().first(),t.select(n),t.trigger("change")}scrollIfNeeded(e,t){if(e.offsetTop-e.clientHeight<t.scrollTop)e.scrollIntoView();else{var n=e.offsetTop+e.offsetHeight;n>t.scrollTop+t.offsetHeight&&(t.scrollTop=n-t.offsetHeight)}}toggleErrorLabel(e,t){var n=this.$searchOptionsPlaceholder.find("i[data-role='telerik_ReportViewer_SearchDialog_Error']");if(n&&0!==n.length){var r=this.$searchOptionsPlaceholder.data("kendoMenu").element.find("li").last();e?(n[0].title=t,r.show()):r.hide()}else console.log(t)}}},{name:"telerik_ReportViewer_SendEmail",constructor:function(e,t,n){var r,a,i,o,s,l,c,u,d,f,h,p,g,m=(t=$.extend({},Tt,t)).controller,v=!1,E=!1,b=n.viewerSelector,P=$("[data-selector='"+b+"']").find(".trv-report-viewer");if(!m)throw"No controller (telerikReporting.ReportViewerController) has been specified.";function T(){S(!1)}function S(t){E=t,t?(!function(){if(!v){r=$(e),i=r.find("[name='from']"),o=r.find("[name='to']"),s=r.find("[name='cc']"),l=r.find("[name='subject']"),u=r.find("[name='format']"),d=r.find("textarea"),r.find(".trv-send-email-field input").each((function(){var e=$(this),t=e.attr("name");e.attr("id",b+"-"+t)})),r.find(".trv-send-email-label label").each((function(){var e=$(this),t=e.attr("for");e.attr("for",b+"-"+t)})),p={sendEmail_Cancel:new ce((function(){k()})),sendEmail_Send:new ce((function(){var e,t,n,r,a;a={from:i.val(),to:o.val(),cc:s.val(),subject:l.val(),format:c.value(),body:_(),deviceInfo:{}},e=A(i)||!N(i,!1),t=A(o)||!N(o,!0),n=s.val().length&&!N(s,!0),(r=c.value().length)||M(u,"data-required-msg"),!(e||t||n)&&r&&(m.sendReport(a),k())}))},ee.attachCommands(r.find(".trv-send-email-actions"),p,n),St(r);try{a=P.find(".trv-send-email-window").kendoWindow({title:q.sendEmailDialogTitle,minWidth:350,minHeight:350,maxHeight:900,modal:!0,close:function(){C(),$(".k-invalid-msg").removeClass("-visible")},open:function(){I(),w()},deactivate:function(){m.setSendEmailDialogVisible({visible:!1})},activate:function(){a.wrapper.find(".trv-send-email-fields input[type='email']:visible").first().focus(),setTimeout((function(){i.off("blur").on("blur",(function(e){A($(this))||N($(this),!1)})),o.off("blur").on("blur",(function(e){A($(this))||N($(this),!0)})),s.off("blur").on("blur",(function(e){$(this).val().length?N($(this),!0):y($(this))}))}),250)}}).data("kendoWindow")}catch(e){throw console.error("Instantiation of Kendo Window for Send Email dialog threw an exception",e),e}a.wrapper.addClass("trv-send-email");try{c=u.kendoComboBox({dataTextField:"localizedName",dataValueField:"name",dataSource:h||[],filter:"startswith",dataBound:function(){this.select(0),this.trigger("change")}}).data("kendoComboBox")}catch(e){throw console.error("Instantiation of Kendo ComboBox as document format selector threw an exception",e),e}r.on("keydown",'[name="format_input"]',(function(e){var t=9;e.keyCode===t&&f&&setTimeout((function(){f.focus()}))}));try{f=d.kendoEditor({tools:["bold","italic","underline","strikethrough","justifyLeft","justifyCenter","justifyRight","justifyFull","insertUnorderedList","insertOrderedList","indent","outdent","createLink","unlink","cleanFormatting","formatting","fontName","fontSize","foreColor","backColor","subscript","superscript"]}).data("kendoEditor")}catch(e){throw console.error("Instantiation of Kendo Editor for Email body editor threw an exception",e),e}R(n.sendEmail),v=!0}}(),R(n.sendEmail),a.open()):a&&a.options.visible&&a.close()}function _(){return f?f.value():""}function C(){var e=a.element.parent(".k-window");g=e.offset()}function I(){var e=a.element.parent(".k-window"),t=350;$(window).width()>800&&(t=720),e.css({width:t}),a.refresh({width:t})}function w(){if(g){var e=10,t=$(window).innerWidth(),n=$(window).innerHeight(),r=a.wrapper,i=r.outerWidth(!0),o=r.outerHeight(!0),s=g.left,l=g.top,c=l+o;s+i>t-e&&(s=Math.max(e,t-i-e),r.css({left:s}),a.setOptions({position:{left:s}})),c>n-e&&(l=Math.max(e,n-o-e),r.css({top:l}),a.setOptions({position:{top:l}}))}else a.center()}function R(e){i.val(e&&e.from||""),o.val(e&&e.to||""),s.val(e&&e.cc||""),l.val(e&&e.subject||""),e&&e.format?c.value(e.format):c.select(0),c.trigger("change"),f.value(e&&e.body||"")}function A(e){return e.val().length?(y(e),!1):(M(e,"data-required-msg"),!0)}function M(e,t){var n=q[e.attr(t)];$('[data-for="'+e.attr("name")+'"]').addClass("-visible").text(n)}function y(e){$('[data-for="'+e.attr("name")+'"]').removeClass("-visible")}function N(e,t){var n=e.val();if(t){for(var r=n.split(/[\s,;]+/),a=0;a<r.length;a++)if(!D(r[a].trim(),e))return!1;return!0}return D(n,e)}function D(e,t){return e.indexOf(",")>-1||e.indexOf(";")>-1?(M(t,"data-single-email-msg"),!1):!!/\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*/.test(e)||(M(t,"data-email-msg"),!1)}function k(){a.close()}n.sendEmail&&n.sendEmail.enabled?(m.beginLoadReport(T).viewModeChanged(T),m.getSendEmailDialogState((function(e,t){t.visible=E})).setSendEmailDialogVisible((function(e,t){S(t.visible)})).setSearchDialogVisible((function(e,t){t.visible&&E&&S(!E)})),m.getDocumentFormats().then((function(e){h=e})),$(window).resize((function(){a&&a.options.visible&&(C(),I(),w())}))):$("[data-selector='"+b+"']").find("a[data-command='telerik_ReportViewer_toggleSendEmailDialog']").closest(".k-item ").hide()}},{name:"telerik_ReportViewer_SideMenu",constructor:function(e,t,n){var r,a=$.extend({},t,n),i=$(e).data("kendoMenu"),o=a.enableAccessibility,s=3,l=!1,c=a.controller;if(!c)throw"No controller (telerikReporting.ReportViewerController) has been specified.";function d(e){var t=$(e.item);r.unbind("expand",d),r.append({text:q.loadingFormats,spriteCssClass:"k-icon k-loading"},t),a.controller.getDocumentFormats().then(f).then((function(){r.expand(t)})).then((function(){r.bind("expand",d)}))}function f(t){Array.from($(e).find("ul[data-command-list=export-format-list]")).forEach((e=>{var n=$(e),a=n.parents("li"),i=a.attr("tabindex");i||(i=s),n.empty(),Array.from(t).forEach((e=>{var t="<li "+(o?u('aria-label="{localizedName}" ',e):" ")+u('tabindex="'+i+'"><a tabindex="-1" href="#" data-command="telerik_ReportViewer_export" data-command-parameter="{name}"><span>{localizedName}</span></a></li>',e);r.append(t,a)})),p(a.find("li"),i),h(a)}))}function h(e){Array.from(e.find("li")).forEach((e=>{0===$(e).children("ul").length&&$(e).children("a").on("click",(e=>{c.setSideMenuVisible({visible:!l})}))}))}function p(e,t){e.attr("tabindex",t);var n=e.find("li");Array.from(n).forEach((e=>{var n=$(e);n.attr("tabindex",t);var r=n.children("a");r.length>0&&$(r).attr("tabindex",-1);n.on("focus",(e=>{var t=n.children("a");t.length>0&&t.addClass("k-focus")})),n.on("blur",(e=>{var t=n.children("a");t.length>0&&t.removeClass("k-focus")})),n.off("keydown",m),n.on("keydown",m)}))}function g(e){if(e.which==kendo.keys.ENTER){var t,n=!1,a=document.activeElement;if(a&&"li"==a.localName)for(var i=r.element.find("li.k-item"),o=0;o<i.length;o++){var s=i[o];if(a===s){t=$(s),n=!0;break}}else t=r.select();if(!t||!t.length>0)return;v(t,n)}}function m(e){e.which==kendo.keys.ENTER&&v($(e.target),!1)}function v(e,t){if(!(!e.length>0))if(0===e.children("ul").length){var n=e.find("a");n.length>0&&n[0].click()}else t&&(e.hasClass("k-active")?r.collapse(e):r.expand(e))}i||function(e){var t=$(e);try{r=t.children("ul").kendoPanelBar().data("kendoPanelBar")}catch(e){throw console.error("Instantiation of Kendo PanelBar as side menu threw an exception",e),e}r.bind("expand",d),r.element.off("keydown",g),r.element.on("keydown",g),function(e){if(!e)return;var t=e.children("ul"),n=e.attr("tabindex");p(t,n||s)}(t),h(t),t.click((function(t){t.target==e&&c.setSideMenuVisible({visible:!l})})),function(){var e=$("div[data-role=telerik_ReportViewer_SideMenu] > ul");if(!e)return;Array.from(e).forEach((e=>{var t=$(e),n=t.children("li.k-panelbar-header");t.attr("aria-label",q[t.attr("aria-label")]),Array.from(n).forEach((e=>{var t=$(e),n=t.find("a");if(t.attr("aria-label",q[t.attr("aria-label")]),n){var r=n.find("span:not(.k-icon)");n.attr("title",q[n.attr("title")]),r&&r.text(q[r.text()])}}))}))}()}(e),c.setSideMenuVisible((function(e,t){var n;(n=r.element.parent()).position().left<0||!n.is(":visible")?n.show():window.setTimeout((function(){n.hide()}),500),o&&r.element.focus(),(l=t.visible)||r.collapse($("#trv-side-menu-export-command"))})).getSideMenuVisible((function(e,t){t.visible=l}))}},{name:"telerik_ReportViewer_LinkButton",constructor:class extends kt{constructor(e,t){super(e,t),Lt(this,"cmd");var n=this.$element.attr("data-command");n&&(this.cmd=this.options.commands[n]),this.cmd&&(this.$element.on("click",(e=>{this.cmd.enabled()?this.cmd.exec($(this).attr("data-command-parameter")):e.preventDefault()})),$(this.cmd).on("enabledChanged",(e=>{(this.cmd.enabled()?$.fn.removeClass:$.fn.addClass).call(this.$element,"disabled")})).on("checkedChanged",(e=>{(this.cmd.checked()?$.fn.addClass:$.fn.removeClass).call(this.$element,"checked")})))}}},{name:"telerik_ReportViewer_PageNumberInput",constructor:class extends kt{constructor(e,t){super(e,t),Vt(this,"cmd"),Vt(this,"_numeric"),this.cmd=this.options.commands.goToPage,this._numeric=new kendo.ui.NumericTextBox(this.element,{format:"0",decimals:0,min:0,spinners:!1,change:this._onChange.bind(this),spin:this._onChange.bind(this)}),this._numeric._text[0].dataset.role="telerik_ReportViewer_PageNumberInput",this._numeric.element[0].dataset.role="",this.options.controller.on("reportLoadComplete",((e,t)=>{this._numeric.max(t.pageCount),this._numeric.min(Math.min(1,t.pageCount)),this._numeric.value(Math.min(1,t.pageCount))})).on("loadedReportChange",(e=>{this._numeric.min(0),this._numeric.max(0),this._numeric.value(0)})).on("renderingStopped",(e=>{this._numeric.min(0),this._numeric.max(0),this._numeric.value(0)})).pageNumberChange(((e,t)=>{this._numeric.value(t)}))}_onChange(e,t){var n=f(this._numeric.value());isNaN(n)||this.cmd.exec(n)}_onSpin(e,t){return this._onChange(e,t)}}},{name:"telerik_ReportViewer_PageCountLabel",constructor:class extends kt{constructor(e,t){super(e,t),this.options.controller.pageCountChange(((e,t)=>{this.$element.text(t)}))}}}];return Bt.forEach((e=>{$.fn[e.name]=function(t,n){return this.each((function(){$.data(this,e.name)||$.data(this,e.name,new e.constructor(this,t,n))}))}})),e.Accessibility=Z,e.Binder=ee,e.CommandSet=fe,e.DocumentMapAreaPositions=le,e.Events=Me,e.GlobalSettings=Q,e.HistoryManager=ye,e.PageModes=re,e.PagesArea=xe,e.ParameterEditorTypes=oe,e.ParameterEditors=Ye,e.ParameterTypes=ie,e.ParameterValidators=be,e.ParametersAreaPositions=se,e.PerspectiveManager=Xe,e.PrintManager=Ee,e.PrintModes=ne,e.ReportViewer=Gt,e.ReportViewerController=we,e.ScaleModes=ae,e.Scroll=De,e.ServiceClient=ct,e.TouchBehavior=Ne,e.UIController=ut,e.UIFreezeCoordinator=$e,e.ViewModes=te,e.domUtils=K,e.parameterEditorsMatch=Oe,e.utils=G,Object.defineProperty(e,"__esModule",{value:!0}),e}({});