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