48d1f872cff7fa94535e2f206c0d2f89460f2849
[motion2.git] / server / services / ami / model / voiceQueue.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and   *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0xc84c=['timeout','outboundAnswerCallsDay','outboundAnswerAgiCallsDay','outboundNoAnswerCallsDay','outboundBusyCallsDay','outboundCongestionCallsDay','outboundNoSuchCallsDay','outboundUnknownCallsDay','outboundOriginateFailureCallsDay','outboundDropCallsDayCallersExit','outboundDropCallsDayACS','outboundReCallsDay','outboundAbandonedDay','startProgressive','startPredictive','handlePredictive','predictiveIntervalMultiplicativeFactor','predictiveIntervalTotalCalls','predictiveIntervalAnsweredCalls','predictiveIntervalDroppedCallsCallersExit','predictiveIntervalDroppedCallsTimeout','predictiveIntervalAvgHoldtime','predictiveIntervalAvgTalktime','predictiveIntervalMaxThreshold','dialPredictiveIntervalMaxThreshold','predictiveIntervalMinThreshold','predictiveIntervalErlangCalls','predictiveIntervalErlangCallsDroppedCalls','predictiveIntervalHitRate','erlangCalls','erlangCallToSecond','erlangBusyFactor','dialRecallMeTimeout','dialRecallInQueue','dialPreviewAutoRecallMe','dialPreviewRecallmeReminder','dialQueueProject2','dialAgiAfterHangupClient','dialAgiAfterHangupAgent','mandatoryDisposition','mandatoryDispositionPause','queueSummaryCountersUpdated','exports','wav','wav49','gsm','fewestcalls','leastrecent','random','roundrobin','rrmemory','rrordered','name','monitor_format','type','inbound','waiting','sumDuration','sumHoldTime','sumBillable','unmanaged','abandoned','available','busy','inUse','loggedIn','onHold','paused','ringing','talking','acwTimeout','autopause','sendMessageOneNotActive','message','statusMessage','originated','temp','dialTimezone','dialGlobalInterval','dialActive','dialMethod','progressive','dialLimitChannel','dialPowerLevel','dialPredictiveOptimization','dialPredictiveOptimizationPercentage','dialPredictiveInterval','dialOriginateCallerIdName','dialOriginateCallerIdNumber','dialOriginateTimeout','dialQueueOptions','dialQueueTimeout','dialQueueProject','dialCongestionMaxRetry','dialCongestionRetryFrequency','dialBusyMaxRetry','dialBusyRetryFrequency','dialNoAnswerMaxRetry','dialNoAnswerRetryFrequency','dialNoSuchNumberMaxRetry','dialNoSuchNumberRetryFrequency','dialDropMaxRetry','dialDropRetryFrequency','dialAbandonedMaxRetry','dialAbandonedRetryFrequency','dialMachineMaxRetry','dialMachineRetryFrequency','dialAgentRejectMaxRetry','dialAgentRejectRetryFrequency','callAdditionalPhoneAfterMin','dialGlobalMaxRetry','TrunkBackup','dialPrefix','Interval','dialOrderByScheduledAt','DESC','dialRandomLastDigitCallerIdNumber','dialCutDigit','strategy','dialAMDActive','dialAMDInitialSilence','dialAMDGreeting','dialAMDAfterGreetingSilence','dialAMDTotalAnalysisTime','dialAMDMinWordLength','dialAMDBetweenWordsSilence','dialAMDMaximumNumberOfWords','dialAMDMaximumWordLength','outboundRejectCallsDay','pTalking'];(function(_0x5ed54b,_0x3a2827){var _0x4b58c7=function(_0x19d3b6){while(--_0x19d3b6){_0x5ed54b['push'](_0x5ed54b['shift']());}};_0x4b58c7(++_0x3a2827);}(_0xc84c,0x12f));var _0xcc84=function(_0x2d8935,_0x2c9d2e){_0x2d8935=_0x2d8935-0x0;var _0x2c5156=_0xc84c[_0x2d8935];return _0x2c5156;};'use strict';var monitorFormat={'wav':_0xcc84('0x0'),'wav49':_0xcc84('0x1'),'gsm':_0xcc84('0x2')};var strategy={'fewestcalls':_0xcc84('0x3'),'leastrecent':_0xcc84('0x4'),'linear':'linear','random':_0xcc84('0x5'),'ringall':'ringall','rr':_0xcc84('0x6'),'rrmemory':_0xcc84('0x7'),'rrordered':_0xcc84('0x8'),'wrandom':'wrandom'};function VoiceQueue(_0x2aeeb4){this['id']=_0x2aeeb4['id']||0x0;this['name']=_0x2aeeb4[_0xcc84('0x9')]||'';this['monitor_format']=_0x2aeeb4[_0xcc84('0xa')]||'';this[_0xcc84('0xb')]=_0x2aeeb4[_0xcc84('0xb')]||_0xcc84('0xc');this[_0xcc84('0xd')]=0x0;this['total']=0x0;this['answered']=0x0;this[_0xcc84('0xe')]=0x0;this[_0xcc84('0xf')]=0x0;this[_0xcc84('0x10')]=0x0;this[_0xcc84('0x11')]=0x0;this[_0xcc84('0x12')]=0x0;this[_0xcc84('0x13')]=0x0;this[_0xcc84('0x14')]=0x0;this[_0xcc84('0x15')]=0x0;this['invalid']=0x0;this[_0xcc84('0x16')]=0x0;this['notInUse']=0x0;this[_0xcc84('0x17')]=0x0;this[_0xcc84('0x18')]=0x0;this[_0xcc84('0x19')]=0x0;this['ringInUse']=0x0;this[_0xcc84('0x1a')]=0x0;this['unavailable']=0x0;this['unknown']=0x0;this['acw']=_0x2aeeb4['acw']||![];this[_0xcc84('0x1b')]=_0x2aeeb4[_0xcc84('0x1b')]||0xa;this[_0xcc84('0x1c')]=_0x2aeeb4[_0xcc84('0x1c')]||'no';this[_0xcc84('0x1d')]=!![];this[_0xcc84('0x1e')]='';this[_0xcc84('0x1f')]='';this[_0xcc84('0x20')]=0x0;this[_0xcc84('0x21')]=0x0;this[_0xcc84('0x22')]=_0x2aeeb4[_0xcc84('0x22')]||null;this[_0xcc84('0x23')]=_0x2aeeb4['dialGlobalInterval']?_0x2aeeb4['dialGlobalInterval']:null;this[_0xcc84('0x24')]=_0x2aeeb4['dialActive'];this[_0xcc84('0x25')]=_0x2aeeb4['dialMethod']||_0xcc84('0x26');this[_0xcc84('0x27')]=_0x2aeeb4[_0xcc84('0x27')]||0x0;this['dialLimitQueue']=_0x2aeeb4['dialLimitQueue']||0x0;this[_0xcc84('0x28')]=_0x2aeeb4[_0xcc84('0x28')]||0x1;this[_0xcc84('0x29')]=_0x2aeeb4[_0xcc84('0x29')]||'dropRate';this[_0xcc84('0x2a')]=_0x2aeeb4[_0xcc84('0x2a')]||0.03;this[_0xcc84('0x2b')]=_0x2aeeb4[_0xcc84('0x2b')]||0x258;this[_0xcc84('0x2c')]=_0x2aeeb4[_0xcc84('0x2c')]||'anonymous';this['dialOriginateCallerIdNumber']=_0x2aeeb4[_0xcc84('0x2d')]||'anonymous';this[_0xcc84('0x2e')]=_0x2aeeb4[_0xcc84('0x2e')]||0x1e;this[_0xcc84('0x2f')]=_0x2aeeb4[_0xcc84('0x2f')]||'tTxX';this[_0xcc84('0x30')]=_0x2aeeb4[_0xcc84('0x30')]||0x3;this[_0xcc84('0x31')]=_0x2aeeb4[_0xcc84('0x31')]||undefined;this[_0xcc84('0x32')]=_0x2aeeb4[_0xcc84('0x32')]||0x3;this[_0xcc84('0x33')]=_0x2aeeb4['dialCongestionRetryFrequency']||0x96;this['dialBusyMaxRetry']=_0x2aeeb4[_0xcc84('0x34')]||0x3;this[_0xcc84('0x35')]=_0x2aeeb4[_0xcc84('0x35')]||0x96;this['dialNoAnswerMaxRetry']=_0x2aeeb4[_0xcc84('0x36')]||0x3;this[_0xcc84('0x37')]=_0x2aeeb4[_0xcc84('0x37')]||0x96;this[_0xcc84('0x38')]=_0x2aeeb4[_0xcc84('0x38')]||0x3;this[_0xcc84('0x39')]=_0x2aeeb4[_0xcc84('0x39')]||0x96;this[_0xcc84('0x3a')]=_0x2aeeb4[_0xcc84('0x3a')]||0x3;this[_0xcc84('0x3b')]=_0x2aeeb4[_0xcc84('0x3b')]||0x96;this[_0xcc84('0x3c')]=_0x2aeeb4[_0xcc84('0x3c')]||0x3;this[_0xcc84('0x3d')]=_0x2aeeb4[_0xcc84('0x3d')]||0x96;this[_0xcc84('0x3e')]=_0x2aeeb4[_0xcc84('0x3e')]||0x3;this[_0xcc84('0x3f')]=_0x2aeeb4[_0xcc84('0x3f')]||0x96;this[_0xcc84('0x40')]=_0x2aeeb4[_0xcc84('0x40')]||0x3;this[_0xcc84('0x41')]=_0x2aeeb4[_0xcc84('0x41')]||0x96;this[_0xcc84('0x42')]=_0x2aeeb4[_0xcc84('0x42')]||0x3;this[_0xcc84('0x43')]=_0x2aeeb4[_0xcc84('0x43')]||0x4;this['Trunk']=_0x2aeeb4['Trunk']?_0x2aeeb4['Trunk']:undefined;this[_0xcc84('0x44')]=_0x2aeeb4[_0xcc84('0x44')]?_0x2aeeb4[_0xcc84('0x44')]:undefined;this[_0xcc84('0x45')]=_0x2aeeb4['dialPrefix']||undefined;this[_0xcc84('0x46')]=_0x2aeeb4[_0xcc84('0x46')]?_0x2aeeb4[_0xcc84('0x46')]:undefined;this['dialOrderByScheduledAt']=_0x2aeeb4[_0xcc84('0x47')]||_0xcc84('0x48');this['dialRandomLastDigitCallerIdNumber']=_0x2aeeb4[_0xcc84('0x49')]||undefined;this[_0xcc84('0x4a')]=_0x2aeeb4[_0xcc84('0x4a')]||undefined;this[_0xcc84('0x4b')]=strategy[_0x2aeeb4['strategy']];this['queueStatusComplete']=!![];this[_0xcc84('0x4c')]=_0x2aeeb4['dialAMDActive']||![];this[_0xcc84('0x4d')]=_0x2aeeb4[_0xcc84('0x4d')];this[_0xcc84('0x4e')]=_0x2aeeb4['dialAMDGreeting'];this['dialAMDAfterGreetingSilence']=_0x2aeeb4[_0xcc84('0x4f')];this[_0xcc84('0x50')]=_0x2aeeb4[_0xcc84('0x50')];this[_0xcc84('0x51')]=_0x2aeeb4[_0xcc84('0x51')];this[_0xcc84('0x52')]=_0x2aeeb4['dialAMDBetweenWordsSilence'];this[_0xcc84('0x53')]=_0x2aeeb4[_0xcc84('0x53')];this['dialAMDSilenceThreshold']=_0x2aeeb4['dialAMDSilenceThreshold'];this[_0xcc84('0x54')]=_0x2aeeb4[_0xcc84('0x54')];this[_0xcc84('0x55')]=0x0;this[_0xcc84('0x56')]=0x0;this[_0xcc84('0x57')]=_0x2aeeb4['timeout'];this[_0xcc84('0x58')]=0x0;this[_0xcc84('0x59')]=0x0;this[_0xcc84('0x5a')]=0x0;this[_0xcc84('0x5b')]=0x0;this[_0xcc84('0x5c')]=0x0;this[_0xcc84('0x5d')]=0x0;this[_0xcc84('0x5e')]=0x0;this['outboundBlacklistCallsDay']=0x0;this[_0xcc84('0x5f')]=0x0;this[_0xcc84('0x60')]=0x0;this['outboundDropCallsDayTimeout']=0x0;this[_0xcc84('0x61')]=0x0;this[_0xcc84('0x62')]=0x0;this[_0xcc84('0x63')]=0x0;this[_0xcc84('0x64')]=undefined;this[_0xcc84('0x65')]=undefined;this[_0xcc84('0x66')]=undefined;this[_0xcc84('0x67')]=1.05;this[_0xcc84('0x68')]=0x0;this[_0xcc84('0x69')]=0x0;this[_0xcc84('0x6a')]=0x0;this[_0xcc84('0x6b')]=0x0;this[_0xcc84('0x6c')]=0x0;this[_0xcc84('0x6d')]=0x0;this['predictiveIntervalPauses']=0x0;this['predictiveIntervalAvailable']=0x0;this[_0xcc84('0x6e')]=_0x2aeeb4[_0xcc84('0x6f')]||0x14;this[_0xcc84('0x70')]=_0x2aeeb4[_0xcc84('0x6f')]||0xa;this[_0xcc84('0x71')]=0x0;this[_0xcc84('0x72')]=0x0;this[_0xcc84('0x73')]=0x1;this[_0xcc84('0x74')]=0x0;this[_0xcc84('0x75')]=0x0;this['erlangAbandonmentRate']=0x0;this[_0xcc84('0x76')]=0x0;this[_0xcc84('0x77')]=_0x2aeeb4[_0xcc84('0x77')]||0x1e;this[_0xcc84('0x78')]=_0x2aeeb4[_0xcc84('0x78')]||![];this[_0xcc84('0x79')]=!!_0x2aeeb4['dialPreviewAutoRecallMe']||![];this[_0xcc84('0x7a')]=!!_0x2aeeb4[_0xcc84('0x7a')]||![];this['dialQueueProject2']=_0x2aeeb4[_0xcc84('0x7b')]||undefined;this[_0xcc84('0x7c')]=_0x2aeeb4['dialAgiAfterHangupClient']||![];this[_0xcc84('0x7d')]=_0x2aeeb4[_0xcc84('0x7d')]||![];this[_0xcc84('0xa')]=monitorFormat[_0x2aeeb4[_0xcc84('0xa')]]?monitorFormat[_0x2aeeb4['monitor_format']]:undefined;this[_0xcc84('0x7e')]=_0x2aeeb4[_0xcc84('0x7e')]||![];this[_0xcc84('0x7f')]=_0x2aeeb4[_0xcc84('0x7f')]?_0x2aeeb4[_0xcc84('0x7f')]:undefined;this[_0xcc84('0x80')]=![];}module[_0xcc84('0x81')]=VoiceQueue;