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