Built motion from commit 19a84241.|2.5.34
[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 _0xd4ad=['erlangCalls','erlangAbandonmentRate','erlangBusyFactor','dialRecallMeTimeout','dialRecallInQueue','dialQueueProject2','dialAgiAfterHangupClient','dialAgiAfterHangupAgent','mandatoryDisposition','mandatoryDispositionPause','exports','unknown','not_inuse','inuse','busy','unavailable','ringing','wav','wav49','rrmemory','name','monitor_format','type','inbound','waiting','talking','total','sumHoldTime','unmanaged','abandoned','available','acw','acwTimeout','autopause','sendMessageOneNotActive','temp','dialGlobalInterval','dialActive','dialMethod','progressive','dialLimitChannel','dialLimitQueue','dialPowerLevel','dialPredictiveOptimization','dropRate','dialPredictiveOptimizationPercentage','dialPredictiveInterval','dialOriginateCallerIdName','dialOriginateTimeout','dialQueueOptions','tTxX','dialQueueTimeout','dialQueueProject','dialCongestionMaxRetry','dialBusyMaxRetry','dialNoAnswerMaxRetry','dialNoAnswerRetryFrequency','dialNoSuchNumberMaxRetry','dialNoSuchNumberRetryFrequency','dialDropMaxRetry','dialDropRetryFrequency','dialAbandonedMaxRetry','dialAbandonedRetryFrequency','dialMachineMaxRetry','dialMachineRetryFrequency','dialAgentRejectMaxRetry','dialAgentRejectRetryFrequency','dialGlobalMaxRetry','Trunk','TrunkBackup','dialPrefix','Interval','dialOrderByScheduledAt','DESC','dialRandomLastDigitCallerIdNumber','dialCutDigit','strategy','dialAMDActive','dialAMDInitialSilence','dialAMDGreeting','dialAMDAfterGreetingSilence','dialAMDTotalAnalysisTime','dialAMDMinWordLength','dialAMDMaximumNumberOfWords','dialAMDSilenceThreshold','dialAMDMaximumWordLength','outboundRejectCallsDay','timeout','outboundAnswerCallsDay','outboundNoAnswerCallsDay','outboundBusyCallsDay','outboundCongestionCallsDay','outboundNoSuchCallsDay','outboundOriginateFailureCallsDay','outboundDropCallsDayCallersExit','outboundDropCallsDayTimeout','outboundReCallsDay','outboundAbandonedDay','startProgressive','startPredictive','handlePredictive','predictiveIntervalTotalCalls','predictiveIntervalAnsweredCalls','predictiveIntervalDroppedCallsCallersExit','predictiveIntervalDroppedCallsTimeout','predictiveIntervalAvgHoldtime','predictiveIntervalPauses','predictiveIntervalAvailable','dialPredictiveIntervalMaxThreshold','predictiveIntervalMinThreshold','predictiveIntervalErlangCalls'];(function(_0x2b722b,_0x1dc6b8){var _0x46849b=function(_0x3f36ec){while(--_0x3f36ec){_0x2b722b['push'](_0x2b722b['shift']());}};_0x46849b(++_0x1dc6b8);}(_0xd4ad,0x158));var _0xdd4a=function(_0x1bbfda,_0x3c1cbb){_0x1bbfda=_0x1bbfda-0x0;var _0x4dbbb1=_0xd4ad[_0x1bbfda];return _0x4dbbb1;};'use strict';var statusDesc=[_0xdd4a('0x0'),_0xdd4a('0x1'),_0xdd4a('0x2'),_0xdd4a('0x3'),'invalid',_0xdd4a('0x4'),_0xdd4a('0x5'),'ringinuse','onhold'];var monitorFormat={'wav':_0xdd4a('0x6'),'wav49':_0xdd4a('0x7'),'gsm':'gsm'};var strategy={'rrmemory':_0xdd4a('0x8'),'roundrobin':'roundrobin'};function VoiceQueue(_0xd243eb){this['id']=_0xd243eb['id']||0x0;this[_0xdd4a('0x9')]=_0xd243eb['name']||'';this[_0xdd4a('0xa')]=_0xd243eb['monitor_format']||'';this[_0xdd4a('0xb')]=_0xd243eb[_0xdd4a('0xb')]||_0xdd4a('0xc');this[_0xdd4a('0xd')]=0x0;this[_0xdd4a('0xe')]=0x0;this[_0xdd4a('0xf')]=0x0;this['answered']=0x0;this['sumDuration']=0x0;this[_0xdd4a('0x10')]=0x0;this['sumBillable']=0x0;this[_0xdd4a('0x11')]=0x0;this[_0xdd4a('0x12')]=0x0;this['loggedIn']=0x0;this[_0xdd4a('0x13')]=0x0;this[_0xdd4a('0x14')]=_0xd243eb['acw']||![];this[_0xdd4a('0x15')]=_0xd243eb['acwTimeout']||0xa;this[_0xdd4a('0x16')]=_0xd243eb['autopause']||'no';this[_0xdd4a('0x17')]=!![];this['message']='';this['originated']=0x0;this[_0xdd4a('0x18')]=0x0;this['dialTimezone']=_0xd243eb['dialTimezone']||null;this['dialGlobalInterval']=_0xd243eb[_0xdd4a('0x19')]?_0xd243eb[_0xdd4a('0x19')]:null;this[_0xdd4a('0x1a')]=_0xd243eb[_0xdd4a('0x1a')];this[_0xdd4a('0x1b')]=_0xd243eb[_0xdd4a('0x1b')]||_0xdd4a('0x1c');this[_0xdd4a('0x1d')]=_0xd243eb['dialLimitChannel']||0x0;this[_0xdd4a('0x1e')]=_0xd243eb[_0xdd4a('0x1e')]||0x0;this['dialPowerLevel']=_0xd243eb[_0xdd4a('0x1f')]||0x1;this[_0xdd4a('0x20')]=_0xd243eb['dialPredictiveOptimization']||_0xdd4a('0x21');this[_0xdd4a('0x22')]=_0xd243eb[_0xdd4a('0x22')]||0.03;this[_0xdd4a('0x23')]=_0xd243eb[_0xdd4a('0x23')]||0x258;this[_0xdd4a('0x24')]=_0xd243eb[_0xdd4a('0x24')]||'anonymous';this['dialOriginateCallerIdNumber']=_0xd243eb['dialOriginateCallerIdNumber']||'anonymous';this[_0xdd4a('0x25')]=_0xd243eb[_0xdd4a('0x25')]||0x1e;this[_0xdd4a('0x26')]=_0xd243eb[_0xdd4a('0x26')]||_0xdd4a('0x27');this['dialQueueTimeout']=_0xd243eb[_0xdd4a('0x28')]||0x3;this[_0xdd4a('0x29')]=_0xd243eb[_0xdd4a('0x29')]||undefined;this[_0xdd4a('0x2a')]=_0xd243eb['dialCongestionMaxRetry']||0x3;this['dialCongestionRetryFrequency']=_0xd243eb['dialCongestionRetryFrequency']||0x96;this['dialBusyMaxRetry']=_0xd243eb[_0xdd4a('0x2b')]||0x3;this['dialBusyRetryFrequency']=_0xd243eb['dialBusyRetryFrequency']||0x96;this[_0xdd4a('0x2c')]=_0xd243eb[_0xdd4a('0x2c')]||0x3;this[_0xdd4a('0x2d')]=_0xd243eb[_0xdd4a('0x2d')]||0x96;this[_0xdd4a('0x2e')]=_0xd243eb[_0xdd4a('0x2e')]||0x3;this['dialNoSuchNumberRetryFrequency']=_0xd243eb[_0xdd4a('0x2f')]||0x96;this[_0xdd4a('0x30')]=_0xd243eb['dialDropMaxRetry']||0x3;this[_0xdd4a('0x31')]=_0xd243eb['dialDropRetryFrequency']||0x96;this[_0xdd4a('0x32')]=_0xd243eb[_0xdd4a('0x32')]||0x3;this[_0xdd4a('0x33')]=_0xd243eb[_0xdd4a('0x33')]||0x96;this['dialMachineMaxRetry']=_0xd243eb[_0xdd4a('0x34')]||0x3;this[_0xdd4a('0x35')]=_0xd243eb[_0xdd4a('0x35')]||0x96;this['dialAgentRejectMaxRetry']=_0xd243eb[_0xdd4a('0x36')]||0x3;this['dialAgentRejectRetryFrequency']=_0xd243eb[_0xdd4a('0x37')]||0x96;this[_0xdd4a('0x38')]=_0xd243eb[_0xdd4a('0x38')]||0x4;this['Trunk']=_0xd243eb[_0xdd4a('0x39')]?_0xd243eb[_0xdd4a('0x39')]:undefined;this['TrunkBackup']=_0xd243eb[_0xdd4a('0x3a')]?_0xd243eb[_0xdd4a('0x3a')]:undefined;this['dialPrefix']=_0xd243eb[_0xdd4a('0x3b')]||undefined;this['Interval']=_0xd243eb[_0xdd4a('0x3c')]?_0xd243eb[_0xdd4a('0x3c')]:undefined;this[_0xdd4a('0x3d')]=_0xd243eb[_0xdd4a('0x3d')]||_0xdd4a('0x3e');this['dialRandomLastDigitCallerIdNumber']=_0xd243eb[_0xdd4a('0x3f')]||undefined;this[_0xdd4a('0x40')]=_0xd243eb[_0xdd4a('0x40')]||undefined;this[_0xdd4a('0x41')]=strategy[_0xd243eb[_0xdd4a('0x41')]]||'rrmemory';this['queueStatusComplete']=!![];this[_0xdd4a('0x42')]=_0xd243eb[_0xdd4a('0x42')]||![];this['dialAMDInitialSilence']=_0xd243eb[_0xdd4a('0x43')];this['dialAMDGreeting']=_0xd243eb[_0xdd4a('0x44')];this[_0xdd4a('0x45')]=_0xd243eb['dialAMDAfterGreetingSilence'];this[_0xdd4a('0x46')]=_0xd243eb[_0xdd4a('0x46')];this['dialAMDMinWordLength']=_0xd243eb[_0xdd4a('0x47')];this['dialAMDBetweenWordsSilence']=_0xd243eb['dialAMDBetweenWordsSilence'];this[_0xdd4a('0x48')]=_0xd243eb[_0xdd4a('0x48')];this[_0xdd4a('0x49')]=_0xd243eb[_0xdd4a('0x49')];this[_0xdd4a('0x4a')]=_0xd243eb[_0xdd4a('0x4a')];this[_0xdd4a('0x4b')]=0x0;this['pTalking']=0x0;this['timeout']=_0xd243eb[_0xdd4a('0x4c')];this[_0xdd4a('0x4d')]=0x0;this['outboundAnswerAgiCallsDay']=0x0;this[_0xdd4a('0x4e')]=0x0;this[_0xdd4a('0x4f')]=0x0;this[_0xdd4a('0x50')]=0x0;this[_0xdd4a('0x51')]=0x0;this['outboundUnknownCallsDay']=0x0;this['outboundBlacklistCallsDay']=0x0;this[_0xdd4a('0x52')]=0x0;this[_0xdd4a('0x53')]=0x0;this[_0xdd4a('0x54')]=0x0;this['outboundDropCallsDayACS']=0x0;this[_0xdd4a('0x55')]=0x0;this[_0xdd4a('0x56')]=0x0;this[_0xdd4a('0x57')]=undefined;this[_0xdd4a('0x58')]=undefined;this[_0xdd4a('0x59')]=undefined;this['predictiveIntervalMultiplicativeFactor']=1.05;this[_0xdd4a('0x5a')]=0x0;this[_0xdd4a('0x5b')]=0x0;this[_0xdd4a('0x5c')]=0x0;this[_0xdd4a('0x5d')]=0x0;this[_0xdd4a('0x5e')]=0x0;this['predictiveIntervalAvgTalktime']=0x0;this[_0xdd4a('0x5f')]=0x0;this[_0xdd4a('0x60')]=0x0;this['predictiveIntervalMaxThreshold']=_0xd243eb[_0xdd4a('0x61')]||0x14;this[_0xdd4a('0x62')]=_0xd243eb[_0xdd4a('0x61')]||0xa;this[_0xdd4a('0x63')]=0x0;this['predictiveIntervalErlangCallsDroppedCalls']=0x0;this['predictiveIntervalHitRate']=0x1;this[_0xdd4a('0x64')]=0x0;this['erlangCallToSecond']=0x0;this[_0xdd4a('0x65')]=0x0;this[_0xdd4a('0x66')]=0x0;this[_0xdd4a('0x67')]=_0xd243eb[_0xdd4a('0x67')]||0x1e;this[_0xdd4a('0x68')]=_0xd243eb[_0xdd4a('0x68')]||![];this[_0xdd4a('0x69')]=_0xd243eb['dialQueueProject2']||undefined;this[_0xdd4a('0x6a')]=_0xd243eb[_0xdd4a('0x6a')]||![];this[_0xdd4a('0x6b')]=_0xd243eb[_0xdd4a('0x6b')]||![];this[_0xdd4a('0xa')]=monitorFormat[_0xd243eb['monitor_format']]?monitorFormat[_0xd243eb[_0xdd4a('0xa')]]:undefined;this[_0xdd4a('0x6c')]=_0xd243eb[_0xdd4a('0x6c')]||![];this[_0xdd4a('0x6d')]=_0xd243eb[_0xdd4a('0x6d')]?_0xd243eb[_0xdd4a('0x6d')]:undefined;}module[_0xdd4a('0x6e')]=VoiceQueue;