function _typeof(e){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _defineProperties(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,_toPropertyKey(n.key),n)}}function _createClass(e,t,r){return t&&_defineProperties(e.prototype,t),r&&_defineProperties(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function _toPropertyKey(e){e=_toPrimitive(e,"string");return"symbol"==_typeof(e)?e:e+""}function _toPrimitive(e,t){if("object"!=_typeof(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0===r)return("string"===t?String:Number)(e);r=r.call(e,t||"default");if("object"!=_typeof(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}var Scenario=(()=>{return _createClass(function e(t){_classCallCheck(this,e),this.instanceMethodType=t;this.url=protocol+"://"+urlBase+"/"+subdomain+"/",this.empreintesFichiers=[]},[{key:"getScenario",value:function(e,t){var r=this;r.nomCompte=e,r.numeroSerie=t,r.makeRequestScenario(r.nomCompte,r.numeroSerie)}},{key:"getScenarioFromWebsocket",value:function(e,t,r){setTimeout(function(){r.makeRequestScenario(e,t,r.empreintesFichiers)},5e3)}},{key:"intervalCheckSenario",value:(t=function(){var e=this;setInterval(function(){e.makeRequestScenario(e.nomCompte,e.numeroSerie,e.empreintesFichiers)},intervalCheckSenario)},e.toString=function(){return t.toString()},e)},{key:"makeRequestScenario",value:function(t,r){var e=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,n=this,i=n.url+"?page=checkIfScenarioChanged",o={numeroSerie:r,nomCompte:t};if(e instanceof Array)for(var a=0;a<e.length;a++){var c=e[a];o["empreinteFichier["+a+"]"]=c}new Ajax(o,i,function(e){n.empreintesFichiers=e.newEmpreinteFichier,e.hasScenarioChanged&&("browser"!==type?reloadScenarioChangedPopUp("Le scénario a changé",1e4,function(){setTimeout(function(){initizialized.getShortLink(r,t,initizialized,!0)},5e3)}):location.reload())})}}]);function e(){return t.apply(this,arguments)}var t})();