webpackJsonp([2],{1031:function(e,t,n){"use strict";t.a=function(e){for(;e;){var t=e,n=t.closed,o=t.destination,i=t.isStopped;if(n||i)return!1;e=o&&o instanceof r.a?o:null}return!0};var r=n(106)},1032:function(e,t,n){"use strict";t.a=function(e){setTimeout(function(){throw e})}},1033:function(e,t,n){"use strict";n.d(t,"a",function(){return r});var r="function"===typeof Symbol?Symbol("rxSubscriber"):"@@rxSubscriber_"+Math.random()},1034:function(e,t,n){"use strict";t.a=function(){}},1035:function(e,t,n){"use strict";t.a=function(){for(var e=[],t=0;t0&&r.next(o)}})}},{key:"betSlipMonitoringSubscription",value:function(e){var t=this;return new o.Observable(function(n){try{return e.subscriptionId?(t.dispatcher[e.subscriptionId]=n,t["betSlipMonitoringHubProxy"+e.subscriptionId].invoke("Subscribe",e).then(function(){},function(t){console.log("Subscription Failed: ",t),console.log("Subscription Failed Request: ",e)}),function(t){try{this["betSlipMonitoringHubProxy"+e.subscriptionId].invoke("Unsubscribe",e).then(function(){},function(e){console.log("Failed to unsubscribe",e)}),delete this.dispatcher[e.subscriptionId]}catch(e){}}.bind(t)):void n.error("missing subscriptionId in subscriptionRequest")}catch(e){console.warn(e)}})}}]),e}();t.default=i},1876:function(e,t,n){"use strict";n.d(t,"a",function(){return i});var r=n(515),o=n(1032),i={closed:!0,next:function(e){},error:function(e){if(r.a.useDeprecatedSynchronousErrorHandling)throw e;Object(o.a)(e)},complete:function(){}}},1877:function(e,t,n){"use strict";t.a=function(e){return null!=e&&"object"===typeof e}},1878:function(e,t,n){"use strict";n.d(t,"a",function(){return r});var r={e:{}}},1879:function(e,t,n){"use strict";function r(e){return Error.call(this),this.message=e?e.length+" errors occurred during unsubscription:\n"+e.map(function(e,t){return t+1+") "+e.toString()}).join("\n "):"",this.name="UnsubscriptionError",this.errors=e,this}n.d(t,"a",function(){return o}),r.prototype=Object.create(Error.prototype);var o=r},1880:function(e,t,n){"use strict";t.a=function(){for(var e=[],t=0;t=0};var r=n(118)},1897:function(e,t,n){"use strict";n.d(t,"a",function(){return i}),t.b=function(){return i};var r=n(38),o=n(1034),i=new r.a(o.a)},1898:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n0&&r.next(o)}})}},{key:"betSlipMonitoringLiveSubscription",value:function(e){var t=this;return new o.Observable(function(n){if(e.subscriptionId)return t.dispatcher[e.subscriptionId]=n,t["betSlipMonitoringLiveHubProxy"+e.subscriptionId].invoke("Subscribe",e).then(function(){},function(t){console.log("Subscription Failed: ",t),console.log("Subscription Failed Request: ",e)}),function(){var t=this;this["betSlipMonitoringLiveHubProxy"+e.subscriptionId].invoke("Unsubscribe",e.subscriptionId).then(function(){console.log("LIVE UNSUBBED"),delete t["betSlipMonitoringLiveHubProxy"+e.subscriptionId],delete t[e.subscriptionId]},function(e){console.log("Failed to unsubscribe",e)}),delete this.dispatcher[e.subscriptionId]}.bind(t);n.error("missing subscriptionId in subscriptionRequest")})}}]),e}();t.default=a},1899:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n0&&r.next(o)}})}},{key:"betSlipMonitoringLiveSubscription",value:function(e){var t=this;return new o.Observable(function(n){if(e.subscriptionId)return t.dispatcher[e.subscriptionId]=n,t["betSlipMonitoringLiveHubProxy"+e.subscriptionId].invoke("Subscribe",e).then(function(){},function(t){console.log("Subscription Failed: ",t),console.log("Subscription Failed Request: ",e)}),function(){var t=this;this["betSlipMonitoringLiveHubProxy"+e.subscriptionId].invoke("Unsubscribe",e.subscriptionId).then(function(){console.log("LIVE UNSUBBED"),delete t["betSlipMonitoringLiveHubProxy"+e.subscriptionId],delete t[e.subscriptionId]},function(e){console.log("Failed to unsubscribe",e)}),delete this.dispatcher[e.subscriptionId]}.bind(t);n.error("missing subscriptionId in subscriptionRequest")})}}]),e}();t.default=i},1900:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:{},n=e.accountRoute.identifier;if("platform"===n)throw new Error("Agency can't be initialized with platform key");var r=null;if(this.apps.has(n))r=this.apps.get(n);else{var o=Object.assign({},h.baasicOptions,t);r=new f.BaasicApp(n,Object.assign({storageHandler:{keyGenerator:p.baasicKeyGenerator}},o)),this.apps.set(n,r),this.rootStore.authStore.registerTokenListeners(n)}return this.agencyCache.set(e),this.setApp({baasic:r}),r}},{key:"unregister",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=arguments[1];this.agencyExists&&(this.apps.delete(t||this.app.baasic.getApiKey()),this.setApp(null)),e&&this.agencyCache.set(null),this.rootStore.selectedAgency=null}},{key:"resolveAgency",value:function(){var e=y(s.default.mark(function e(t){var n,r,o,i,a=this;return s.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(this.agencyLoader.suspend(),n=t,(r=this.rootStore.userStore.user)&&!0===r.isApplicationUser&&"platform"!==r.apiKey&&(n=r.apiKey),o=this.getAgencyInfo(),i=null,!n){e.next=16;break}if(!o||!o.accountRoute||o.accountRoute.identifier!==n){e.next=11;break}i=o,e.next=14;break;case 11:return e.next=13,this.getAgency(n);case 13:i=e.sent;case 14:e.next=17;break;case 16:i=o||null;case 17:return i?this.register(i):this.unregister(),(0,l.runInAction)(function(){a.rootStore.selectedAgency=i}),this.agencyLoader.resume(),e.abrupt("return",i);case 21:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"getAgencyInfo",value:function(){return this.agencyCache.get()}},{key:"clearAgencyInfo",value:function(){this.agencyCache.set(null)}},{key:"getAgency",value:function(){var e=y(s.default.mark(function e(t){var n,r,o=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return s.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(null!=t){e.next=3;break}return this.agencyCache.set(null),e.abrupt("return",null);case 3:return n=o||!this.rootStore.permissionStore.hasPermission("companyRootCentral.read"),e.next=6,this.agencyCacheService.getWithOrganizationStructure(n);case 6:return r=e.sent,e.abrupt("return",r.item.find(function(e){return e.id===t||e.accountRoute.identifier===t})||null);case 8:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"agencyExists",get:function(){return void 0!==this.app&&null!==this.app}},{key:"resolving",get:function(){return this.agencyLoader.loading}}]),e}(),i=S(o.prototype,"apps",[l.observable],{enumerable:!0,initializer:function(){return l.observable.map()}}),a=S(o.prototype,"agencyIdentifier",[l.observable],{enumerable:!0,initializer:function(){return l.observable.box(null)}}),S(o.prototype,"setApp",[l.action],Object.getOwnPropertyDescriptor(o.prototype,"setApp"),o.prototype),S(o.prototype,"resolving",[l.computed],Object.getOwnPropertyDescriptor(o.prototype,"resolving"),o.prototype),S(o.prototype,"register",[l.action],Object.getOwnPropertyDescriptor(o.prototype,"register"),o.prototype),S(o.prototype,"unregister",[l.action],Object.getOwnPropertyDescriptor(o.prototype,"unregister"),o.prototype),S(o.prototype,"resolveAgency",[l.action],Object.getOwnPropertyDescriptor(o.prototype,"resolveAgency"),o.prototype),o),_=function(){function e(){m(this,e),this.cache=d.cacheManager.create("Gp-Working-Agency")}return u(e,[{key:"get",value:function(){return this.cache.get("")}},{key:"set",value:function(e){null===e?(this.cache.remove(),localStorage.removeItem("Gp-Working-Agency")):this.cache.set("",e)}}]),e}();t.default=w},4779:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,o,i,a,c=n(3),s=(r=c)&&r.__esModule?r:{default:r},u=function(){function e(e,t){for(var n=0;n0?this.sportBettingTypeSettings[r].values=e.map(function(e){return e.sportId}):this.sportBettingTypeSettings.push({key:n,values:e.map(function(e){return e.sportId})})}}},{key:"updateTournamentBettingTypes",value:function(e){var t=(0,f.default)(e);if(t){var n=t.bettingTypeSettingId,r=(0,l.default)(this.tournamentBettingTypes,function(e){return e.key===n});r>0?this.tournamentBettingTypes[r].values=e.map(function(e){return e.tournamentId}):this.tournamentBettingTypes.push({key:n,values:e.map(function(e){return e.tournamentId})})}}}]),e}(),s=v(c.prototype,"sportBettingTypeSettings",[r],{enumerable:!0,initializer:function(){return[]}}),u=v(c.prototype,"tournamentBettingTypes",[o],{enumerable:!0,initializer:function(){return[]}}),v(c.prototype,"updateSportBettingTypeSettings",[i],Object.getOwnPropertyDescriptor(c.prototype,"updateSportBettingTypeSettings"),c.prototype),v(c.prototype,"updateTournamentBettingTypes",[a],Object.getOwnPropertyDescriptor(c.prototype,"updateTournamentBettingTypes"),c.prototype),c);t.default=y},4781:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,o,i,a,c,s,u,l,f,p,d,h,b,v,y,g,m,S,w,_,O,x,k,j,C,T,P,E,I,A,R,z,M,D=ee(n(3)),H=ee(n(139)),N=ee(n(24)),L=ee(n(91)),F=function(){function e(e,t){for(var n=0;n0})}},{key:"selectedCompanyName",get:function(){return this.selectedCompany&&this.selectedCompany.length&&(1==this.selectedCompany.length?this.selectedCompany[0].name:this.localizationStore.localizationService.t("AGENCY_DEVICE_QUEUE.LIST.MULTIPLE_TAB_TITLE")+"("+this.selectedCompany.length+")")||this.localizationStore.localizationService.t("COMPANY.NOT_SELECTED.TITLE")}}]),F(e,[{key:"init",value:function(){var e=te(D.default.mark(function e(){return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:this.setConnectionCheck();case 1:case"end":return e.stop()}},e,this)}));return function(){return e.apply(this,arguments)}}()},{key:"mobileTreeData",value:function(){var e=te(D.default.mark(function e(){return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!localStorage.getItem("Gp-Working-Company")){e.next=5;break}return e.next=3,this.getAvailableCentrals();case 3:return e.next=5,this.getTreeData();case 5:case"end":return e.stop()}},e,this)}));return function(){return e.apply(this,arguments)}}()},{key:"onUserResolve",value:function(){var e=te(D.default.mark(function e(){var t=this;return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return this.timeZoneStore.setTimeZone(),e.next=3,this.getCompanies();case 3:return e.next=5,this.headerViewStore.getCashierNotifications();case 5:return e.next=7,(0,U.runInAction)(te(D.default.mark(function e(){return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return t.selectedCompany=t.companyStore.getSelectedCompany(),null!=t.userStore.agencyUser&&t.userStore.agencyUser.roles.length>0&&(t.companySelectViewStore.selectedCompany=t.selectedCompany||[t.companiesForModal[0]],t.companySelectViewStore.selectCompany()),e.next=4,t.mobileTreeData();case 4:case"end":return e.stop()}},e,t)})));case 7:case"end":return e.stop()}},e,this)}));return function(){return e.apply(this,arguments)}}()},{key:"setSelectedAgency",value:function(){var e=te(D.default.mark(function e(t){var n,r,o=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=arguments[2];return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.agencyStore.getAgency(t,!0);case 2:return n=e.sent,this.selectedAgency=n,r=this.routerStore.routerState,e.next=7,this.routerStore.goTo(new W.RouterState(r.routeName,Object.assign({},r.params,{agencyIdentifier:n&&n.accountRoute&&n.accountRoute.identifier?n.accountRoute.identifier:void 0}),r.queryParams));case 7:o&&this.routerStore.goTo(i.routeName,i&&i.paramObj||{});case 8:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"setAllCompaniesSelected",value:function(){var e=te(D.default.mark(function e(t){return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:this.allCompaniesSelected=!!t;case 1:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"setMultipleSelectedCompanies",value:function(){var e=te(D.default.mark(function e(t){return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:this.multipleSelectedCompanies=t;case 1:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"setHideHeaderControls",value:function(e){this.hideHeaderControls=!!e}},{key:"setupRouter",value:function(){var e=this;this.routerStore.setErrorHook(function(t){return e.errorStore.setError({title:t&&t.message?t.message:null,description:t&&t.stack?t.stack:null}),e.routerStore.goTo(new W.RouterState("error",{type:"router"}))}),this.historyAdapter=new W.HistoryAdapter(this.routerStore,q.history),this.historyAdapter.observeRouterStateChanges();var t=this.historyAdapter.history.location.pathname;""!==t&&"/"!==t||this.routerStore.goTo("master.platform.main.dashboard")}},{key:"navigateLogin",value:function(){return this.cacheService.clear(),this.routerStore.goTo("master.platform.membership.login")}},{key:"navigateHome",value:function(){return this.routerStore.goTo("master.platform.main.dashboard")}},{key:"createAgencyService",value:function(e){return new e(this.agency.baasic.apiClient)}},{key:"confirmFormModal",value:function(){var e=te(D.default.mark(function e(t,n,r){var o=this;return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",this.modalStore.showConfirm(this.localizationStore.localizationService.t("EDIT_FORM_LAYOUT.CONFIRMATION"),te(D.default.mark(function e(){return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if("goTo"!==t){e.next=4;break}o.routerStore.goTo(n),e.next=10;break;case 4:if(!t){e.next=9;break}return e.next=7,t(n,r,!0);case 7:e.next=10;break;case 9:o.routerStore.goBack();case 10:o.currentForm&&o.currentForm.update(o.currentForm.initials()),o.formChanged=!1;case 12:case"end":return e.stop()}},e,o)})),function(){o.modalStore.confirmParams.close()}));case 1:case"end":return e.stop()}},e,this)}));return function(t,n,r){return e.apply(this,arguments)}}()},{key:"routeChange",value:function(){var e=te(D.default.mark(function e(t){var n,r,o=t.fromState,i=t.toState,a=t.options;return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(this.setTitle(a.data.title),this.formChanged=!1,n=this.authStore,r=this.permissionStore,!o||"master.platform.membership.login"!==o.routeName||"error"!==i.routeName){e.next=5;break}return e.abrupt("return",Promise.reject(this.initialState));case 5:if(!1!==a.isPublic){e.next=11;break}if(n.isAuthenticated||"master.platform.membership.login"===i.routeName){e.next=9;break}return n.setSignInRedirect(i),e.abrupt("return",Promise.reject(new W.RouterState("master.platform.membership.login")));case 9:if(!(a.authorization.length>0&&(0,L.default)(a.authorization,function(e){return!r.hasPermission(e)}))&&r.hasPermission()){e.next=11;break}return e.abrupt("return",Promise.reject(new W.RouterState("unauthorized")));case 11:return e.abrupt("return",Promise.resolve());case 12:case"end":return e.stop()}},e,this)}));return function(t){return e.apply(this,arguments)}}()},{key:"onBeforeLogout",value:function(){this.menuStore.selectedSubmenu=[],this.menuStore.clearSubmenu(),this.headerViewStore.isMenuOpened=!1}},{key:"setTitle",value:function(e){null!=e?e!==this.title&&(0,$.faviconBuilder)(Y.localizationService.t(e)):(0,$.faviconBuilder)()}},{key:"getCompanies",value:function(){var e=te(D.default.mark(function e(){return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.companyStore.getCompanies();case 2:this.companiesForModal=e.sent;case 3:case"end":return e.stop()}},e,this)}));return function(){return e.apply(this,arguments)}}()},{key:"onReconnect",value:function(){this.hasInternetConnection=!0,this.notificationStore.success("Reconnected successfully")}},{key:"onDisconnect",value:function(){this.notificationStore.error("Connection lost"),this.navigateHome(),this.hasInternetConnection=!1}},{key:"getAvailableCentrals",value:function(){var e=te(D.default.mark(function e(){var t,n=this;return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(this.availableCentrals=[],!this.selectedCompany||!this.selectedCompany.length){e.next=6;break}return e.next=4,this.platform.companyModule.companyCacheService.getWithOrganizationStructure();case 4:t=e.sent,this.selectedCompany.forEach(function(e){var r,o=t.item.find(function(t){return t.id==e.id}),i=null!=o?o.roots.find(function(t){return t.id===e.rootId}):null;(r=n.availableCentrals).push.apply(r,ne(i.centrals))});case 6:case"end":return e.stop()}},e,this)}));return function(){return e.apply(this,arguments)}}()},{key:"getTreeData",value:function(){var e=te(D.default.mark(function e(){var t,n=this;return D.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!this.selectedCompany||!this.selectedCompany.length){e.next=5;break}return e.next=3,this.platform.companyModule.companyCacheService.getWithOrganizationStructure();case 3:t=e.sent,(0,U.runInAction)(function(){n.treeData=[].concat(ne(n.selectedCompany)),n.selectedCompany.forEach(function(e){var r=t.item.find(function(t){return t.id==e.id}),o=null!=r?r.roots.find(function(t){return t.id===e.rootId}):void 0;n.treeData.roots?n.treeData.roots.push(o):n.treeData.roots=[o]})});case 5:case"end":return e.stop()}},e,this)}));return function(){return e.apply(this,arguments)}}()},{key:"isCompanySelected",value:function(e){return this.selectedCompany&&this.selectedCompany.length&&this.selectedCompany.find(function(t){return t.companyAndRoot===e.companyAndRoot})}}]),e}(),_=oe(w.prototype,"activeScreen",[U.observable],{enumerable:!0,initializer:null}),O=oe(w.prototype,"selectedCompany",[U.observable],{enumerable:!0,initializer:function(){return[]}}),x=oe(w.prototype,"availableCentrals",[U.observable],{enumerable:!0,initializer:function(){return[]}}),k=oe(w.prototype,"treeData",[U.observable],{enumerable:!0,initializer:function(){return[]}}),j=oe(w.prototype,"selectedAgency",[U.observable],{enumerable:!0,initializer:null}),C=oe(w.prototype,"allCompaniesSelected",[U.observable],{enumerable:!0,initializer:function(){return!0}}),T=oe(w.prototype,"multipleSelectedCompanies",[r],{enumerable:!0,initializer:function(){return[]}}),P=oe(w.prototype,"hideHeaderControls",[U.observable],{enumerable:!0,initializer:function(){return!1}}),E=oe(w.prototype,"formChanged",[U.observable],{enumerable:!0,initializer:function(){return!1}}),I=oe(w.prototype,"currentForm",[U.observable],{enumerable:!0,initializer:function(){return null}}),A=oe(w.prototype,"isSidebarExpanded",[U.observable],{enumerable:!0,initializer:function(){return!0}}),R=oe(w.prototype,"hasInternetConnection",[U.observable],{enumerable:!0,initializer:function(){return!0}}),z=oe(w.prototype,"cashierNotifications",[U.observable],{enumerable:!0,initializer:function(){return null}}),oe(w.prototype,"isOnLiveScreen",[U.computed],Object.getOwnPropertyDescriptor(w.prototype,"isOnLiveScreen"),w.prototype),oe(w.prototype,"hasTreeData",[U.computed],Object.getOwnPropertyDescriptor(w.prototype,"hasTreeData"),w.prototype),oe(w.prototype,"selectedCompanyName",[U.computed],Object.getOwnPropertyDescriptor(w.prototype,"selectedCompanyName"),w.prototype),oe(w.prototype,"init",[o],Object.getOwnPropertyDescriptor(w.prototype,"init"),w.prototype),oe(w.prototype,"mobileTreeData",[i],Object.getOwnPropertyDescriptor(w.prototype,"mobileTreeData"),w.prototype),oe(w.prototype,"onUserResolve",[a],Object.getOwnPropertyDescriptor(w.prototype,"onUserResolve"),w.prototype),oe(w.prototype,"setSelectedAgency",[c],Object.getOwnPropertyDescriptor(w.prototype,"setSelectedAgency"),w.prototype),oe(w.prototype,"setAllCompaniesSelected",[s],Object.getOwnPropertyDescriptor(w.prototype,"setAllCompaniesSelected"),w.prototype),oe(w.prototype,"setMultipleSelectedCompanies",[u],Object.getOwnPropertyDescriptor(w.prototype,"setMultipleSelectedCompanies"),w.prototype),oe(w.prototype,"setHideHeaderControls",[l],Object.getOwnPropertyDescriptor(w.prototype,"setHideHeaderControls"),w.prototype),oe(w.prototype,"routeChange",[f],Object.getOwnPropertyDescriptor(w.prototype,"routeChange"),w.prototype),oe(w.prototype,"onBeforeLogout",[p],Object.getOwnPropertyDescriptor(w.prototype,"onBeforeLogout"),w.prototype),oe(w.prototype,"setTitle",[d],Object.getOwnPropertyDescriptor(w.prototype,"setTitle"),w.prototype),oe(w.prototype,"getCompanies",[h],Object.getOwnPropertyDescriptor(w.prototype,"getCompanies"),w.prototype),M=oe(w.prototype,"clearCache",[b],{enumerable:!0,initializer:function(){var e=this;return function(t){e.cacheService.clearRegion(Y.CacheRegions.GPCompany),e.cacheService.clearRegion(Y.CacheRegions.GPCompanyOrgStruct),e.cacheService.clearRegion(Y.CacheRegions.GPCompanyRoot),e.cacheService.clearRegion(Y.CacheRegions.GPCentral),e.cacheService.clearRegion(Y.CacheRegions.GPAgency),e.cacheService.clearRegion(Y.CacheRegions.GPSport),t||(e.allCompaniesSelected=!0,e.multipleSelectedCompanies=[],e.companyStore.unregister(),e.selectedCompany=null,e.agencyStore.unregister(),e.selectedAgency=null)}}}),oe(w.prototype,"onReconnect",[v],Object.getOwnPropertyDescriptor(w.prototype,"onReconnect"),w.prototype),oe(w.prototype,"onDisconnect",[y],Object.getOwnPropertyDescriptor(w.prototype,"onDisconnect"),w.prototype),oe(w.prototype,"getAvailableCentrals",[g],Object.getOwnPropertyDescriptor(w.prototype,"getAvailableCentrals"),w.prototype),oe(w.prototype,"getTreeData",[m],Object.getOwnPropertyDescriptor(w.prototype,"getTreeData"),w.prototype),oe(w.prototype,"isCompanySelected",[S],Object.getOwnPropertyDescriptor(w.prototype,"isCompanySelected"),w.prototype),w);function ae(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];if(e&&t){var r=(0,N.default)(n)?n:[n];(0,H.default)(t,function(t,n){(0,L.default)(r,function(e){return e===n})||(e[n]=t)})}}t.default=ie},4782:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(4783);Object.defineProperty(t,"BetSlipMonitoringHub",{enumerable:!0,get:function(){return p(r).default}});var o=n(1875);Object.defineProperty(t,"BetSlipMonitoringHubStore",{enumerable:!0,get:function(){return p(o).default}});var i=n(1898);Object.defineProperty(t,"LiveOfferBetaHubStore",{enumerable:!0,get:function(){return p(i).default}});var a=n(1899);Object.defineProperty(t,"LiveOfferHubStore",{enumerable:!0,get:function(){return p(a).default}});var c=n(4833);Object.defineProperty(t,"LiveOfferHub",{enumerable:!0,get:function(){return p(c).default}});var s=n(1900);Object.defineProperty(t,"MessageHubStore",{enumerable:!0,get:function(){return p(s).default}});var u=n(4834);Object.defineProperty(t,"MessageCenterHub",{enumerable:!0,get:function(){return p(u).default}});var l=n(1901);Object.defineProperty(t,"PaymentHubStore",{enumerable:!0,get:function(){return p(l).default}});var f=n(4835);function p(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"PaymentHub",{enumerable:!0,get:function(){return p(f).default}})},4783:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,o,i,a,c,s,u,l,f,p=function(){function e(e,t){for(var n=0;n1)this.connection=null;else{var n=this.connection,r=e._connection;this.connection=null,!r||n&&r!==n||r.unsubscribe()}}else this.connection=null},t}(o.a)},4788:function(e,t,n){"use strict";n.d(t,"a",function(){return u});var r=n(34),o=n(106),i=n(79),a=n(38),c=n(282);o.a;var s=function(e){function t(t,n,r){var o=e.call(this,n)||this;return o.key=t,o.group=n,o.parent=r,o}return r.__extends(t,e),t.prototype._next=function(e){this.complete()},t.prototype._unsubscribe=function(){var e=this.parent,t=this.key;this.key=this.parent=null,e&&e.removeGroup(t)},t}(o.a),u=function(e){function t(t,n,r){var o=e.call(this)||this;return o.key=t,o.groupSubject=n,o.refCountSubscription=r,o}return r.__extends(t,e),t.prototype._subscribe=function(e){var t=new i.a,n=this.refCountSubscription,r=this.groupSubject;return n&&!n.closed&&t.add(new l(n)),t.add(r.subscribe(e)),t},t}(a.a),l=function(e){function t(t){var n=e.call(this)||this;return n.parent=t,t.count++,n}return r.__extends(t,e),t.prototype.unsubscribe=function(){var t=this.parent;t.closed||this.closed||(e.prototype.unsubscribe.call(this),t.count-=1,0===t.count&&t.attemptedToUnsubscribe&&t.unsubscribe())},t}(i.a)},4789:function(e,t,n){"use strict";n.d(t,"a",function(){return a});var r=n(34),o=n(282),i=n(516),a=function(e){function t(t){var n=e.call(this)||this;return n._value=t,n}return r.__extends(t,e),Object.defineProperty(t.prototype,"value",{get:function(){return this.getValue()},enumerable:!0,configurable:!0}),t.prototype._subscribe=function(t){var n=e.prototype._subscribe.call(this,t);return n&&!n.closed&&t.next(this._value),n},t.prototype.getValue=function(){if(this.hasError)throw this.thrownError;if(this.closed)throw new i.a;return this._value},t.prototype.next=function(t){e.prototype.next.call(this,this._value=t)},t}(o.a)},4790:function(e,t,n){"use strict";n.d(t,"a",function(){return l});var r=n(34),o=n(282),i=n(1882),a=n(79),c=n(4794),s=n(516),u=n(1881),l=function(e){function t(t,n,r){void 0===t&&(t=Number.POSITIVE_INFINITY),void 0===n&&(n=Number.POSITIVE_INFINITY);var o=e.call(this)||this;return o.scheduler=r,o._events=[],o._infiniteTimeWindow=!1,o._bufferSize=t<1?1:t,o._windowTime=n<1?1:n,n===Number.POSITIVE_INFINITY?(o._infiniteTimeWindow=!0,o.next=o.nextInfiniteTimeWindow):o.next=o.nextTimeWindow,o}return r.__extends(t,e),t.prototype.nextInfiniteTimeWindow=function(t){var n=this._events;n.push(t),n.length>this._bufferSize&&n.shift(),e.prototype.next.call(this,t)},t.prototype.nextTimeWindow=function(t){this._events.push(new f(this._getNow(),t)),this._trimBufferThenGetEvents(),e.prototype.next.call(this,t)},t.prototype._subscribe=function(e){var t,n=this._infiniteTimeWindow,r=n?this._events:this._trimBufferThenGetEvents(),o=this.scheduler,i=r.length;if(this.closed)throw new s.a;if(this.isStopped||this.hasError?t=a.a.EMPTY:(this.observers.push(e),t=new u.a(this,e)),o&&e.add(e=new c.a(e,o)),n)for(var l=0;lt&&(i=Math.max(i,o-t)),i>0&&r.splice(0,i),r},t}(o.a),f=function(){return function(e,t){this.time=e,this.value=t}}()},4791:function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=n(34),o=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.scheduler=t,r.work=n,r}return r.__extends(t,e),t.prototype.schedule=function(t,n){return void 0===n&&(n=0),n>0?e.prototype.schedule.call(this,t,n):(this.delay=n,this.state=t,this.scheduler.flush(this),this)},t.prototype.execute=function(t,n){return n>0||this.closed?e.prototype.execute.call(this,t,n):this._execute(t,n)},t.prototype.requestAsyncId=function(t,n,r){return void 0===r&&(r=0),null!==r&&r>0||null===r&&this.delay>0?e.prototype.requestAsyncId.call(this,t,n,r):t.flush(this)},t}(n(384).a)},4792:function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=n(34),o=function(e){function t(t,n){return e.call(this)||this}return r.__extends(t,e),t.prototype.schedule=function(e,t){return void 0===t&&(t=0),this},t}(n(79).a)},4793:function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=n(34),o=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r.__extends(t,e),t}(n(385).a)},4794:function(e,t,n){"use strict";n.d(t,"a",function(){return a});var r=n(34),o=n(106),i=n(1884);var a=function(e){function t(t,n,r){void 0===r&&(r=0);var o=e.call(this,t)||this;return o.scheduler=n,o.delay=r,o}return r.__extends(t,e),t.dispatch=function(e){var t=e.notification,n=e.destination;t.observe(n),this.unsubscribe()},t.prototype.scheduleMessage=function(e){this.destination.add(this.scheduler.schedule(t.dispatch,this.delay,new c(e,this.destination)))},t.prototype._next=function(e){this.scheduleMessage(i.a.createNext(e))},t.prototype._error=function(e){this.scheduleMessage(i.a.createError(e)),this.unsubscribe()},t.prototype._complete=function(){this.scheduleMessage(i.a.createComplete()),this.unsubscribe()},t}(o.a),c=function(){return function(e,t){this.notification=e,this.destination=t}}()},4795:function(e,t,n){"use strict";t.a=function(e){var t=new r.a(function(t){t.next(e),t.complete()});return t._isScalar=!0,t.value=e,t};var r=n(38)},4796:function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=n(4797),o=new(n(4799).a)(r.a)},4797:function(e,t,n){"use strict";n.d(t,"a",function(){return i});var r=n(34),o=n(4798),i=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.scheduler=t,r.work=n,r}return r.__extends(t,e),t.prototype.requestAsyncId=function(t,n,r){return void 0===r&&(r=0),null!==r&&r>0?e.prototype.requestAsyncId.call(this,t,n,r):(t.actions.push(this),t.scheduled||(t.scheduled=o.a.setImmediate(t.flush.bind(t,null))))},t.prototype.recycleAsyncId=function(t,n,r){if(void 0===r&&(r=0),null!==r&&r>0||null===r&&this.delay>0)return e.prototype.recycleAsyncId.call(this,t,n,r);0===t.actions.length&&(o.a.clearImmediate(n),t.scheduled=void 0)},t}(n(384).a)},4798:function(e,t,n){"use strict";n.d(t,"a",function(){return i});var r=1,o={};var i={setImmediate:function(e){var t=r++;return o[t]=e,Promise.resolve().then(function(){return function(e){var t=o[e];t&&t()}(t)}),t},clearImmediate:function(e){delete o[e]}}},4799:function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=n(34),o=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r.__extends(t,e),t.prototype.flush=function(e){this.active=!0,this.scheduled=void 0;var t,n=this.actions,r=-1,o=n.length;e=e||n.shift();do{if(t=e.execute(e.state,e.delay))break}while(++r0?e.prototype.requestAsyncId.call(this,t,n,r):(t.actions.push(this),t.scheduled||(t.scheduled=requestAnimationFrame(function(){return t.flush(null)})))},t.prototype.recycleAsyncId=function(t,n,r){if(void 0===r&&(r=0),null!==r&&r>0||null===r&&this.delay>0)return e.prototype.recycleAsyncId.call(this,t,n,r);0===t.actions.length&&(cancelAnimationFrame(n),t.scheduled=void 0)},t}(n(384).a)},4802:function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=n(34),o=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r.__extends(t,e),t.prototype.flush=function(e){this.active=!0,this.scheduled=void 0;var t,n=this.actions,r=-1,o=n.length;e=e||n.shift();do{if(t=e.execute(e.state,e.delay))break}while(++rt.index?1:-1:e.delay>t.delay?1:-1},t}(o.a)},4804:function(e,t,n){"use strict";t.a=function(e){return!!e&&(e instanceof r.a||"function"===typeof e.lift&&"function"===typeof e.subscribe)};var r=n(38)},4805:function(e,t,n){"use strict";function r(){return Error.call(this),this.message="argument out of range",this.name="ArgumentOutOfRangeError",this}n.d(t,"a",function(){return o}),r.prototype=Object.create(Error.prototype);var o=r},4806:function(e,t,n){"use strict";function r(){return Error.call(this),this.message="no elements in sequence",this.name="EmptyError",this}n.d(t,"a",function(){return o}),r.prototype=Object.create(Error.prototype);var o=r},4807:function(e,t,n){"use strict";function r(){return Error.call(this),this.message="Timeout has occurred",this.name="TimeoutError",this}n.d(t,"a",function(){return o}),r.prototype=Object.create(Error.prototype);var o=r},4808:function(e,t,n){"use strict";t.a=function e(t,n,l){if(n){if(!Object(s.a)(n))return function(){for(var r=[],o=0;o0?this._next(t.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()},t}(i.a)},4819:function(e,t,n){"use strict";t.a=function e(){var t=[];for(var n=0;n1?e.next(Array.prototype.slice.call(arguments)):e.next(t)},e,c)})};var r=n(38),o=n(118),i=n(514),a=n(284);Object.prototype.toString},4821:function(e,t,n){"use strict";t.a=function e(t,n,c){if(c)return e(t,n).pipe(Object(a.a)(function(e){return Object(o.a)(e)?c.apply(void 0,e):c(e)}));return new r.a(function(e){var r,o=function(){for(var t=[],n=0;n1&&"number"===typeof e[e.length-1]&&(n=e.pop())):"number"===typeof s&&(n=e.pop());if(null===c&&1===e.length&&e[0]instanceof r.a)return e[0];return Object(i.a)(n)(Object(a.a)(e,c))};var r=n(38),o=n(175),i=n(1894),a=n(283)},4826:function(e,t,n){"use strict";t.a=function e(){var t=[];for(var n=0;n=t){r.complete();break}if(r.next(a++),r.closed)break}})};var r=n(38);function o(e){var t=e.start,n=e.index,r=e.count,o=e.subscriber;n>=r?o.complete():(o.next(t),o.closed||(e.index=n+1,e.start=t+1,this.schedule(e)))}},4830:function(e,t,n){"use strict";t.a=function(e,t,n){void 0===e&&(e=0);var s=-1;Object(i.a)(t)?s=Number(t)<1?1:Number(t):Object(a.a)(t)&&(n=t);Object(a.a)(n)||(n=o.a);return new r.a(function(t){var r=Object(i.a)(e)?e:+e-n.now();return n.schedule(c,r,{index:0,period:s,subscriber:t})})};var r=n(38),o=n(1037),i=n(1896),a=n(175);function c(e){var t=e.index,n=e.period,r=e.subscriber;if(r.next(t),!r.closed){if(-1===n)return r.complete();e.index=t+1,this.schedule(e,n)}}},4831:function(e,t,n){"use strict";t.a=function(e,t){return new r.a(function(n){var r,a;try{r=e()}catch(e){return void n.error(e)}try{a=t(r)}catch(e){return void n.error(e)}var c=a?Object(o.a)(a):i.a,s=c.subscribe(n);return function(){s.unsubscribe(),r&&r.unsubscribe()}})};var r=n(38),o=n(285),i=n(149)},4832:function(e,t,n){"use strict";t.a=function(){for(var e=[],t=0;tthis.index},e.prototype.hasCompleted=function(){return this.array.length===this.index},e}(),h=function(e){function t(t,n,r){var o=e.call(this,t)||this;return o.parent=n,o.observable=r,o.stillUnsubscribed=!0,o.buffer=[],o.isComplete=!1,o}return r.__extends(t,e),t.prototype[u.a]=function(){return this},t.prototype.next=function(){var e=this.buffer;return 0===e.length&&this.isComplete?{value:null,done:!0}:{value:e.shift(),done:!1}},t.prototype.hasValue=function(){return this.buffer.length>0},t.prototype.hasCompleted=function(){return 0===this.buffer.length&&this.isComplete},t.prototype.notifyComplete=function(){this.buffer.length>0?(this.isComplete=!0,this.parent.notifyInactive()):this.destination.complete()},t.prototype.notifyNext=function(e,t,n,r,o){this.buffer.push(t),this.parent.checkIterators()},t.prototype.subscribe=function(e,t){return Object(s.a)(this,this.observable,this,t)},t}(c.a)},4833:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,o,i,a,c,s,u,l,f=function(){function e(e,t){for(var n=0;n<\/script>.")}},"function"==typeof u.on?u.on("load",function(){s=!0}):u.load(function(){s=!0}),o.fn=o.prototype={init:function(t,n,r){var o=e(this);this.url=t,this.qs=n,this.lastError=null,this._={keepAliveData:{},connectingMessageBuffer:new function(t,n){var r=[];this.tryBuffer=function(n){return t.state===e.signalR.connectionState.connecting&&(r.push(n),!0)},this.drain=function(){if(t.state===e.signalR.connectionState.connected)for(;r.length>0;)n(r.shift())},this.clear=function(){r=[]}}(this,function(e){o.triggerHandler(l.onReceived,[e])}),lastMessageAt:(new Date).getTime(),lastActiveAt:(new Date).getTime(),beatInterval:5e3,beatHandle:null,totalTransportConnectTimeout:0,redirectQs:null},"boolean"===typeof r&&(this.logging=r)},_parseResponse:function(e){return e&&"string"===typeof e?this.json.parse(e):e},_originalJson:t.JSON,json:t.JSON,isCrossDomain:function(n,r){var o;return n=e.trim(n),r=r||t.location,0===n.indexOf("http")&&((o=t.document.createElement("a")).href=n,o.protocol+d(o.protocol,o.host)!==r.protocol+d(r.protocol,r.host))},ajaxDataType:"text",contentType:"application/json; charset=UTF-8",logging:!1,state:o.connectionState.disconnected,clientProtocol:"2.1",supportedProtocols:["1.5","2.0","2.1"],negotiateRedirectSupportedProtocols:["2.0","2.1"],reconnectDelay:2e3,transportConnectTimeout:0,disconnectTimeout:3e4,reconnectWindow:3e4,keepAliveWarnAt:2/3,start:function(n,i){var a,c=this,d={pingInterval:3e5,waitForPageLoad:!0,transport:"auto",jsonp:!1},h=c._deferral||e.Deferred(),b=t.document.createElement("a"),v=function(n,r){n.url===r&&n.baseUrl||(n.url=r,b.href=n.url,b.protocol&&":"!==b.protocol?(n.protocol=b.protocol,n.host=b.host):(n.protocol=t.document.location.protocol,n.host=b.host||t.document.location.host),n.baseUrl=n.protocol+"//"+n.host,n.wsProtocol="https:"===n.protocol?"wss://":"ws://",0===n.url.indexOf("//")&&(n.url=t.location.protocol+n.url,n.log("Protocol relative URL detected, normalizing it to '"+n.url+"'.")),n.isCrossDomain(n.url)&&(n.log("Auto detected cross domain url."),"auto"===d.transport&&(d.transport=["webSockets","serverSentEvents","longPolling"]),"undefined"===typeof n.withCredentials&&(n.withCredentials=!0),e.support.cors||(n.ajaxDataType="jsonp",n.log("Using jsonp because this browser doesn't support CORS.")),n.contentType=o._.defaultContentType))};if(c.lastError=null,c._deferral=h,!c.json)throw new Error("SignalR: No JSON parser found. Please ensure json2.js is referenced before the SignalR.js file if you need to support clients without native JSON parsing support, e.g. IE<8.");if("function"===e.type(n)?i=n:"object"===e.type(n)&&(e.extend(d,n),"function"===e.type(d.callback)&&(i=d.callback)),d.transport=function(t,n){if(e.isArray(t)){for(var r=t.length-1;r>=0;r--){var i=t[r];"string"===e.type(i)&&o.transports[i]||(n.log("Invalid transport: "+i+", removing it from the transports list."),t.splice(r,1))}0===t.length&&(n.log("No transports remain within the specified transport array."),t=null)}else if(o.transports[t]||"auto"===t){if("auto"===t&&o._.ieVersion<=8)return["longPolling"]}else n.log("Invalid transport: "+t.toString()+"."),t=null;return t}(d.transport,c),!d.transport)throw new Error("SignalR: Invalid transport(s) specified, aborting start.");if(c._.config=d,!s&&!0===d.waitForPageLoad)return c._.deferredStartHandler=function(){c.start(n,i)},u.bind("load",c._.deferredStartHandler),h.promise();if(c.state===o.connectionState.connecting)return h.promise();if(!1===f(c,o.connectionState.disconnected,o.connectionState.connecting))return h.resolve(c),h.promise();!function(n){var r,i;n._.configuredStopReconnectingTimeout||(i=function(t){var n=o._.format(o.resources.reconnectTimeout,t.disconnectTimeout);t.log(n),e(t).triggerHandler(l.onError,[o._.error(n,"TimeoutException")]),t.stop(!1,!1)},n.reconnecting(function(){var e=this;e.state===o.connectionState.reconnecting&&(r=t.setTimeout(function(){i(e)},e.disconnectTimeout))}),n.stateChanged(function(e){e.oldState===o.connectionState.reconnecting&&t.clearTimeout(r)}),n._.configuredStopReconnectingTimeout=!0)}(c),"auto"===d.transport&&!0===d.jsonp&&(d.transport="longPolling"),c.withCredentials=d.withCredentials,c._originalUrl=c.url,c.ajaxDataType=d.jsonp?"jsonp":"text",v(c,c.url),e(c).bind(l.onStart,function(t,n){"function"===e.type(i)&&i.call(c),h.resolve(c)}),c._.initHandler=o.transports._logic.initHandler(c),a=function(n,i){var s=o._.error(r.noTransportOnInit);if((i=i||0)>=n.length)return 0===i?c.log("No transports supported by the server were selected."):1===i?c.log("No fallback transports were selected."):c.log("Fallback transports exhausted."),e(c).triggerHandler(l.onError,[s]),h.reject(s),void c.stop();if(c.state!==o.connectionState.disconnected){var d=n[i],b=o.transports[d],v=function(){a(n,i+1)};c.transport=b;try{c._.initHandler.start(b,function(){var n=o._.firefoxMajorVersion(t.navigator.userAgent)>=11;c.log("The start request succeeded. Transitioning to the connected state."),p(c)&&o.transports._logic.monitorKeepAlive(c),c._.keepAliveData.activated&&o.transports._logic.startHeartbeat(c),o._.configurePingInterval(c),f(c,o.connectionState.connecting,o.connectionState.connected)||c.log("WARNING! The connection was not in the connecting state."),c._.connectingMessageBuffer.drain(),e(c).triggerHandler(l.onStart),u.bind("unload",function(){c.log("Window unloading, stopping the connection."),c.stop(!0)}),n&&u.bind("beforeunload",function(){t.setTimeout(function(){c.stop(!0)},0)})},v)}catch(e){c.log(b.name+" transport threw '"+e.message+"' when attempting to start."),v()}}};var y=c.url+"/negotiate",g=function(t,n){var i=o._.error(r.errorOnNegotiate,t,n._.negotiateRequest);e(n).triggerHandler(l.onError,i),h.reject(i),n.stop()};return e(c).triggerHandler(l.onStarting),y=o.transports._logic.prepareQueryString(c,y),c.log("Negotiating with '"+y+"'."),c._.negotiateRequest=function(){var t,n,i,s=0,u=[],f=[],p=function(e,t){var n=o.transports._logic.prepareQueryString(e,e.url+"/negotiate");e.log("Negotiating with '"+n+"'.");var i={url:n,error:function(t,n){"__Negotiate Aborted__"!==n?g(t,e):h.reject(o._.error(r.stoppedWhileNegotiating,null,e._.negotiateRequest))},success:t};return e.accessToken&&(i.headers={Authorization:"Bearer "+e.accessToken}),o.transports._logic.ajax(e,i)},b=function(y){try{t=c._parseResponse(y)}catch(e){return void g(o._.error(r.errorParsingNegotiateResponse,e),c)}if(t.availableTransports)return i=o._.error(r.aspnetCoreSignalrServer),e(c).triggerHandler(l.onError,[i]),void h.reject(i);if(!t.ProtocolVersion||-1===c.supportedProtocols.indexOf(t.ProtocolVersion))return i=o._.error(o._.format(r.protocolIncompatible,c.clientProtocol,t.ProtocolVersion)),e(c).triggerHandler(l.onError,[i]),void h.reject(i);if(-1!==c.negotiateRedirectSupportedProtocols.indexOf(t.ProtocolVersion)){if(t.Error)return i=o._.error(o._.format(r.errorFromServer,t.Error)),e(c).triggerHandler(l.onError,[i]),void h.reject(i);if(t.RedirectUrl){if(100===s)return void g(o._.error(r.errorRedirectionExceedsLimit),c);"auto"===d.transport&&(d.transport=["webSockets","serverSentEvents","longPolling"]),c.log("Received redirect to: "+t.RedirectUrl),c.accessToken=t.AccessToken;var m=t.RedirectUrl.split("?",2);return v(c,m[0]),c._.redirectQs=2===m.length?m[1]:null,"jsonp"===c.ajaxDataType&&c.accessToken?void g(o._.error(r.jsonpNotSupportedWithAccessToken),c):(s++,void p(c,b))}}n=c._.keepAliveData,c.appRelativeUrl=t.Url,c.id=t.ConnectionId,c.token=t.ConnectionToken,c.webSocketServerUrl=t.WebSocketServerUrl,c._.pollTimeout=1e3*t.ConnectionTimeout+1e4,c.disconnectTimeout=1e3*t.DisconnectTimeout,c._.totalTransportConnectTimeout=c.transportConnectTimeout+1e3*t.TransportConnectTimeout,t.KeepAliveTimeout?(n.activated=!0,n.timeout=1e3*t.KeepAliveTimeout,n.timeoutWarning=n.timeout*c.keepAliveWarnAt,c._.beatInterval=(n.timeout-n.timeoutWarning)/3):n.activated=!1,c.reconnectWindow=c.disconnectTimeout+(n.timeout||0),e.each(o.transports,function(e){if(0===e.indexOf("_")||"webSockets"===e&&!t.TryWebSockets)return!0;f.push(e)}),e.isArray(d.transport)?e.each(d.transport,function(t,n){e.inArray(n,f)>=0&&u.push(n)}):"auto"===d.transport?u=f:e.inArray(d.transport,f)>=0&&u.push(d.transport),a(u)};return p(c,b)}(),h.promise()},starting:function(t){var n=this;return e(n).bind(l.onStarting,function(e,r){t.call(n)}),n},send:function(e){if(this.state===o.connectionState.disconnected)throw new Error("SignalR: Connection must be started before data can be sent. Call .start() before .send()");if(this.state===o.connectionState.connecting)throw new Error("SignalR: Connection has not been fully initialized. Use .start().done() or .start().fail() to run logic after the connection has started.");return this.transport.send(this,e),this},received:function(t){var n=this;return e(n).bind(l.onReceived,function(e,r){t.call(n,r)}),n},stateChanged:function(t){var n=this;return e(n).bind(l.onStateChanged,function(e,r){t.call(n,r)}),n},error:function(t){var n=this;return e(n).bind(l.onError,function(e,r,o){n.lastError=r,t.call(n,r,o)}),n},disconnected:function(t){var n=this;return e(n).bind(l.onDisconnect,function(e,r){t.call(n)}),n},connectionSlow:function(t){var n=this;return e(n).bind(l.onConnectionSlow,function(e,r){t.call(n)}),n},reconnecting:function(t){var n=this;return e(n).bind(l.onReconnecting,function(e,r){t.call(n)}),n},reconnected:function(t){var n=this;return e(n).bind(l.onReconnect,function(e,r){t.call(n)}),n},stop:function(n,i){var a=this._deferral;return this._.deferredStartHandler&&u.unbind("load",this._.deferredStartHandler),delete this._.config,delete this._.deferredStartHandler,s||this._.config&&!0!==this._.config.waitForPageLoad?this.state!==o.connectionState.disconnected?(this.log("Stopping connection."),t.clearTimeout(this._.beatHandle),t.clearInterval(this._.pingIntervalId),this.transport&&(this.transport.stop(this),!1!==i&&this.transport.abort(this,n),p(this)&&o.transports._logic.stopMonitoringKeepAlive(this),this.transport=null),this._.negotiateRequest&&(this._.negotiateRequest.abort("__Negotiate Aborted__"),delete this._.negotiateRequest),this._.initHandler&&this._.initHandler.stop(),delete this._deferral,delete this.messageId,delete this.groupsToken,delete this.id,delete this._.pingIntervalId,delete this._.lastMessageAt,delete this._.lastActiveAt,this._.connectingMessageBuffer.clear(),e(this).unbind(l.onStart),delete this.accessToken,delete this.protocol,delete this.host,delete this.baseUrl,delete this.wsProtocol,delete this.contentType,this.url=this._originalUrl,this._.redirectQs=null,f(this,this.state,o.connectionState.disconnected),e(this).triggerHandler(l.onDisconnect),this):void 0:(this.log("Stopping connection prior to negotiate."),void(a&&a.reject(o._.error(r.stoppedWhileLoading))))},log:function(e){!function(e,n){var r;!1!==n&&"undefined"!==typeof t.console&&(r="["+(new Date).toTimeString()+"] SignalR: "+e,t.console.debug?t.console.debug(r):t.console.log&&t.console.log(r))}(e,this.logging)}},o.fn.init.prototype=o.fn,o.noConflict=function(){return e.connection===o&&(e.connection=i),o},e.connection&&(i=e.connection),e.connection=e.signalR=o}(window.jQuery,window),function(e,t,n){var r,o=e.signalR,i=e.signalR.events,a=e.signalR.changeState;function c(n){n._.keepAliveData.monitoring&&function(t){var n,r=t._.keepAliveData;t.state===o.connectionState.connected&&((n=(new Date).getTime()-t._.lastMessageAt)>=r.timeout?(t.log("Keep alive timed out. Notifying transport that connection has been lost."),t.transport.lostConnection(t)):n>=r.timeoutWarning?r.userNotified||(t.log("Keep alive has been missed, connection may be dead/slow."),e(t).triggerHandler(i.onConnectionSlow),r.userNotified=!0):r.userNotified=!1)}(n),r.markActive(n)&&(n._.beatHandle=t.setTimeout(function(){c(n)},n._.beatInterval))}function s(e,t){var n=e.url+t;return e.transport&&(n+="?transport="+e.transport.name),r.prepareQueryString(e,n)}function u(e){this.connection=e,this.startRequested=!1,this.startCompleted=!1,this.connectionStopped=!1}o.transports={},u.prototype={start:function(e,n,r){var o=this,i=o.connection,a=!1;o.startRequested||o.connectionStopped?i.log("WARNING! "+e.name+" transport cannot be started. Initialization ongoing or completed."):(i.log(e.name+" transport starting."),e.start(i,function(){a||o.initReceived(e,n)},function(t){return a||(a=!0,o.transportFailed(e,t,r)),!o.startCompleted||o.connectionStopped}),o.transportTimeoutHandle=t.setTimeout(function(){a||(a=!0,i.log(e.name+" transport timed out when trying to connect."),o.transportFailed(e,void 0,r))},i._.totalTransportConnectTimeout))},stop:function(){this.connectionStopped=!0,t.clearTimeout(this.transportTimeoutHandle),o.transports._logic.tryAbortStartRequest(this.connection)},initReceived:function(e,n){var r=this,i=r.connection;r.startRequested?i.log("WARNING! The client received multiple init messages."):r.connectionStopped||(r.startRequested=!0,t.clearTimeout(r.transportTimeoutHandle),i.log(e.name+" transport connected. Initiating start request."),o.transports._logic.ajaxStart(i,function(){r.startCompleted=!0,n()}))},transportFailed:function(n,r,a){var c,s=this.connection,u=s._deferral;this.connectionStopped||(t.clearTimeout(this.transportTimeoutHandle),this.startRequested?this.startCompleted||(c=o._.error(o.resources.errorDuringStartRequest,r),s.log(n.name+" transport failed during the start request. Stopping the connection."),e(s).triggerHandler(i.onError,[c]),u&&u.reject(c),s.stop()):(n.stop(s),s.log(n.name+" transport failed to connect. Attempting to fall back."),a()))}},r=o.transports._logic={ajax:function(t,n){return e.ajax(e.extend(!0,{},e.signalR.ajaxDefaults,{type:"GET",data:{},xhrFields:{withCredentials:t.withCredentials},contentType:t.contentType,dataType:t.ajaxDataType},n))},pingServer:function(t){var n,i,a=e.Deferred();return t.transport?(n=t.url+"/ping",n=r.addQs(n,t.qs),i=r.ajax(t,{url:n,headers:t.accessToken?{Authorization:"Bearer "+t.accessToken}:{},success:function(e){var n;try{n=t._parseResponse(e)}catch(e){return a.reject(o._.transportError(o.resources.pingServerFailedParse,t.transport,e,i)),void t.stop()}"pong"===n.Response?a.resolve():a.reject(o._.transportError(o._.format(o.resources.pingServerFailedInvalidResponse,e),t.transport,null,i))},error:function(e){401===e.status||403===e.status?(a.reject(o._.transportError(o._.format(o.resources.pingServerFailedStatusCode,e.status),t.transport,e,i)),t.stop()):a.reject(o._.transportError(o.resources.pingServerFailed,t.transport,e,i))}})):a.reject(o._.transportError(o.resources.noConnectionTransport,t.transport)),a.promise()},prepareQueryString:function(e,n){var o;return o=r.addQs(n,"clientProtocol="+e.clientProtocol),o="string"===typeof e._.redirectQs?r.addQs(o,e._.redirectQs):r.addQs(o,e.qs),e.token&&(o+="&connectionToken="+t.encodeURIComponent(e.token)),e.data&&(o+="&connectionData="+t.encodeURIComponent(e.data)),o},addQs:function(t,n){var r,o=-1!==t.indexOf("?")?"&":"?";if(!n)return t;if("object"===typeof n)return t+o+e.param(n);if("string"===typeof n)return"?"!==(r=n.charAt(0))&&"&"!==r||(o=""),t+o+n;throw new Error("Query string property must be either a string or object.")},getUrl:function(e,n,o,i,a){var c=("webSockets"===n?"":e.baseUrl)+e.appRelativeUrl,s="transport="+n;return!a&&e.groupsToken&&(s+="&groupsToken="+t.encodeURIComponent(e.groupsToken)),o?(c+=i?"/poll":"/reconnect",!a&&e.messageId&&(s+="&messageId="+t.encodeURIComponent(e.messageId))):c+="/connect",c+="?"+s,c=r.prepareQueryString(e,c),e.transport&&e.accessToken&&("serverSentEvents"!==e.transport.name&&"webSockets"!==e.transport.name||(c+="&access_token="+t.encodeURIComponent(e.accessToken))),a||(c+="&tid="+Math.floor(11*Math.random())),c},maximizePersistentResponse:function(e){return{MessageId:e.C,Messages:e.M,Initialized:"undefined"!==typeof e.S,ShouldReconnect:"undefined"!==typeof e.T,LongPollDelay:e.L,GroupsToken:e.G,Error:e.E}},updateGroups:function(e,t){t&&(e.groupsToken=t)},stringifySend:function(e,t){return"string"===typeof t||"undefined"===typeof t||null===t?t:e.json.stringify(t)},ajaxSend:function(t,n){var a,c=r.stringifySend(t,n),u=s(t,"/send"),l=function(t,r){e(r).triggerHandler(i.onError,[o._.transportError(o.resources.sendFailed,r.transport,t,a),n])};return a=r.ajax(t,{url:u,type:"jsonp"===t.ajaxDataType?"GET":"POST",contentType:o._.defaultContentType,headers:t.accessToken?{Authorization:"Bearer "+t.accessToken}:{},data:{data:c},success:function(e){var n;if(e){try{n=t._parseResponse(e)}catch(e){return l(e,t),void t.stop()}r.triggerReceived(t,n)}},error:function(e,n){"abort"!==n&&"parsererror"!==n&&l(e,t)}})},ajaxAbort:function(e,n){if("undefined"!==typeof e.transport){n="undefined"===typeof n||n;var o=s(e,"/abort"),i=e.accessToken?{Authorization:"Bearer "+e.accessToken}:{};t.fetch?t.fetch(o,{method:"POST",keepalive:!0,headers:i}):r.ajax(e,{url:o,async:n,timeout:1e3,type:"POST",headers:i,dataType:"text"}),e.log("Fired ajax abort async = "+n+".")}},ajaxStart:function(t,n){var a=function(e){var n=t._deferral;n&&n.reject(e)},c=function(n){t.log("The start request failed. Stopping the connection."),e(t).triggerHandler(i.onError,[n]),a(n),t.stop()};t._.startRequest=r.ajax(t,{url:s(t,"/start"),headers:t.accessToken?{Authorization:"Bearer "+t.accessToken}:{},success:function(e,r,i){var a;try{a=t._parseResponse(e)}catch(t){return void c(o._.error(o._.format(o.resources.errorParsingStartResponse,e),t,i))}"started"===a.Response?n():c(o._.error(o._.format(o.resources.invalidStartResponse,e),null,i))},error:function(e,n,r){"__Start Aborted__"!==n?c(o._.error(o.resources.errorDuringStartRequest,r,e)):(t.log("The start request aborted because connection.stop() was called."),a(o._.error(o.resources.stoppedDuringStartRequest,null,e)))}})},tryAbortStartRequest:function(e){e._.startRequest&&(e._.startRequest.abort("__Start Aborted__"),delete e._.startRequest)},tryInitialize:function(e,t,n){t.Initialized&&n?n():t.Initialized&&e.log("WARNING! The client received an init message after reconnecting.")},triggerReceived:function(t,n){t._.connectingMessageBuffer.tryBuffer(n)||e(t).triggerHandler(i.onReceived,[n])},processMessages:function(t,n,i){var a;if(n&&"undefined"!==typeof n.I)r.triggerReceived(t,n);else if(r.markLastMessage(t),n){if((a=r.maximizePersistentResponse(n)).Error)return t.log("Received an error message from the server: "+n.E),e(t).triggerHandler(o.events.onError,[o._.error(n.E,"ServerError")]),void t.stop(!1,!1);r.updateGroups(t,a.GroupsToken),a.MessageId&&(t.messageId=a.MessageId),a.Messages&&(e.each(a.Messages,function(e,n){r.triggerReceived(t,n)}),r.tryInitialize(t,a,i))}},monitorKeepAlive:function(t){var n=t._.keepAliveData;n.monitoring?t.log("Tried to monitor keep alive but it's already being monitored."):(n.monitoring=!0,r.markLastMessage(t),t._.keepAliveData.reconnectKeepAliveUpdate=function(){r.markLastMessage(t)},e(t).bind(i.onReconnect,t._.keepAliveData.reconnectKeepAliveUpdate),t.log("Now monitoring keep alive with a warning timeout of "+n.timeoutWarning+", keep alive timeout of "+n.timeout+" and disconnecting timeout of "+t.disconnectTimeout))},stopMonitoringKeepAlive:function(t){var n=t._.keepAliveData;n.monitoring&&(n.monitoring=!1,e(t).unbind(i.onReconnect,t._.keepAliveData.reconnectKeepAliveUpdate),t._.keepAliveData={},t.log("Stopping the monitoring of the keep alive."))},startHeartbeat:function(e){e._.lastActiveAt=(new Date).getTime(),c(e)},markLastMessage:function(e){e._.lastMessageAt=(new Date).getTime(),e._.lastActiveAt=e._.lastMessageAt},markActive:function(e){return!!r.verifyLastActive(e)&&(e._.lastActiveAt=(new Date).getTime(),!0)},isConnectedOrReconnecting:function(e){return e.state===o.connectionState.connected||e.state===o.connectionState.reconnecting},ensureReconnectingState:function(t){return!0===a(t,o.connectionState.connected,o.connectionState.reconnecting)&&e(t).triggerHandler(i.onReconnecting),t.state===o.connectionState.reconnecting},clearReconnectTimeout:function(e){e&&e._.reconnectTimeout&&(t.clearTimeout(e._.reconnectTimeout),delete e._.reconnectTimeout)},verifyLastActive:function(t){if(!t._.keepAliveData.activated||(new Date).getTime()-t._.lastActiveAt0&&o--}});i.transports.foreverFrame={name:"foreverFrame",supportsKeepAlive:function(){return!0},iframeClearThreshold:50,start:function(e,n,r){if(e.accessToken)r&&(e.log("Forever Frame does not support connections that require a Bearer token to connect, such as the Azure SignalR Service."),r());else{var o,i=this,a=s.foreverFrame.count+=1,c=u(),f=function(){e.log("Forever frame iframe finished loading and is no longer receiving messages."),r&&r()||i.reconnect(e)};t.EventSource?r&&(e.log("Forever Frame is not supported by SignalR on browsers with SSE support."),r()):(c.setAttribute("data-signalr-connection-id",e.id),l.prevent(),o=s.getUrl(e,this.name),o+="&frameId="+a,t.document.documentElement.appendChild(c),e.log("Binding to iframe's load event."),c.addEventListener?c.addEventListener("load",f,!1):c.attachEvent&&c.attachEvent("onload",f),c.src=o,s.foreverFrame.connections[a]=e,e.frame=c,e.frameId=a,n&&(e.onSuccess=function(){e.log("Iframe transport started."),n()}))}},reconnect:function(e){var n=this;s.isConnectedOrReconnecting(e)&&s.verifyLastActive(e)&&t.setTimeout(function(){if(s.verifyLastActive(e)&&e.frame&&s.ensureReconnectingState(e)){var t=e.frame,r=s.getUrl(e,n.name,!0)+"&frameId="+e.frameId;e.log("Updating iframe src to '"+r+"'."),t.src=r}},e.reconnectDelay)},lostConnection:function(e){this.reconnect(e)},send:function(e,t){s.ajaxSend(e,t)},receive:function(t,n){var r,o,a;if(t.json!==t._originalJson&&(n=t._originalJson.stringify(n)),a=t._parseResponse(n),s.processMessages(t,a,t.onSuccess),t.state===e.signalR.connectionState.connected&&(t.frameMessageCount=(t.frameMessageCount||0)+1,t.frameMessageCount>i.transports.foreverFrame.iframeClearThreshold&&(t.frameMessageCount=0,(r=t.frame.contentWindow||t.frame.contentDocument)&&r.document&&r.document.body)))for(o=r.document.body;o.firstChild;)o.removeChild(o.firstChild)},stop:function(e){var n=null;if(l.cancel(),e.frame){if(e.frame.stop)e.frame.stop();else try{(n=e.frame.contentWindow||e.frame.contentDocument).document&&n.document.execCommand&&n.document.execCommand("Stop")}catch(t){e.log("Error occurred when stopping foreverFrame transport. Message = "+t.message+".")}e.frame.parentNode===t.document.documentElement&&t.document.documentElement.removeChild(e.frame),delete s.foreverFrame.connections[e.frameId],e.frame=null,e.frameId=null,delete e.frame,delete e.frameId,delete e.onSuccess,delete e.frameMessageCount,e.log("Stopping forever frame.")}},abort:function(e,t){s.ajaxAbort(e,t)},getConnection:function(e){return s.foreverFrame.connections[e]},started:function(t){!0===c(t,i.connectionState.reconnecting,i.connectionState.connected)&&e(t).triggerHandler(a.onReconnect)}}}(window.jQuery,window),function(e,t,n){var r=e.signalR,o=e.signalR.events,i=e.signalR.changeState,a=e.signalR.isDisconnecting,c=r.transports._logic;r.transports.longPolling={name:"longPolling",supportsKeepAlive:function(){return!1},reconnectDelay:3e3,start:function(n,s,u){var l=this,f=function(){f=e.noop,n.log("LongPolling connected."),s?s():n.log("WARNING! The client received an init message after reconnecting.")},p=function(e){return!!u(e)&&(n.log("LongPolling failed to connect."),!0)},d=n._,h=0,b=function(n){t.clearTimeout(d.reconnectTimeoutId),d.reconnectTimeoutId=null,!0===i(n,r.connectionState.reconnecting,r.connectionState.connected)&&(n.log("Raising the reconnect event"),e(n).triggerHandler(o.onReconnect))};n.pollXhr&&(n.log("Polling xhr requests already exists, aborting."),n.stop()),n.messageId=null,d.reconnectTimeoutId=null,d.pollTimeoutId=t.setTimeout(function(){!function i(s,u){var v=!(null===s.messageId),y=!u,g=c.getUrl(s,l.name,v,y,!0),m={};s.messageId&&(m.messageId=s.messageId),s.groupsToken&&(m.groupsToken=s.groupsToken),!0!==a(s)&&(n.log("Opening long polling request to '"+g+"'."),s.pollXhr=c.ajax(n,{xhrFields:{onprogress:function(){c.markLastMessage(n)}},url:g,type:"POST",contentType:r._.defaultContentType,data:m,timeout:n._.pollTimeout,headers:n.accessToken?{Authorization:"Bearer "+n.accessToken}:{},success:function(r){var o,u,l,v=0;n.log("Long poll complete."),h=0;try{o=n._parseResponse(r)}catch(e){return void c.handleParseFailure(s,r,e,p,s.pollXhr)}null!==d.reconnectTimeoutId&&b(s),o&&(u=c.maximizePersistentResponse(o)),c.processMessages(s,o,f),u&&"number"===e.type(u.LongPollDelay)&&(v=u.LongPollDelay),!0!==a(s)&&((l=u&&u.ShouldReconnect)&&!c.ensureReconnectingState(s)||(v>0?d.pollTimeoutId=t.setTimeout(function(){i(s,l)},v):i(s,l)))},error:function(a,u){var f=r._.transportError(r.resources.longPollFailed,n.transport,a,s.pollXhr);if(t.clearTimeout(d.reconnectTimeoutId),d.reconnectTimeoutId=null,"abort"!==u){if(!p(f)){if(h++,n.state!==r.connectionState.reconnecting&&(n.log("An error occurred using longPolling. Status = "+u+". Response = "+a.responseText+"."),e(s).triggerHandler(o.onError,[f])),(n.state===r.connectionState.connected||n.state===r.connectionState.reconnecting)&&!c.verifyLastActive(n))return;if(!c.ensureReconnectingState(s))return;d.pollTimeoutId=t.setTimeout(function(){i(s,!0)},l.reconnectDelay)}}else n.log("Aborted xhr request.")}}),v&&!0===u&&(d.reconnectTimeoutId=t.setTimeout(function(){b(s)},Math.min(1e3*(Math.pow(2,h)-1),36e5))))}(n)},250)},lostConnection:function(e){e.pollXhr&&e.pollXhr.abort("lostConnection")},send:function(e,t){c.ajaxSend(e,t)},stop:function(e){t.clearTimeout(e._.pollTimeoutId),t.clearTimeout(e._.reconnectTimeoutId),delete e._.pollTimeoutId,delete e._.reconnectTimeoutId,e.pollXhr&&(e.pollXhr.abort(),e.pollXhr=null,delete e.pollXhr)},abort:function(e,t){c.ajaxAbort(e,t)}}}(window.jQuery,window),function(e,t,n){var r=0,o=".hubProxy",i=e.signalR;function a(e){return e+o}function c(t){return e.isFunction(t)?null:"undefined"===e.type(t)?null:t}function s(e){for(var t in e)if(e.hasOwnProperty(t))return!0;return!1}function u(e,t){var n,r=e._.invocationCallbacks;for(var o in s(r)&&e.log("Clearing hub invocation callbacks with error: "+t+"."),e._.invocationCallbackId=0,delete e._.invocationCallbacks,e._.invocationCallbacks={},r)(n=r[o]).method.call(n.scope,{E:t})}function l(t){return e.isFunction(t)&&t.toString().slice(0,256).indexOf("// Call the client hub method")>=0}function f(e,t){return new f.fn.init(e,t)}function p(t,n){var r={qs:null,logging:!1,useDefaultPath:!0};return e.extend(r,n),t&&!r.useDefaultPath||(t=(t||"")+"/signalr"),new p.fn.init(t,r)}f.fn=f.prototype={init:function(e,t){this.state={},this.connection=e,this.hubName=t,this._={callbackMap:{}}},constructor:f,hasSubscriptions:function(){return s(this._.callbackMap)},on:function(t,n,o){var i=this,c=i._.callbackMap,s=!o&&l(n);(o=o||n)._signalRGuid||(o._signalRGuid=r++);var u,f=c[t=t.toLowerCase()];f||(f=[],c[t]=f);for(var p=0;p