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