Built motion from commit (unavailable).|2.5.30
[motion2.git] / server / services / ami / report / voiceQueueReport.js
index af6d208..876add0 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x4728=['redis','localhost','prototype','enqueue','tail','finally','sequence','agents','queueChannels','voiceQueues','flagQueueSummary','campaigns','variables','queuesummary','syncQueueSummary','syncQueueSummaryComplete','bind','queuecallerjoin','syncQueueCallerJoin','queuecallerabandon','syncQueueCallerAbandon','queuecallerleave','syncQueueCallerLeave','agentcomplete','syncAgentConnect','syncHangup','fullybooted','syncFullyBooted','syncMusicOnHoldStart','musiconholdstop','syncMusicOnHoldStop','attendedtransfer','syncAttendedTransfer','syncBlindTransfer','loopQueueSummary','isEmpty','hasOwnProperty','originated','pTalking','waiting','queueStatusComplete','unlockRR','channels','switch','Action','status','channel','catch','message','No\x20such\x20channel','queueReports','error','[%s][voiceQueueReport][checkQueueReport]','inspect','[%s][voiceQueueReport][checkVariables]','[FullyBooted]\x20clear\x20realtime','clearQueueReport','emitVoiceQueueChannelRemove','emit','emitVoiceQueueChannelSave','debug','[%s][voiceQueueReport][',']\x20sending\x20voice_queue_channel:save\x20event:','voice:queue:%s','name','voice_queue_channel:save',']\x20sending\x20voice_queue_channel:remove\x20event:','format','voice_queue_channel:remove','emitVoiceQueueSummary','inbound','answered','loggedIn','sumDuration','sumHoldTime','talking','unmanaged','abandoned','Trunk','active','callerid','Interval','stringify','md5','voice_queue:save','isNotNull','isUndefined','loopQueueShow','queues','[voiceQueueReport][queues]','then','queue','[voiceQueueReport][queuesummary]\x20event:','[voiceQueueReport][queuesummary]\x20name:%s','callers','toNumber','loggedin','available','[voiceQueueReport][queuesummary]\x20sending\x20queuesummary\x20event:','custom:queuesummary','[voiceQueueReport][queuesummary]','[voiceQueueReport][queuesummarycomplete]\x20event:','[%s][voiceQueueReport][queuecallerjoin]','uniqueid','type','queuecallerjoinAt','YYYY-MM-DD\x20HH:mm:ss','position','count','[voiceQueueReport][queuecallerjoin]\x20name:%s\x20type:%s','pick','keys','push','[%s][voiceQueueReport][queuecallerabandon]','last','queuecallercompleteAt','holdtime','originalposition','queuecallerexitreason','ABANDONED','info','[voiceQueueReport][queuecallerabandon]\x20name:%s\x20type:%s','[%s][voiceQueueReport][queuecallerleave]','queuecallerleaveAt','connectedlinenum','connectedlinename','[%s][voiceQueueReport][agentconnect]','queuecallercomplete','COMPLETEDBYAGENT','[voiceQueueReport][agentconnect]\x20name:%s\x20type:%s\x20queuecallerexitreason:COMPLETEDBYAGENT','syncAgentComplete','[%s][voiceQueueReport][agentcomplete]','queuecallerabandonAt','lastAssignedTo','membername','queuecallerexit','queuecallerexitAt','reason','transfer','COMPLETED','[voiceQueueReport][agentcomplete]\x20name:%s\x20type:%s\x20queuecallerexitreason:COMPLETED','startsWith','linkedid','seconds','FORWARDTRANSFER','transfertype','FORWARD','transferuniqueid','toUpperCase','[voiceQueueReport][agentcomplete]\x20name:%s\x20type:%s\x20queuecallerexitreason:%s','syncVarSet','[%s][voiceQueueReport][varset]','addVariable','variable','value','CONTINUE','TIMEOUT','timeout','varset','queueposition','EXITWITHKEY','[%s][voiceQueueReport][varset]\x20name:%s\x20type:%s\x20variable:%s\x20value:%s','rtpaudioqos','rtpaudioqosbridged','rtpaudioqosjitter','rtpaudioqosjitterbridged','rtpaudioqosloss','rtpaudioqoslossbridged','rtpaudioqosrtt','rtpaudioqosrttbridged','sipcallid','sipuri','bridgepeer','bridgepvtcallid','membercalls','memberinterface','memberlastcall','memberpenalty','memberrealtime','isNil','includes','[%s][voiceQueueReport][hangup]','diff','length','milliseconds','lastevent','custom:queuecallerunmanaged','[%s][voiceQueueReport][hangup]\x20sending\x20queuecallerabandon\x20event:','custom:queuecallerabandon','[%s][voiceQueueReport][hangup]\x20name:%s\x20type:%s\x20reason:%s','cause-txt','hangup','[%s][voiceQueueReport][hangup]\x20sending\x20voiceQueueReport\x20event:','transfereeuniqueid','transferexten','secondtransfererexten','secondtransfereruniqueid','ATTENDEDTRANSFER','ATTENDED','[%s][voiceQueueReport][attendedTransfer]\x20name:%s\x20type:%s\x20transferexten:%s\x20transferuniqueid:%s','transfertargetuniqueid','origtransfererexten','origtransfereruniqueid','[%s][voiceQueueReport][blindtransfer]','extension','[%s][voiceQueueReport][blindTransfer]\x20name:%s\x20type:%s\x20transferexten:%s\x20transferuniqueid:%s','BlindTransfer','context','transfererchannel','[%s][voiceQueueReport][musiconholdstart]','mohstarttime','[%s][voiceQueueReport][musiconholdstart]\x20mohstarttime:%s','[%s][voiceQueueReport][musiconholdstop]','mohtime','exports','moment','util','ioredis','../../../config/environment','ami','../ami','defaults'];(function(_0x4d2e37,_0x1a60d4){var _0x223f0f=function(_0x4b4659){while(--_0x4b4659){_0x4d2e37['push'](_0x4d2e37['shift']());}};_0x223f0f(++_0x1a60d4);}(_0x4728,0x1b5));var _0x8472=function(_0x2dfc49,_0x16d7a3){_0x2dfc49=_0x2dfc49-0x0;var _0x1324e3=_0x4728[_0x2dfc49];return _0x1324e3;};'use strict';var _=require('lodash');var moment=require(_0x8472('0x0'));var util=require(_0x8472('0x1'));var md5=require('md5');var Redis=require(_0x8472('0x2'));var config=require(_0x8472('0x3'));var logger=require('../../../config/logger')(_0x8472('0x4'));var ami=require(_0x8472('0x5'));var QueueReport=require('../model/queueReport');config['redis']=_[_0x8472('0x6')](config[_0x8472('0x7')],{'host':_0x8472('0x8'),'port':0x18eb});var io=require('socket.io-emitter')(new Redis(config[_0x8472('0x7')]));var Sequence=function(){};Sequence[_0x8472('0x9')][_0x8472('0xa')]=function(_0x27861f){this[_0x8472('0xb')]=this[_0x8472('0xb')]?this[_0x8472('0xb')][_0x8472('0xc')](_0x27861f):_0x27861f();};function VoiceQueueReport(_0x1de38a){this[_0x8472('0xd')]=new Sequence();this['queueReports']={};this[_0x8472('0xe')]=_0x1de38a[_0x8472('0xe')];this['channels']=_0x1de38a[_0x8472('0xf')];this[_0x8472('0x10')]=_0x1de38a['voiceQueues'];this[_0x8472('0x11')]=!![];this['campaigns']=_0x1de38a[_0x8472('0x12')];this[_0x8472('0x13')]={};ami['on'](_0x8472('0x14'),this[_0x8472('0x15')]['bind'](this));ami['on']('queuesummarycomplete',this[_0x8472('0x16')][_0x8472('0x17')](this));ami['on'](_0x8472('0x18'),this[_0x8472('0x19')][_0x8472('0x17')](this));ami['on'](_0x8472('0x1a'),this[_0x8472('0x1b')][_0x8472('0x17')](this));ami['on'](_0x8472('0x1c'),this[_0x8472('0x1d')]['bind'](this));ami['on'](_0x8472('0x1e'),this['syncAgentComplete'][_0x8472('0x17')](this));ami['on']('agentconnect',this[_0x8472('0x1f')][_0x8472('0x17')](this));ami['on']('varset',this['syncVarSet'][_0x8472('0x17')](this));ami['on']('hangup',this[_0x8472('0x20')][_0x8472('0x17')](this));ami['on'](_0x8472('0x21'),this[_0x8472('0x22')][_0x8472('0x17')](this));ami['on']('musiconholdstart',this[_0x8472('0x23')][_0x8472('0x17')](this));ami['on'](_0x8472('0x24'),this[_0x8472('0x25')][_0x8472('0x17')](this));ami['on'](_0x8472('0x26'),this[_0x8472('0x27')][_0x8472('0x17')](this));ami['on']('blindtransfer',this[_0x8472('0x28')][_0x8472('0x17')](this));this[_0x8472('0x29')]();this['loopQueueShow']();}function clearChannels(_0x4f49af){if(!_[_0x8472('0x2a')](_0x4f49af)){for(var _0x15e4ac in _0x4f49af){if(_0x4f49af[_0x8472('0x2b')](_0x15e4ac)){delete _0x4f49af[_0x15e4ac];}}}}function clearCampaigns(_0x11dc7c){if(!_['isEmpty'](_0x11dc7c)){for(var _0x39f942 in _0x11dc7c){if(_0x11dc7c[_0x8472('0x2b')](_0x39f942)){_0x11dc7c[_0x39f942][_0x8472('0x2c')]=0x0;}}}}function clearVoiceQueues(_0x654df){if(!_[_0x8472('0x2a')](_0x654df)){for(var _0x54d48d in _0x654df){if(_0x654df[_0x8472('0x2b')](_0x54d48d)){_0x654df[_0x54d48d][_0x8472('0x2c')]=0x0;_0x654df[_0x54d48d]['talking']=0x0;_0x654df[_0x54d48d][_0x8472('0x2d')]=0x0;_0x654df[_0x54d48d][_0x8472('0x2e')]=0x0;_0x654df[_0x54d48d][_0x8472('0x2f')]=!![];}}}}function clearAgentBooked(_0x3bf0b2){if(!_[_0x8472('0x2a')](_0x3bf0b2)){for(var _0x473967 in _0x3bf0b2){if(_0x3bf0b2['hasOwnProperty'](_0x473967)){_0x3bf0b2[_0x473967][_0x8472('0x30')]=!![];}}}}VoiceQueueReport[_0x8472('0x9')]['clearZombieChannels']=function(){var _0x1771e2=this;for(var _0x231ff9 in this['channels']){if(this[_0x8472('0x31')][_0x8472('0x2b')](_0x231ff9)&&!this[_0x8472('0x31')][_0x231ff9][_0x8472('0x32')]){this[_0x8472('0xd')][_0x8472('0xa')](function(){if(!_['isNil'](_0x1771e2[_0x8472('0x31')][_0x231ff9])){return ami[_0x8472('0x33')]({'action':_0x8472('0x34'),'channel':_0x1771e2[_0x8472('0x31')][_0x231ff9][_0x8472('0x35')]})[_0x8472('0x36')](function(_0x384e64){if(_0x384e64[_0x8472('0x37')]===_0x8472('0x38')){setTimeout(function(){if(_0x1771e2[_0x8472('0x31')][_0x231ff9]){delete _0x1771e2[_0x8472('0x31')][_0x231ff9];logger['error']('[%s][voiceQueueReport][checkChannel]',_0x231ff9,util['inspect'](_0x384e64,{'showHidden':![],'depth':null}));}if(_0x1771e2[_0x8472('0x39')][_0x231ff9]){delete _0x1771e2[_0x8472('0x39')][_0x231ff9];logger[_0x8472('0x3a')](_0x8472('0x3b'),_0x231ff9,util[_0x8472('0x3c')](_0x384e64,{'showHidden':![],'depth':null}));}if(_0x1771e2[_0x8472('0x13')][_0x231ff9]){delete _0x1771e2[_0x8472('0x13')][_0x231ff9];logger['error'](_0x8472('0x3d'),_0x231ff9,util[_0x8472('0x3c')](_0x384e64,{'showHidden':![],'depth':null}));}},0x1f40);}});}});}}};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x22')]=function(){logger[_0x8472('0x3a')](_0x8472('0x3e'));clearChannels(this[_0x8472('0x31')]);this[_0x8472('0x3f')](this[_0x8472('0x39')]);clearAgentBooked(this['agents']);clearVoiceQueues(this[_0x8472('0x10')]);clearCampaigns(this['campaigns']);};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x3f')]=function(_0x375ceb){var _0x156992=this;if(!_[_0x8472('0x2a')](_0x375ceb)){for(var _0x17af56 in _0x375ceb){if(_0x375ceb[_0x8472('0x2b')](_0x17af56)){_0x156992[_0x8472('0x40')](_0x375ceb[_0x17af56],'clearqueuereport');delete _0x375ceb[_0x17af56];}}}};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x41')]=function(_0x238297,_0x362ca6,_0x1daa69){io['to'](_0x238297)[_0x8472('0x41')](_0x362ca6,_0x1daa69);};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x42')]=function(_0x5dca3e,_0x48a115){logger[_0x8472('0x43')](_0x8472('0x44')+_0x48a115+_0x8472('0x45'),_0x5dca3e['uniqueid'],util[_0x8472('0x3c')](_0x5dca3e,{'showHidden':![],'depth':null}));this['emit'](util['format'](_0x8472('0x46'),_0x5dca3e[_0x8472('0x47')]),_0x8472('0x48'),_0x5dca3e);};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x40')]=function(_0x568495,_0xb22d84){logger[_0x8472('0x43')](_0x8472('0x44')+_0xb22d84+_0x8472('0x49'),_0x568495['uniqueid'],util[_0x8472('0x3c')](_0x568495,{'showHidden':![],'depth':null}));this['emit'](util[_0x8472('0x4a')]('voice:queue:%s',_0x568495[_0x8472('0x47')]),_0x8472('0x4b'),_0x568495);};VoiceQueueReport['prototype'][_0x8472('0x4c')]=function(_0x496a8b,_0x5e1115){if(_0x496a8b['type']===_0x8472('0x4d')){var _0x444eb8={'id':_0x496a8b['id'],'name':_0x496a8b[_0x8472('0x47')],'strategy':_0x496a8b['strategy'],'answered':_0x496a8b[_0x8472('0x4e')],'available':_0x496a8b['available'],'loggedIn':_0x496a8b[_0x8472('0x4f')],'pTalking':_0x496a8b[_0x8472('0x2d')],'sumBillable':_0x496a8b['sumBillable'],'sumDuration':_0x496a8b[_0x8472('0x50')],'sumHoldTime':_0x496a8b[_0x8472('0x51')]||0x0,'talking':_0x496a8b[_0x8472('0x52')],'total':_0x496a8b['total'],'type':_0x496a8b['type'],'unmanaged':_0x496a8b[_0x8472('0x53')],'abandoned':_0x496a8b[_0x8472('0x54')],'waiting':_0x496a8b[_0x8472('0x2e')]};if(_0x496a8b['Trunk']){_0x444eb8[_0x8472('0x55')]={'id':_0x496a8b[_0x8472('0x55')]['id'],'name':_0x496a8b['Trunk']['name'],'active':_0x496a8b[_0x8472('0x55')][_0x8472('0x56')],'callerid':_0x496a8b[_0x8472('0x55')][_0x8472('0x57')]};}if(_0x496a8b[_0x8472('0x58')]){_0x444eb8[_0x8472('0x58')]={'id':_0x496a8b['Interval']['id'],'name':_0x496a8b['Interval'][_0x8472('0x47')]};}var _0x394cda=md5(JSON[_0x8472('0x59')](_0x444eb8));if(_0x496a8b[_0x8472('0x5a')]!==_0x394cda){_0x496a8b[_0x8472('0x5a')]=_0x394cda;logger[_0x8472('0x43')]('[voiceQueueReport]['+_0x5e1115+']\x20sending\x20voice_queue:save\x20event:',util[_0x8472('0x3c')](_0x444eb8,{'showHidden':![],'depth':null}));this[_0x8472('0x41')](util['format'](_0x8472('0x46'),_0x444eb8[_0x8472('0x47')]),_0x8472('0x5b'),_0x444eb8);}}};VoiceQueueReport['prototype'][_0x8472('0x5c')]=function(_0x474b8f){return _0x474b8f!==null&&!_[_0x8472('0x5d')](_0x474b8f);};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x5e')]=function(){var _0x2e1fb1=this;setInterval(function(){_0x2e1fb1['clearZombieChannels']();ami['Action']({'action':_0x8472('0x5f')})[_0x8472('0x36')](function(_0x3f83b8){logger[_0x8472('0x3a')](_0x8472('0x60'),util['inspect'](_0x3f83b8,{'showHidden':![],'depth':null}));});},0x2710);};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x29')]=function(){var _0x3fbea3=this;setInterval(function(){if(_0x3fbea3[_0x8472('0x11')]){return ami[_0x8472('0x33')]({'action':_0x8472('0x14')})[_0x8472('0x61')](function(_0x5b0d40){_0x3fbea3[_0x8472('0x11')]=![];})[_0x8472('0x36')](function(_0xc6ef67){logger[_0x8472('0x3a')]('[voiceQueueReport][queuesummary]',util[_0x8472('0x3c')](_0xc6ef67,{'showHidden':![],'depth':null}));});}},0x3e8);};VoiceQueueReport[_0x8472('0x9')]['syncQueueSummary']=function(_0x2b3759){try{if(this[_0x8472('0x5c')](_0x2b3759)&&this[_0x8472('0x5c')](_0x2b3759[_0x8472('0x62')])){logger[_0x8472('0x43')](_0x8472('0x63'),util[_0x8472('0x3c')](_0x2b3759,{'showHidden':![],'depth':null}));if(this[_0x8472('0x10')][_0x2b3759[_0x8472('0x62')]]){logger['info'](_0x8472('0x64'),_0x2b3759[_0x8472('0x62')]);var _0x4054bb=_['countBy'](this[_0x8472('0x31')],_0x8472('0x62'))[_0x2b3759[_0x8472('0x62')]]||0x0;var _0x3bfbe4=_0x4054bb-_0x2b3759[_0x8472('0x65')];if(this[_0x8472('0x10')][_0x2b3759[_0x8472('0x62')]][_0x8472('0x2e')]!==_[_0x8472('0x66')](_0x2b3759[_0x8472('0x65')])||this[_0x8472('0x10')][_0x2b3759[_0x8472('0x62')]]['loggedIn']!==_[_0x8472('0x66')](_0x2b3759[_0x8472('0x67')])||this[_0x8472('0x10')][_0x2b3759[_0x8472('0x62')]]['available']!==_[_0x8472('0x66')](_0x2b3759[_0x8472('0x68')])||this[_0x8472('0x10')][_0x2b3759[_0x8472('0x62')]][_0x8472('0x52')]!==_0x3bfbe4){this[_0x8472('0x10')][_0x2b3759[_0x8472('0x62')]]['waiting']=_['toNumber'](_0x2b3759[_0x8472('0x65')]);this['voiceQueues'][_0x2b3759['queue']]['loggedIn']=_[_0x8472('0x66')](_0x2b3759[_0x8472('0x67')]);this[_0x8472('0x10')][_0x2b3759[_0x8472('0x62')]][_0x8472('0x68')]=_[_0x8472('0x66')](_0x2b3759['available']);this['voiceQueues'][_0x2b3759[_0x8472('0x62')]][_0x8472('0x52')]=_0x3bfbe4>0x0?_0x3bfbe4:0x0;this['voiceQueues'][_0x2b3759[_0x8472('0x62')]]['talking']=this['voiceQueues'][_0x2b3759['queue']]['talking']>_['toNumber'](_0x2b3759[_0x8472('0x67')])?_[_0x8472('0x66')](_0x2b3759[_0x8472('0x67')]):this[_0x8472('0x10')][_0x2b3759[_0x8472('0x62')]][_0x8472('0x52')];this[_0x8472('0x4c')](this[_0x8472('0x10')][_0x2b3759['queue']],_0x8472('0x14'));}logger['debug'](_0x8472('0x69'),util['inspect'](this[_0x8472('0x10')][_0x2b3759['queue']],{'showHidden':![],'depth':null}));ami[_0x8472('0x41')](_0x8472('0x6a'),this[_0x8472('0x10')][_0x2b3759[_0x8472('0x62')]]);}}}catch(_0x5a176a){logger['error'](_0x8472('0x6b'),util['inspect'](_0x5a176a,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x16')]=function(_0xb1ff5d){logger[_0x8472('0x43')](_0x8472('0x6c'),util['inspect'](_0xb1ff5d,{'showHidden':![],'depth':null}));this[_0x8472('0x11')]=!![];};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x19')]=function(_0x5c9427){try{if(this['isNotNull'](_0x5c9427)){logger[_0x8472('0x43')](_0x8472('0x6d'),_0x5c9427['uniqueid'],util['inspect'](_0x5c9427,{'showHidden':![],'depth':null}));if(_[_0x8472('0x5d')](this[_0x8472('0x39')][_0x5c9427[_0x8472('0x6e')]])){this['queueReports'][_0x5c9427[_0x8472('0x6e')]]=[];this[_0x8472('0x31')][_0x5c9427[_0x8472('0x6e')]]={};}var _0xeb485f=new QueueReport();_0xeb485f['name']=_0x5c9427[_0x8472('0x62')];_0xeb485f[_0x8472('0x6f')]=this[_0x8472('0x10')][_0xeb485f['name']]&&this[_0x8472('0x10')][_0xeb485f[_0x8472('0x47')]][_0x8472('0x6f')]?this[_0x8472('0x10')][_0xeb485f[_0x8472('0x47')]][_0x8472('0x6f')]||_0x8472('0x4d'):'inbound';_0xeb485f['queue']=_0x5c9427[_0x8472('0x62')];_0xeb485f[_0x8472('0x70')]=moment()['format'](_0x8472('0x71'));_0xeb485f[_0x8472('0x72')]=_0x5c9427[_0x8472('0x72')];_0xeb485f[_0x8472('0x73')]=_0x5c9427[_0x8472('0x73')];_0xeb485f[_0x8472('0x6e')]=_0x5c9427[_0x8472('0x6e')];logger['info'](_0x8472('0x74'),_0xeb485f['name'],_0xeb485f[_0x8472('0x6f')]);_['merge'](_0xeb485f,_[_0x8472('0x75')](_0x5c9427,_[_0x8472('0x76')](_0xeb485f)));this[_0x8472('0x39')][_0x5c9427[_0x8472('0x6e')]][_0x8472('0x77')](_0xeb485f);this['channels'][_0x5c9427['uniqueid']]=_0xeb485f;this['emitVoiceQueueChannelSave'](_0xeb485f,_0x8472('0x18'));}}catch(_0x3b378c){logger[_0x8472('0x3a')](_0x8472('0x6d'),_0x5c9427[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x3b378c,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x1b')]=function(_0x1fd92c){try{if(this['isNotNull'](_0x1fd92c)){logger['debug'](_0x8472('0x78'),_0x1fd92c[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x1fd92c,{'showHidden':![],'depth':null}));if(this[_0x8472('0x39')][_0x1fd92c['uniqueid']]){var _0xe54f7a=_[_0x8472('0x79')](this[_0x8472('0x39')][_0x1fd92c[_0x8472('0x6e')]]);_0xe54f7a['queuecallercomplete']=![];_0xe54f7a[_0x8472('0x7a')]=null;_0xe54f7a[_0x8472('0x7b')]=_0x1fd92c[_0x8472('0x7b')];_0xe54f7a[_0x8472('0x7c')]=_0x1fd92c[_0x8472('0x7c')];_0xe54f7a[_0x8472('0x1a')]=!![];_0xe54f7a['queuecallerabandonAt']=moment()[_0x8472('0x4a')](_0x8472('0x71'));_0xe54f7a[_0x8472('0x7d')]=_0x8472('0x7e');_0xe54f7a['lastAssignedTo']=null;logger[_0x8472('0x7f')](_0x8472('0x80'),_0xe54f7a[_0x8472('0x47')],_0xe54f7a[_0x8472('0x6f')]);this['channels'][_0x1fd92c[_0x8472('0x6e')]]=_0xe54f7a;this[_0x8472('0x40')](_0xe54f7a,_0x8472('0x1a'));}}}catch(_0x40f4d1){logger[_0x8472('0x3a')](_0x8472('0x78'),_0x1fd92c[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x40f4d1,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0x8472('0x9')]['syncQueueCallerLeave']=function(_0x1c978a){try{if(this['isNotNull'](_0x1c978a)){logger['debug'](_0x8472('0x81'),_0x1c978a[_0x8472('0x6e')],util['inspect'](_0x1c978a,{'showHidden':![],'depth':null}));if(this[_0x8472('0x39')][_0x1c978a[_0x8472('0x6e')]]){var _0x20cc6=_[_0x8472('0x79')](this[_0x8472('0x39')][_0x1c978a[_0x8472('0x6e')]]);_0x20cc6[_0x8472('0x82')]=moment()['format']('YYYY-MM-DD\x20HH:mm:ss');_0x20cc6[_0x8472('0x83')]=_0x1c978a[_0x8472('0x83')];_0x20cc6[_0x8472('0x84')]=_0x1c978a[_0x8472('0x84')];logger['info']('[voiceQueueReport][queuecallerleave]\x20name:%s\x20type:%s\x20connectedlinenum:%s\x20connectedlinename:%s',_0x20cc6[_0x8472('0x47')],_0x20cc6[_0x8472('0x6f')],_0x1c978a['connectedlinenum'],_0x1c978a[_0x8472('0x84')]);this[_0x8472('0x31')][_0x1c978a[_0x8472('0x6e')]]=_0x20cc6;this['emitVoiceQueueChannelSave'](_0x20cc6,_0x8472('0x1c'));}}}catch(_0x33b965){logger[_0x8472('0x3a')](_0x8472('0x81'),_0x1c978a['uniqueid'],util[_0x8472('0x3c')](_0x33b965,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x1f')]=function(_0x4d788f){try{if(this['isNotNull'](_0x4d788f)){logger[_0x8472('0x43')](_0x8472('0x85'),_0x4d788f[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x4d788f,{'showHidden':![],'depth':null}));if(this[_0x8472('0x39')][_0x4d788f[_0x8472('0x6e')]]){var _0x4958c2=_[_0x8472('0x79')](this[_0x8472('0x39')][_0x4d788f[_0x8472('0x6e')]]);_0x4958c2[_0x8472('0x86')]=!![];_0x4958c2[_0x8472('0x7d')]=_0x8472('0x87');logger[_0x8472('0x7f')](_0x8472('0x88'),_0x4958c2[_0x8472('0x47')],_0x4958c2[_0x8472('0x6f')]);}}}catch(_0x5449d3){logger['error']('[%s][voiceQueueReport][agentconnect]',_0x4d788f['uniqueid'],util[_0x8472('0x3c')](_0x5449d3,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x89')]=function(_0x3f2b48){try{if(this[_0x8472('0x5c')](_0x3f2b48)){logger[_0x8472('0x43')](_0x8472('0x8a'),_0x3f2b48['uniqueid'],util['inspect'](_0x3f2b48,{'showHidden':![],'depth':null}));if(this['queueReports'][_0x3f2b48['uniqueid']]){var _0x49ff03=_[_0x8472('0x79')](this[_0x8472('0x39')][_0x3f2b48[_0x8472('0x6e')]]);_0x49ff03[_0x8472('0x1a')]=![];_0x49ff03[_0x8472('0x8b')]=null;_0x49ff03['assigned']=!![];_0x49ff03[_0x8472('0x8c')]=_0x3f2b48[_0x8472('0x8d')];_0x49ff03[_0x8472('0x7b')]=_0x3f2b48[_0x8472('0x7b')];_0x49ff03['queuecallercomplete']=!![];_0x49ff03[_0x8472('0x8e')]=![];_0x49ff03[_0x8472('0x8f')]=null;if(!_0x49ff03['transfer']){if(_0x3f2b48[_0x8472('0x90')]==_0x8472('0x91')){_0x49ff03[_0x8472('0x7d')]=_0x8472('0x92');logger[_0x8472('0x7f')](_0x8472('0x93'),_0x49ff03[_0x8472('0x47')],_0x49ff03[_0x8472('0x6f')]);}else{if(_[_0x8472('0x94')](_0x3f2b48['channel']['toLowerCase'](),'local/')){if(this[_0x8472('0x39')][_0x3f2b48[_0x8472('0x95')]]){var _0x161921=_['last'](this[_0x8472('0x39')][_0x3f2b48[_0x8472('0x95')]]);_0x161921[_0x8472('0x86')]=![];_0x161921[_0x8472('0x8e')]=!![];_0x161921[_0x8472('0x8f')]=moment(_0x49ff03['queuecallerjoinAt'])['add'](_0x3f2b48[_0x8472('0x7b')],_0x8472('0x96'))[_0x8472('0x4a')](_0x8472('0x71'));_0x161921[_0x8472('0x7d')]=_0x8472('0x97');_0x161921['transfer']=!![];_0x161921[_0x8472('0x98')]=_0x8472('0x99');_0x161921['transferexten']=_0x3f2b48['destexten'];_0x161921[_0x8472('0x9a')]=_0x3f2b48[_0x8472('0x6e')];logger[_0x8472('0x7f')]('[voiceQueueReport][agentcomplete]\x20name:%s\x20type:%s\x20queuecallerexitreason:FORWARDTRANSFER',_0x161921[_0x8472('0x47')],_0x161921[_0x8472('0x6f')]);var _0x2c620b=this[_0x8472('0x39')][_0x3f2b48[_0x8472('0x95')]];this['queueReports'][_0x3f2b48[_0x8472('0x95')]]=this[_0x8472('0x39')][_0x3f2b48[_0x8472('0x6e')]];this[_0x8472('0x39')][_0x3f2b48['uniqueid']]=_0x2c620b;}}else{_0x49ff03[_0x8472('0x7d')]='COMPLETEDBY'+_0x3f2b48[_0x8472('0x90')][_0x8472('0x9b')]();logger[_0x8472('0x7f')](_0x8472('0x9c'),_0x49ff03[_0x8472('0x47')],_0x49ff03[_0x8472('0x6f')],_0x49ff03[_0x8472('0x7d')]);}}}this['channels'][_0x3f2b48[_0x8472('0x6e')]]=_0x49ff03;this['emitVoiceQueueChannelRemove'](_0x49ff03,_0x8472('0x1e'));}}}catch(_0x3024fc){logger[_0x8472('0x3a')](_0x8472('0x8a'),_0x3f2b48[_0x8472('0x6e')],util['inspect'](_0x3024fc,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x9d')]=function(_0x23d733){try{if(this[_0x8472('0x5c')](_0x23d733)){logger[_0x8472('0x43')](_0x8472('0x9e'),_0x23d733[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x23d733,{'showHidden':![],'depth':null}));this[_0x8472('0x9f')](_0x23d733[_0x8472('0x6e')],_['keys'](_0x23d733[_0x8472('0xa0')])[0x0],_0x23d733[_0x8472('0xa1')]);if(this['queueReports'][_0x23d733[_0x8472('0x6e')]]){var _0x21036e=_[_0x8472('0x79')](this['queueReports'][_0x23d733[_0x8472('0x6e')]]);if(_0x21036e){if(this[_0x8472('0x5c')](_0x23d733['variable'])&&this[_0x8472('0x5c')](_0x23d733[_0x8472('0xa0')]['queuestatus'])){switch(_0x23d733[_0x8472('0xa1')]){case _0x8472('0xa2'):_0x21036e[_0x8472('0x8e')]=![];_0x21036e['queuecallerexitAt']=null;break;case _0x8472('0xa3'):_0x21036e['lastevent']=_0x8472('0xa4');_0x21036e[_0x8472('0x8e')]=!![];_0x21036e[_0x8472('0x8f')]=moment()['format'](_0x8472('0x71'));_0x21036e[_0x8472('0x82')]=moment()[_0x8472('0x4a')]('YYYY-MM-DD\x20HH:mm:ss');logger['debug']('[%s][voiceQueueReport][varset]\x20sending\x20timeout\x20event:',_0x23d733[_0x8472('0x6e')],util['inspect'](_0x21036e,{'showHidden':![],'depth':null}));ami[_0x8472('0x41')]('custom:timeout',_0x21036e);break;default:_0x21036e[_0x8472('0x8e')]=!![];_0x21036e[_0x8472('0x8f')]=moment()[_0x8472('0x4a')]('YYYY-MM-DD\x20HH:mm:ss');_0x21036e[_0x8472('0x82')]=moment()['format'](_0x8472('0x71'));}_0x21036e[_0x8472('0x1a')]=![];_0x21036e[_0x8472('0x8b')]=null;_0x21036e[_0x8472('0x7d')]=_0x23d733[_0x8472('0xa1')];this[_0x8472('0x31')][_0x23d733[_0x8472('0x6e')]]=_0x21036e;this[_0x8472('0x40')](_0x21036e,_0x8472('0xa5'));}else if(this['isNotNull'](_0x23d733[_0x8472('0xa0')])&&this['isNotNull'](_0x23d733[_0x8472('0xa0')][_0x8472('0xa6')])){if(!_0x21036e['queuecallerabandon']){_0x21036e[_0x8472('0x8e')]=!![];_0x21036e[_0x8472('0x8f')]=moment()[_0x8472('0x4a')](_0x8472('0x71'));_0x21036e[_0x8472('0x7d')]=_0x8472('0xa7');_0x21036e[_0x8472('0x82')]=moment()[_0x8472('0x4a')](_0x8472('0x71'));this[_0x8472('0x31')][_0x23d733[_0x8472('0x6e')]]=_0x21036e;}}logger[_0x8472('0x7f')](_0x8472('0xa8'),_0x23d733[_0x8472('0x6e')],_0x21036e['name'],_0x21036e[_0x8472('0x6f')],_[_0x8472('0x76')](_0x23d733[_0x8472('0xa0')])[0x0],_0x23d733[_0x8472('0xa1')]);_0x21036e[_0x8472('0x13')]=this[_0x8472('0x13')][_0x23d733['uniqueid']];}}}}catch(_0x24a620){logger['error']('[%s][voiceQueueReport][varset]',_0x23d733[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x24a620,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x9f')]=function(_0x4ee810,_0x4e9c83,_0x590062){var _0x14bcf4=[_0x8472('0xa9'),_0x8472('0xaa'),_0x8472('0xab'),_0x8472('0xac'),_0x8472('0xad'),_0x8472('0xae'),_0x8472('0xaf'),_0x8472('0xb0'),_0x8472('0xb1'),_0x8472('0xb2'),_0x8472('0xb3'),_0x8472('0xb4'),_0x8472('0xb5'),'memberdynamic',_0x8472('0xb6'),_0x8472('0xb7'),'membername',_0x8472('0xb8'),_0x8472('0xb9')];if(!_[_0x8472('0xba')](_0x4e9c83)&&!_[_0x8472('0xbb')](_0x14bcf4,_0x4e9c83)){if(_[_0x8472('0x5d')](this[_0x8472('0x13')][_0x4ee810])){this[_0x8472('0x13')][_0x4ee810]={};}this['variables'][_0x4ee810][_0x4e9c83]=_0x590062;}};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x20')]=function(_0x288ac9){try{if(this['isNotNull'](_0x288ac9)){logger[_0x8472('0x43')](_0x8472('0xbc'),_0x288ac9[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x288ac9,{'showHidden':![],'depth':null}));if(this[_0x8472('0x39')][_0x288ac9[_0x8472('0x6e')]]){for(var _0x1f575a=0x0,_0x4cf127={};_0x1f575a<this['queueReports'][_0x288ac9['uniqueid']]['length'];_0x1f575a+=0x1){_0x4cf127=this[_0x8472('0x39')][_0x288ac9[_0x8472('0x6e')]][_0x1f575a];if(this[_0x8472('0x10')][_0x4cf127['queue']]){if(_0x4cf127['queuecallerexit']&&_0x4cf127['transfer']!=!![]){this[_0x8472('0x10')][_0x4cf127[_0x8472('0x62')]][_0x8472('0x53')]+=0x1;}if(_0x4cf127[_0x8472('0x1a')]){this[_0x8472('0x10')][_0x4cf127[_0x8472('0x62')]][_0x8472('0x54')]+=0x1;}this[_0x8472('0x10')][_0x4cf127[_0x8472('0x62')]][_0x8472('0x51')]+=moment(_0x4cf127['queuecallerleaveAt'])[_0x8472('0xbd')](_0x4cf127[_0x8472('0x70')],_0x8472('0x96'))||0x0;if(_0x1f575a===this[_0x8472('0x39')][_0x288ac9[_0x8472('0x6e')]][_0x8472('0xbe')]-0x1){this[_0x8472('0x10')][_0x4cf127['queue']]['sumDuration']+=moment()[_0x8472('0xbf')](0x0)['diff'](_0x4cf127['queuecallerjoinAt'],_0x8472('0x96'));this[_0x8472('0x10')][_0x4cf127[_0x8472('0x62')]]['total']+=0x1;if(_0x4cf127[_0x8472('0x86')]){this[_0x8472('0x10')][_0x4cf127[_0x8472('0x62')]]['answered']+=0x1;this[_0x8472('0x10')][_0x4cf127['queue']]['sumBillable']+=moment()[_0x8472('0xbf')](0x0)[_0x8472('0xbd')](_0x4cf127['queuecallerleaveAt'],_0x8472('0x96'));_0x4cf127[_0x8472('0x7a')]=moment()['format'](_0x8472('0x71'));_0x4cf127[_0x8472('0x8e')]=![];_0x4cf127[_0x8472('0x8f')]=null;}if(_0x4cf127[_0x8472('0x8e')]&&_0x4cf127[_0x8472('0x91')]!=!![]){_0x4cf127[_0x8472('0xc0')]=_0x8472('0x53');logger[_0x8472('0x43')]('[%s][voiceQueueReport][hangup]\x20sending\x20queuecallerunmanaged\x20event:',_0x288ac9[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x4cf127,{'showHidden':![],'depth':null}));ami[_0x8472('0x41')](_0x8472('0xc1'),_0x4cf127);}if(_0x4cf127[_0x8472('0x1a')]){_0x4cf127[_0x8472('0xc0')]=_0x8472('0x54');logger[_0x8472('0x43')](_0x8472('0xc2'),_0x288ac9[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x4cf127,{'showHidden':![],'depth':null}));ami[_0x8472('0x41')](_0x8472('0xc3'),_0x4cf127);}}else{this[_0x8472('0x10')][_0x4cf127[_0x8472('0x62')]]['sumDuration']+=this['voiceQueues'][_0x4cf127[_0x8472('0x62')]][_0x8472('0x51')];}logger[_0x8472('0x7f')](_0x8472('0xc4'),_0x288ac9[_0x8472('0x6e')],_0x4cf127[_0x8472('0x47')],_0x4cf127[_0x8472('0x6f')],_0x288ac9[_0x8472('0xc5')]);this[_0x8472('0x31')][_0x288ac9['uniqueid']]=_0x4cf127;this[_0x8472('0x40')](_0x4cf127,_0x8472('0xc6'));this[_0x8472('0x4c')](this['voiceQueues'][_0x4cf127[_0x8472('0x62')]],_0x8472('0xc6'));}}logger['debug'](_0x8472('0xc7'),_0x288ac9['uniqueid'],util['inspect'](this[_0x8472('0x39')][_0x288ac9['uniqueid']],{'showHidden':![],'depth':null}));ami['emit']('custom:voiceQueueReport',this[_0x8472('0x39')][_0x288ac9['uniqueid']]);delete this[_0x8472('0x39')][_0x288ac9['uniqueid']];delete this['channels'][_0x288ac9[_0x8472('0x6e')]];}if(this[_0x8472('0x13')][_0x288ac9[_0x8472('0x6e')]]){delete this[_0x8472('0x13')][_0x288ac9[_0x8472('0x6e')]];}}}catch(_0x3c1428){logger[_0x8472('0x3a')](_0x8472('0xbc'),_0x288ac9[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x3c1428,{'showHidden':![],'depth':null}));}};VoiceQueueReport['prototype'][_0x8472('0x27')]=function(_0x5ec647){try{if(this['isNotNull'](_0x5ec647)){logger[_0x8472('0x43')]('[%s][voiceQueueReport][attendedtransfer]',_0x5ec647['uniqueid'],util[_0x8472('0x3c')](_0x5ec647,{'showHidden':![],'depth':null}));var _0x3cd2cf;if(this[_0x8472('0x39')][_0x5ec647['transfereeuniqueid']]){_0x3cd2cf=_[_0x8472('0x79')](this[_0x8472('0x39')][_0x5ec647[_0x8472('0xc8')]]);_0x3cd2cf[_0x8472('0xc9')]=_0x5ec647[_0x8472('0xca')];_0x3cd2cf[_0x8472('0x9a')]=_0x5ec647[_0x8472('0xcb')];_0x3cd2cf['queuecallerexitreason']=_0x8472('0xcc');_0x3cd2cf[_0x8472('0x91')]=!![];_0x3cd2cf['transfertype']=_0x8472('0xcd');if(this[_0x8472('0x39')][_0x5ec647['secondtransfereruniqueid']]){var _0x355caa=this[_0x8472('0x39')][_0x5ec647['secondtransfereruniqueid']];this[_0x8472('0x39')][_0x5ec647['secondtransfereruniqueid']]=this[_0x8472('0x39')][_0x5ec647[_0x8472('0xc8')]];this[_0x8472('0x39')][_0x5ec647[_0x8472('0xc8')]]=_0x355caa;var _0x23b383=_['last'](this[_0x8472('0x39')][_0x5ec647[_0x8472('0xc8')]]);_0x23b383[_0x8472('0x32')]=!![];}logger[_0x8472('0x7f')](_0x8472('0xce'),_0x5ec647[_0x8472('0x6e')],_0x3cd2cf[_0x8472('0x47')],_0x3cd2cf[_0x8472('0x6f')],_0x3cd2cf[_0x8472('0xc9')],_0x3cd2cf[_0x8472('0x9a')]);}else if(this['queueReports'][_0x5ec647[_0x8472('0xcf')]]){_0x3cd2cf=_[_0x8472('0x79')](this['queueReports'][_0x5ec647[_0x8472('0xcf')]]);_0x3cd2cf['transferexten']=_0x5ec647[_0x8472('0xd0')];_0x3cd2cf[_0x8472('0x9a')]=_0x5ec647[_0x8472('0xd1')];_0x3cd2cf[_0x8472('0x7d')]='ATTENDEDTRANSFER';_0x3cd2cf['transfer']=!![];_0x3cd2cf[_0x8472('0x98')]=_0x8472('0xcd');if(this['queueReports'][_0x5ec647[_0x8472('0xd1')]]){var _0x355caa=this['queueReports'][_0x5ec647[_0x8472('0xd1')]];this[_0x8472('0x39')][_0x5ec647[_0x8472('0xd1')]]=this[_0x8472('0x39')][_0x5ec647['transfertargetuniqueid']];this[_0x8472('0x39')][_0x5ec647['transfertargetuniqueid']]=_0x355caa;var _0x23b383=_[_0x8472('0x79')](this[_0x8472('0x39')][_0x5ec647[_0x8472('0xcf')]]);_0x23b383[_0x8472('0x32')]=!![];}logger[_0x8472('0x7f')](_0x8472('0xce'),_0x5ec647[_0x8472('0x6e')],_0x3cd2cf[_0x8472('0x47')],_0x3cd2cf[_0x8472('0x6f')],_0x3cd2cf[_0x8472('0xc9')],_0x3cd2cf['transferuniqueid']);}}}catch(_0xa7bf17){logger[_0x8472('0x3a')]('[%s][voiceQueueReport][attendedtransfer]',_0x5ec647[_0x8472('0x6e')],util[_0x8472('0x3c')](_0xa7bf17,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0x8472('0x9')][_0x8472('0x28')]=function(_0xd1c8a2){try{if(this[_0x8472('0x5c')](_0xd1c8a2)){logger[_0x8472('0x43')](_0x8472('0xd2'),_0xd1c8a2[_0x8472('0x6e')],util[_0x8472('0x3c')](_0xd1c8a2,{'showHidden':![],'depth':null}));if(this['queueReports'][_0xd1c8a2[_0x8472('0xc8')]]){var _0x18a983=_[_0x8472('0x79')](this[_0x8472('0x39')][_0xd1c8a2[_0x8472('0xc8')]]);_0x18a983['queuecallerexitreason']='BLINDTRANSFER';_0x18a983['transfer']=!![];_0x18a983[_0x8472('0x98')]='BLIND';_0x18a983[_0x8472('0xc9')]=_0xd1c8a2[_0x8472('0xd3')];_0x18a983[_0x8472('0x9a')]=_0xd1c8a2[_0x8472('0xc8')];logger[_0x8472('0x7f')](_0x8472('0xd4'),_0xd1c8a2[_0x8472('0x6e')],_0x18a983[_0x8472('0x47')],_0x18a983[_0x8472('0x6f')],_0x18a983['transferexten'],_0x18a983[_0x8472('0x9a')]);this[_0x8472('0x20')]({'event':_0x8472('0xd5'),'uniqueid':_0xd1c8a2[_0x8472('0xc8')],'context':_0xd1c8a2[_0x8472('0xd6')],'channel':_0xd1c8a2[_0x8472('0xd7')]});}}}catch(_0x2486d5){logger[_0x8472('0x3a')](_0x8472('0xd2'),_0xd1c8a2[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x2486d5,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0x8472('0x9')]['syncMusicOnHoldStart']=function(_0x4bdd5b){try{if(this['isNotNull'](_0x4bdd5b)){logger['debug'](_0x8472('0xd8'),_0x4bdd5b[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x4bdd5b,{'showHidden':![],'depth':null}));if(this['queueReports'][_0x4bdd5b[_0x8472('0x6e')]]){var _0x1e6eca=_['last'](this[_0x8472('0x39')][_0x4bdd5b['uniqueid']]);if(!_[_0x8472('0xba')](_0x1e6eca[_0x8472('0x82')])){_0x1e6eca[_0x8472('0xd9')]=moment()['format'](_0x8472('0x71'));logger['info'](_0x8472('0xda'),_0x4bdd5b[_0x8472('0x6e')],_0x1e6eca[_0x8472('0xd9')]);}}}}catch(_0xe21167){logger[_0x8472('0x3a')](_0x8472('0xd8'),_0x4bdd5b['uniqueid'],util['inspect'](_0xe21167,{'showHidden':![],'depth':null}));}};VoiceQueueReport['prototype'][_0x8472('0x25')]=function(_0x34c80c){try{if(this[_0x8472('0x5c')](_0x34c80c)){logger[_0x8472('0x43')](_0x8472('0xdb'),_0x34c80c['uniqueid'],util[_0x8472('0x3c')](_0x34c80c,{'showHidden':![],'depth':null}));if(this[_0x8472('0x39')][_0x34c80c[_0x8472('0x6e')]]){var _0x3ef1f9=_[_0x8472('0x79')](this[_0x8472('0x39')][_0x34c80c[_0x8472('0x6e')]]);if(!_[_0x8472('0xba')](_0x3ef1f9[_0x8472('0xd9')])){_0x3ef1f9[_0x8472('0xdc')]+=moment()[_0x8472('0xbf')](0x0)[_0x8472('0xbd')](_0x3ef1f9['mohstarttime'],_0x8472('0x96'));logger[_0x8472('0x7f')]('[%s][voiceQueueReport][musiconholdstop]\x20mohtime:%s',_0x34c80c[_0x8472('0x6e')],_0x3ef1f9['mohtime']);delete _0x3ef1f9[_0x8472('0xd9')];}}}}catch(_0x379c5c){logger['error']('[%s][voiceQueueReport][musiconholdstop]',_0x34c80c[_0x8472('0x6e')],util[_0x8472('0x3c')](_0x379c5c,{'showHidden':![],'depth':null}));}};module[_0x8472('0xdd')]=VoiceQueueReport;
\ No newline at end of file
+var _0x720c=['[voiceQueueReport][queuesummary]\x20event:','[voiceQueueReport][queuesummary]\x20name:%s','countBy','callers','toNumber','loggedin','emitVoiceQueueSummary','[voiceQueueReport][queuesummary]\x20sending\x20queuesummary\x20event:','custom:queuesummary','[voiceQueueReport][queuesummarycomplete]\x20event:','[%s][voiceQueueReport][queuecallerjoin]','inbound','queuecallerjoinAt','position','count','info','[voiceQueueReport][queuecallerjoin]\x20name:%s\x20type:%s','merge','pick','keys','push','[%s][voiceQueueReport][queuecallerabandon]','queuecallercompleteAt','holdtime','originalposition','queuecallerabandonAt','YYYY-MM-DD\x20HH:mm:ss','queuecallerexitreason','ABANDONED','lastAssignedTo','[voiceQueueReport][queuecallerabandon]\x20name:%s\x20type:%s','[%s][voiceQueueReport][queuecallerleave]','last','queuecallerleaveAt','connectedlinenum','connectedlinename','[voiceQueueReport][queuecallerleave]\x20name:%s\x20type:%s\x20connectedlinenum:%s\x20connectedlinename:%s','queuecallerleave','[%s][voiceQueueReport][agentconnect]','queuecallercomplete','[voiceQueueReport][agentconnect]\x20name:%s\x20type:%s\x20queuecallerexitreason:COMPLETEDBYAGENT','[%s][voiceQueueReport][agentcomplete]','assigned','membername','queuecallerexit','transfer','[voiceQueueReport][agentcomplete]\x20name:%s\x20type:%s\x20queuecallerexitreason:COMPLETED','startsWith','toLowerCase','local/','linkedid','queuecallerexitAt','seconds','transfertype','FORWARD','transferexten','destexten','transferuniqueid','[voiceQueueReport][agentcomplete]\x20name:%s\x20type:%s\x20queuecallerexitreason:FORWARDTRANSFER','COMPLETEDBY','reason','toUpperCase','[voiceQueueReport][agentcomplete]\x20name:%s\x20type:%s\x20queuecallerexitreason:%s','addVariable','variable','value','CONTINUE','TIMEOUT','timeout','[%s][voiceQueueReport][varset]\x20sending\x20timeout\x20event:','custom:timeout','EXITWITHKEY','[%s][voiceQueueReport][varset]\x20name:%s\x20type:%s\x20variable:%s\x20value:%s','[%s][voiceQueueReport][varset]','rtpaudioqosjitter','rtpaudioqosloss','rtpaudioqoslossbridged','rtpaudioqosrtt','rtpaudioqosrttbridged','sipcallid','sipuri','bridgepvtcallid','membercalls','memberdynamic','memberpenalty','memberrealtime','includes','[%s][voiceQueueReport][hangup]','length','diff','sumDuration','milliseconds','lastevent','custom:queuecallerunmanaged','[%s][voiceQueueReport][hangup]\x20sending\x20queuecallerabandon\x20event:','[%s][voiceQueueReport][hangup]\x20name:%s\x20type:%s\x20reason:%s','[%s][voiceQueueReport][hangup]\x20sending\x20voiceQueueReport\x20event:','custom:voiceQueueReport','syncAttendedTransfer','[%s][voiceQueueReport][attendedtransfer]','transfereeuniqueid','secondtransfereruniqueid','ATTENDEDTRANSFER','ATTENDED','switch','[%s][voiceQueueReport][attendedTransfer]\x20name:%s\x20type:%s\x20transferexten:%s\x20transferuniqueid:%s','transfertargetuniqueid','origtransfereruniqueid','[%s][voiceQueueReport][blindtransfer]','BLINDTRANSFER','[%s][voiceQueueReport][blindTransfer]\x20name:%s\x20type:%s\x20transferexten:%s\x20transferuniqueid:%s','context','[%s][voiceQueueReport][musiconholdstart]','mohstarttime','[%s][voiceQueueReport][musiconholdstart]\x20mohstarttime:%s','[%s][voiceQueueReport][musiconholdstop]','mohtime','[%s][voiceQueueReport][musiconholdstop]\x20mohtime:%s','exports','lodash','util','md5','ioredis','../../../config/environment','ami','../ami','../model/queueReport','redis','defaults','localhost','prototype','enqueue','tail','finally','sequence','queueReports','agents','channels','queueChannels','voiceQueues','campaigns','variables','queuesummary','bind','queuesummarycomplete','syncQueueSummaryComplete','queuecallerjoin','syncQueueCallerJoin','queuecallerabandon','syncQueueCallerAbandon','syncQueueCallerLeave','agentcomplete','syncAgentComplete','agentconnect','syncAgentConnect','varset','syncVarSet','hangup','syncHangup','musiconholdstart','syncMusicOnHoldStart','musiconholdstop','syncMusicOnHoldStop','attendedtransfer','syncBlindTransfer','loopQueueShow','isEmpty','hasOwnProperty','originated','pTalking','waiting','queueStatusComplete','clearZombieChannels','isNil','Action','status','channel','catch','No\x20such\x20channel','inspect','error','[%s][voiceQueueReport][checkVariables]','[FullyBooted]\x20clear\x20realtime','clearQueueReport','emitVoiceQueueChannelRemove','emit','emitVoiceQueueChannelSave','[%s][voiceQueueReport][',']\x20sending\x20voice_queue_channel:save\x20event:','format','voice:queue:%s','name','voice_queue_channel:save','debug',']\x20sending\x20voice_queue_channel:remove\x20event:','uniqueid','voice_queue_presence:remove','type','strategy','answered','available','loggedIn','sumBillable','sumHoldTime','talking','total','unmanaged','abandoned','Trunk','callerid','Interval','stringify','[voiceQueueReport][','isNotNull','isUndefined','[voiceQueueReport][queues]','then','flagQueueSummary','[voiceQueueReport][queuesummary]','syncQueueSummary','queue'];(function(_0x1e9eb6,_0x190d4a){var _0x2c89e5=function(_0xfd31e1){while(--_0xfd31e1){_0x1e9eb6['push'](_0x1e9eb6['shift']());}};_0x2c89e5(++_0x190d4a);}(_0x720c,0x154));var _0xc720=function(_0x525511,_0x3b9d9b){_0x525511=_0x525511-0x0;var _0x1ab032=_0x720c[_0x525511];return _0x1ab032;};'use strict';var _=require(_0xc720('0x0'));var moment=require('moment');var util=require(_0xc720('0x1'));var md5=require(_0xc720('0x2'));var Redis=require(_0xc720('0x3'));var config=require(_0xc720('0x4'));var logger=require('../../../config/logger')(_0xc720('0x5'));var ami=require(_0xc720('0x6'));var QueueReport=require(_0xc720('0x7'));config[_0xc720('0x8')]=_[_0xc720('0x9')](config[_0xc720('0x8')],{'host':_0xc720('0xa'),'port':0x18eb});var io=require('socket.io-emitter')(new Redis(config[_0xc720('0x8')]));var Sequence=function(){};Sequence[_0xc720('0xb')][_0xc720('0xc')]=function(_0x1a2a00){this[_0xc720('0xd')]=this['tail']?this['tail'][_0xc720('0xe')](_0x1a2a00):_0x1a2a00();};function VoiceQueueReport(_0x4bea5d){this[_0xc720('0xf')]=new Sequence();this[_0xc720('0x10')]={};this['agents']=_0x4bea5d[_0xc720('0x11')];this[_0xc720('0x12')]=_0x4bea5d[_0xc720('0x13')];this[_0xc720('0x14')]=_0x4bea5d[_0xc720('0x14')];this['flagQueueSummary']=!![];this[_0xc720('0x15')]=_0x4bea5d[_0xc720('0x15')];this[_0xc720('0x16')]={};ami['on'](_0xc720('0x17'),this['syncQueueSummary'][_0xc720('0x18')](this));ami['on'](_0xc720('0x19'),this[_0xc720('0x1a')]['bind'](this));ami['on'](_0xc720('0x1b'),this[_0xc720('0x1c')][_0xc720('0x18')](this));ami['on'](_0xc720('0x1d'),this[_0xc720('0x1e')]['bind'](this));ami['on']('queuecallerleave',this[_0xc720('0x1f')]['bind'](this));ami['on'](_0xc720('0x20'),this[_0xc720('0x21')]['bind'](this));ami['on'](_0xc720('0x22'),this[_0xc720('0x23')][_0xc720('0x18')](this));ami['on'](_0xc720('0x24'),this[_0xc720('0x25')][_0xc720('0x18')](this));ami['on'](_0xc720('0x26'),this[_0xc720('0x27')][_0xc720('0x18')](this));ami['on']('fullybooted',this['syncFullyBooted']['bind'](this));ami['on'](_0xc720('0x28'),this[_0xc720('0x29')][_0xc720('0x18')](this));ami['on'](_0xc720('0x2a'),this[_0xc720('0x2b')][_0xc720('0x18')](this));ami['on'](_0xc720('0x2c'),this['syncAttendedTransfer'][_0xc720('0x18')](this));ami['on']('blindtransfer',this[_0xc720('0x2d')][_0xc720('0x18')](this));this['loopQueueSummary']();this[_0xc720('0x2e')]();}function clearChannels(_0x2d6b3f){if(!_[_0xc720('0x2f')](_0x2d6b3f)){for(var _0x232cb1 in _0x2d6b3f){if(_0x2d6b3f[_0xc720('0x30')](_0x232cb1)){delete _0x2d6b3f[_0x232cb1];}}}}function clearCampaigns(_0x141cb5){if(!_[_0xc720('0x2f')](_0x141cb5)){for(var _0x5a8b03 in _0x141cb5){if(_0x141cb5[_0xc720('0x30')](_0x5a8b03)){_0x141cb5[_0x5a8b03][_0xc720('0x31')]=0x0;}}}}function clearVoiceQueues(_0x522428){if(!_[_0xc720('0x2f')](_0x522428)){for(var _0x2c7e75 in _0x522428){if(_0x522428['hasOwnProperty'](_0x2c7e75)){_0x522428[_0x2c7e75][_0xc720('0x31')]=0x0;_0x522428[_0x2c7e75]['talking']=0x0;_0x522428[_0x2c7e75][_0xc720('0x32')]=0x0;_0x522428[_0x2c7e75][_0xc720('0x33')]=0x0;_0x522428[_0x2c7e75][_0xc720('0x34')]=!![];}}}}function clearAgentBooked(_0x84d71e){if(!_[_0xc720('0x2f')](_0x84d71e)){for(var _0x4760a0 in _0x84d71e){if(_0x84d71e[_0xc720('0x30')](_0x4760a0)){_0x84d71e[_0x4760a0]['unlockRR']=!![];}}}}VoiceQueueReport['prototype'][_0xc720('0x35')]=function(){var _0x34e19d=this;for(var _0x531cee in this[_0xc720('0x12')]){if(this['channels'][_0xc720('0x30')](_0x531cee)&&!this[_0xc720('0x12')][_0x531cee]['switch']){this[_0xc720('0xf')][_0xc720('0xc')](function(){if(!_[_0xc720('0x36')](_0x34e19d[_0xc720('0x12')][_0x531cee])){return ami[_0xc720('0x37')]({'action':_0xc720('0x38'),'channel':_0x34e19d[_0xc720('0x12')][_0x531cee][_0xc720('0x39')]})[_0xc720('0x3a')](function(_0x422e01){if(_0x422e01['message']===_0xc720('0x3b')){setTimeout(function(){if(_0x34e19d['channels'][_0x531cee]){delete _0x34e19d[_0xc720('0x12')][_0x531cee];logger['error']('[%s][voiceQueueReport][checkChannel]',_0x531cee,util[_0xc720('0x3c')](_0x422e01,{'showHidden':![],'depth':null}));}if(_0x34e19d[_0xc720('0x10')][_0x531cee]){delete _0x34e19d[_0xc720('0x10')][_0x531cee];logger[_0xc720('0x3d')]('[%s][voiceQueueReport][checkQueueReport]',_0x531cee,util[_0xc720('0x3c')](_0x422e01,{'showHidden':![],'depth':null}));}if(_0x34e19d[_0xc720('0x16')][_0x531cee]){delete _0x34e19d['variables'][_0x531cee];logger[_0xc720('0x3d')](_0xc720('0x3e'),_0x531cee,util[_0xc720('0x3c')](_0x422e01,{'showHidden':![],'depth':null}));}},0x1f40);}});}});}}};VoiceQueueReport[_0xc720('0xb')]['syncFullyBooted']=function(){logger[_0xc720('0x3d')](_0xc720('0x3f'));clearChannels(this['channels']);this['clearQueueReport'](this[_0xc720('0x10')]);clearAgentBooked(this[_0xc720('0x11')]);clearVoiceQueues(this['voiceQueues']);clearCampaigns(this[_0xc720('0x15')]);};VoiceQueueReport['prototype'][_0xc720('0x40')]=function(_0x1bb558){var _0x25408e=this;if(!_[_0xc720('0x2f')](_0x1bb558)){for(var _0x4740db in _0x1bb558){if(_0x1bb558['hasOwnProperty'](_0x4740db)){_0x25408e[_0xc720('0x41')](_0x1bb558[_0x4740db],'clearqueuereport');delete _0x1bb558[_0x4740db];}}}};VoiceQueueReport[_0xc720('0xb')]['emit']=function(_0x57fa43,_0x407c47,_0x2b86e1){io['to'](_0x57fa43)[_0xc720('0x42')](_0x407c47,_0x2b86e1);};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x43')]=function(_0x517536,_0x1d71f7){logger['debug'](_0xc720('0x44')+_0x1d71f7+_0xc720('0x45'),_0x517536['uniqueid'],util[_0xc720('0x3c')](_0x517536,{'showHidden':![],'depth':null}));this[_0xc720('0x42')](util[_0xc720('0x46')](_0xc720('0x47'),_0x517536[_0xc720('0x48')]),_0xc720('0x49'),_0x517536);io[_0xc720('0x42')]('voice_queue_presence:save',_0x517536);};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x41')]=function(_0x20a18d,_0x5b1f21){logger[_0xc720('0x4a')](_0xc720('0x44')+_0x5b1f21+_0xc720('0x4b'),_0x20a18d[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x20a18d,{'showHidden':![],'depth':null}));this[_0xc720('0x42')](util[_0xc720('0x46')](_0xc720('0x47'),_0x20a18d[_0xc720('0x48')]),'voice_queue_channel:remove',_0x20a18d);io[_0xc720('0x42')](_0xc720('0x4d'),_0x20a18d);};VoiceQueueReport[_0xc720('0xb')]['emitVoiceQueueSummary']=function(_0xfc9eac,_0x3e53f8){if(_0xfc9eac[_0xc720('0x4e')]==='inbound'){var _0x1b76ff={'id':_0xfc9eac['id'],'name':_0xfc9eac[_0xc720('0x48')],'strategy':_0xfc9eac[_0xc720('0x4f')],'answered':_0xfc9eac[_0xc720('0x50')],'available':_0xfc9eac[_0xc720('0x51')],'loggedIn':_0xfc9eac[_0xc720('0x52')],'pTalking':_0xfc9eac[_0xc720('0x32')],'sumBillable':_0xfc9eac[_0xc720('0x53')],'sumDuration':_0xfc9eac['sumDuration'],'sumHoldTime':_0xfc9eac[_0xc720('0x54')]||0x0,'talking':_0xfc9eac[_0xc720('0x55')],'total':_0xfc9eac[_0xc720('0x56')],'type':_0xfc9eac[_0xc720('0x4e')],'unmanaged':_0xfc9eac[_0xc720('0x57')],'abandoned':_0xfc9eac[_0xc720('0x58')],'waiting':_0xfc9eac['waiting']};if(_0xfc9eac[_0xc720('0x59')]){_0x1b76ff['Trunk']={'id':_0xfc9eac[_0xc720('0x59')]['id'],'name':_0xfc9eac[_0xc720('0x59')][_0xc720('0x48')],'active':_0xfc9eac[_0xc720('0x59')]['active'],'callerid':_0xfc9eac[_0xc720('0x59')][_0xc720('0x5a')]};}if(_0xfc9eac[_0xc720('0x5b')]){_0x1b76ff['Interval']={'id':_0xfc9eac['Interval']['id'],'name':_0xfc9eac['Interval']['name']};}var _0x4f152c=md5(JSON[_0xc720('0x5c')](_0x1b76ff));if(_0xfc9eac['md5']!==_0x4f152c){_0xfc9eac[_0xc720('0x2')]=_0x4f152c;logger['debug'](_0xc720('0x5d')+_0x3e53f8+']\x20sending\x20voice_queue:save\x20event:',util[_0xc720('0x3c')](_0x1b76ff,{'showHidden':![],'depth':null}));this[_0xc720('0x42')](util['format'](_0xc720('0x47'),_0x1b76ff[_0xc720('0x48')]),'voice_queue:save',_0x1b76ff);}}};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x5e')]=function(_0x5dbed4){return _0x5dbed4!==null&&!_[_0xc720('0x5f')](_0x5dbed4);};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x2e')]=function(){var _0x2980fb=this;setInterval(function(){_0x2980fb[_0xc720('0x35')]();ami[_0xc720('0x37')]({'action':'queues'})['catch'](function(_0x2d3c41){logger[_0xc720('0x3d')](_0xc720('0x60'),util[_0xc720('0x3c')](_0x2d3c41,{'showHidden':![],'depth':null}));});},0x2710);};VoiceQueueReport[_0xc720('0xb')]['loopQueueSummary']=function(){var _0x3ed89b=this;setInterval(function(){if(_0x3ed89b['flagQueueSummary']){return ami[_0xc720('0x37')]({'action':_0xc720('0x17')})[_0xc720('0x61')](function(_0x3e9609){_0x3ed89b[_0xc720('0x62')]=![];})[_0xc720('0x3a')](function(_0x4200e1){logger[_0xc720('0x3d')](_0xc720('0x63'),util[_0xc720('0x3c')](_0x4200e1,{'showHidden':![],'depth':null}));});}},0x3e8);};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x64')]=function(_0x379edd){try{if(this[_0xc720('0x5e')](_0x379edd)&&this[_0xc720('0x5e')](_0x379edd[_0xc720('0x65')])){logger[_0xc720('0x4a')](_0xc720('0x66'),util[_0xc720('0x3c')](_0x379edd,{'showHidden':![],'depth':null}));if(this[_0xc720('0x14')][_0x379edd[_0xc720('0x65')]]){logger['info'](_0xc720('0x67'),_0x379edd[_0xc720('0x65')]);var _0x5b1751=_[_0xc720('0x68')](this[_0xc720('0x12')],_0xc720('0x65'))[_0x379edd['queue']]||0x0;var _0x47e7c5=_0x5b1751-_0x379edd['callers'];if(this[_0xc720('0x14')][_0x379edd[_0xc720('0x65')]]['waiting']!==_['toNumber'](_0x379edd[_0xc720('0x69')])||this[_0xc720('0x14')][_0x379edd['queue']]['loggedIn']!==_[_0xc720('0x6a')](_0x379edd[_0xc720('0x6b')])||this['voiceQueues'][_0x379edd[_0xc720('0x65')]][_0xc720('0x51')]!==_[_0xc720('0x6a')](_0x379edd[_0xc720('0x51')])||this[_0xc720('0x14')][_0x379edd[_0xc720('0x65')]][_0xc720('0x55')]!==_0x47e7c5){this['voiceQueues'][_0x379edd[_0xc720('0x65')]][_0xc720('0x33')]=_[_0xc720('0x6a')](_0x379edd[_0xc720('0x69')]);this[_0xc720('0x14')][_0x379edd[_0xc720('0x65')]]['loggedIn']=_[_0xc720('0x6a')](_0x379edd[_0xc720('0x6b')]);this[_0xc720('0x14')][_0x379edd[_0xc720('0x65')]][_0xc720('0x51')]=_[_0xc720('0x6a')](_0x379edd[_0xc720('0x51')]);this['voiceQueues'][_0x379edd[_0xc720('0x65')]][_0xc720('0x55')]=_0x47e7c5>0x0?_0x47e7c5:0x0;this['voiceQueues'][_0x379edd[_0xc720('0x65')]][_0xc720('0x55')]=this[_0xc720('0x14')][_0x379edd[_0xc720('0x65')]][_0xc720('0x55')]>_[_0xc720('0x6a')](_0x379edd['loggedin'])?_['toNumber'](_0x379edd[_0xc720('0x6b')]):this[_0xc720('0x14')][_0x379edd[_0xc720('0x65')]]['talking'];this[_0xc720('0x6c')](this['voiceQueues'][_0x379edd[_0xc720('0x65')]],_0xc720('0x17'));}logger[_0xc720('0x4a')](_0xc720('0x6d'),util[_0xc720('0x3c')](this[_0xc720('0x14')][_0x379edd['queue']],{'showHidden':![],'depth':null}));ami[_0xc720('0x42')](_0xc720('0x6e'),this['voiceQueues'][_0x379edd[_0xc720('0x65')]]);}}}catch(_0x4040e9){logger[_0xc720('0x3d')](_0xc720('0x63'),util[_0xc720('0x3c')](_0x4040e9,{'showHidden':![],'depth':null}));}};VoiceQueueReport['prototype'][_0xc720('0x1a')]=function(_0x35f916){logger[_0xc720('0x4a')](_0xc720('0x6f'),util[_0xc720('0x3c')](_0x35f916,{'showHidden':![],'depth':null}));this[_0xc720('0x62')]=!![];};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x1c')]=function(_0x46e301){try{if(this[_0xc720('0x5e')](_0x46e301)){logger['debug'](_0xc720('0x70'),_0x46e301[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x46e301,{'showHidden':![],'depth':null}));if(_[_0xc720('0x5f')](this[_0xc720('0x10')][_0x46e301[_0xc720('0x4c')]])){this[_0xc720('0x10')][_0x46e301[_0xc720('0x4c')]]=[];this[_0xc720('0x12')][_0x46e301[_0xc720('0x4c')]]={};}var _0xc29c71=new QueueReport();_0xc29c71[_0xc720('0x48')]=_0x46e301[_0xc720('0x65')];_0xc29c71['type']=this['voiceQueues'][_0xc29c71['name']]&&this[_0xc720('0x14')][_0xc29c71[_0xc720('0x48')]][_0xc720('0x4e')]?this['voiceQueues'][_0xc29c71['name']]['type']||_0xc720('0x71'):_0xc720('0x71');_0xc29c71['queue']=_0x46e301[_0xc720('0x65')];_0xc29c71[_0xc720('0x72')]=moment()[_0xc720('0x46')]('YYYY-MM-DD\x20HH:mm:ss');_0xc29c71[_0xc720('0x73')]=_0x46e301[_0xc720('0x73')];_0xc29c71[_0xc720('0x74')]=_0x46e301[_0xc720('0x74')];_0xc29c71[_0xc720('0x4c')]=_0x46e301['uniqueid'];logger[_0xc720('0x75')](_0xc720('0x76'),_0xc29c71[_0xc720('0x48')],_0xc29c71[_0xc720('0x4e')]);_[_0xc720('0x77')](_0xc29c71,_[_0xc720('0x78')](_0x46e301,_[_0xc720('0x79')](_0xc29c71)));this[_0xc720('0x10')][_0x46e301[_0xc720('0x4c')]][_0xc720('0x7a')](_0xc29c71);this['channels'][_0x46e301[_0xc720('0x4c')]]=_0xc29c71;this[_0xc720('0x43')](_0xc29c71,_0xc720('0x1b'));}}catch(_0x5b56b2){logger[_0xc720('0x3d')](_0xc720('0x70'),_0x46e301[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x5b56b2,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x1e')]=function(_0x5bec36){try{if(this['isNotNull'](_0x5bec36)){logger[_0xc720('0x4a')](_0xc720('0x7b'),_0x5bec36[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x5bec36,{'showHidden':![],'depth':null}));if(this[_0xc720('0x10')][_0x5bec36['uniqueid']]){var _0x240440=_['last'](this[_0xc720('0x10')][_0x5bec36[_0xc720('0x4c')]]);_0x240440['queuecallercomplete']=![];_0x240440[_0xc720('0x7c')]=null;_0x240440['holdtime']=_0x5bec36[_0xc720('0x7d')];_0x240440[_0xc720('0x7e')]=_0x5bec36['originalposition'];_0x240440['queuecallerabandon']=!![];_0x240440[_0xc720('0x7f')]=moment()[_0xc720('0x46')](_0xc720('0x80'));_0x240440[_0xc720('0x81')]=_0xc720('0x82');_0x240440[_0xc720('0x83')]=null;logger[_0xc720('0x75')](_0xc720('0x84'),_0x240440[_0xc720('0x48')],_0x240440[_0xc720('0x4e')]);this[_0xc720('0x12')][_0x5bec36['uniqueid']]=_0x240440;this['emitVoiceQueueChannelRemove'](_0x240440,_0xc720('0x1d'));}}}catch(_0x4e36aa){logger['error'](_0xc720('0x7b'),_0x5bec36[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x4e36aa,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x1f')]=function(_0x3d2996){try{if(this[_0xc720('0x5e')](_0x3d2996)){logger['debug'](_0xc720('0x85'),_0x3d2996[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x3d2996,{'showHidden':![],'depth':null}));if(this[_0xc720('0x10')][_0x3d2996['uniqueid']]){var _0x308806=_[_0xc720('0x86')](this[_0xc720('0x10')][_0x3d2996[_0xc720('0x4c')]]);_0x308806[_0xc720('0x87')]=moment()[_0xc720('0x46')](_0xc720('0x80'));_0x308806[_0xc720('0x88')]=_0x3d2996[_0xc720('0x88')];_0x308806[_0xc720('0x89')]=_0x3d2996[_0xc720('0x89')];logger[_0xc720('0x75')](_0xc720('0x8a'),_0x308806[_0xc720('0x48')],_0x308806[_0xc720('0x4e')],_0x3d2996[_0xc720('0x88')],_0x3d2996['connectedlinename']);this[_0xc720('0x12')][_0x3d2996['uniqueid']]=_0x308806;this[_0xc720('0x43')](_0x308806,_0xc720('0x8b'));}}}catch(_0xb57e5f){logger[_0xc720('0x3d')](_0xc720('0x85'),_0x3d2996['uniqueid'],util[_0xc720('0x3c')](_0xb57e5f,{'showHidden':![],'depth':null}));}};VoiceQueueReport['prototype']['syncAgentConnect']=function(_0x202891){try{if(this[_0xc720('0x5e')](_0x202891)){logger[_0xc720('0x4a')](_0xc720('0x8c'),_0x202891[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x202891,{'showHidden':![],'depth':null}));if(this[_0xc720('0x10')][_0x202891[_0xc720('0x4c')]]){var _0xb3a698=_[_0xc720('0x86')](this[_0xc720('0x10')][_0x202891['uniqueid']]);_0xb3a698[_0xc720('0x8d')]=!![];_0xb3a698[_0xc720('0x81')]='COMPLETEDBYAGENT';logger['info'](_0xc720('0x8e'),_0xb3a698[_0xc720('0x48')],_0xb3a698['type']);}}}catch(_0x4118fe){logger[_0xc720('0x3d')](_0xc720('0x8c'),_0x202891[_0xc720('0x4c')],util['inspect'](_0x4118fe,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x21')]=function(_0x5ad6e5){try{if(this[_0xc720('0x5e')](_0x5ad6e5)){logger[_0xc720('0x4a')](_0xc720('0x8f'),_0x5ad6e5['uniqueid'],util[_0xc720('0x3c')](_0x5ad6e5,{'showHidden':![],'depth':null}));if(this[_0xc720('0x10')][_0x5ad6e5[_0xc720('0x4c')]]){var _0x2091dc=_[_0xc720('0x86')](this[_0xc720('0x10')][_0x5ad6e5[_0xc720('0x4c')]]);_0x2091dc[_0xc720('0x1d')]=![];_0x2091dc[_0xc720('0x7f')]=null;_0x2091dc[_0xc720('0x90')]=!![];_0x2091dc[_0xc720('0x83')]=_0x5ad6e5[_0xc720('0x91')];_0x2091dc['holdtime']=_0x5ad6e5[_0xc720('0x7d')];_0x2091dc[_0xc720('0x8d')]=!![];_0x2091dc[_0xc720('0x92')]=![];_0x2091dc['queuecallerexitAt']=null;if(!_0x2091dc[_0xc720('0x93')]){if(_0x5ad6e5['reason']==_0xc720('0x93')){_0x2091dc['queuecallerexitreason']='COMPLETED';logger['info'](_0xc720('0x94'),_0x2091dc[_0xc720('0x48')],_0x2091dc[_0xc720('0x4e')]);}else{if(_[_0xc720('0x95')](_0x5ad6e5['channel'][_0xc720('0x96')](),_0xc720('0x97'))){if(this[_0xc720('0x10')][_0x5ad6e5['linkedid']]){var _0x506112=_[_0xc720('0x86')](this[_0xc720('0x10')][_0x5ad6e5[_0xc720('0x98')]]);_0x506112['queuecallercomplete']=![];_0x506112['queuecallerexit']=!![];_0x506112[_0xc720('0x99')]=moment(_0x2091dc[_0xc720('0x72')])['add'](_0x5ad6e5[_0xc720('0x7d')],_0xc720('0x9a'))[_0xc720('0x46')](_0xc720('0x80'));_0x506112[_0xc720('0x81')]='FORWARDTRANSFER';_0x506112[_0xc720('0x93')]=!![];_0x506112[_0xc720('0x9b')]=_0xc720('0x9c');_0x506112[_0xc720('0x9d')]=_0x5ad6e5[_0xc720('0x9e')];_0x506112[_0xc720('0x9f')]=_0x5ad6e5[_0xc720('0x4c')];logger[_0xc720('0x75')](_0xc720('0xa0'),_0x506112[_0xc720('0x48')],_0x506112[_0xc720('0x4e')]);var _0xf54775=this[_0xc720('0x10')][_0x5ad6e5['linkedid']];this['queueReports'][_0x5ad6e5['linkedid']]=this[_0xc720('0x10')][_0x5ad6e5[_0xc720('0x4c')]];this[_0xc720('0x10')][_0x5ad6e5['uniqueid']]=_0xf54775;}}else{_0x2091dc[_0xc720('0x81')]=_0xc720('0xa1')+_0x5ad6e5[_0xc720('0xa2')][_0xc720('0xa3')]();logger[_0xc720('0x75')](_0xc720('0xa4'),_0x2091dc['name'],_0x2091dc[_0xc720('0x4e')],_0x2091dc[_0xc720('0x81')]);}}}this[_0xc720('0x12')][_0x5ad6e5[_0xc720('0x4c')]]=_0x2091dc;this[_0xc720('0x41')](_0x2091dc,_0xc720('0x20'));}}}catch(_0x4a24a4){logger[_0xc720('0x3d')]('[%s][voiceQueueReport][agentcomplete]',_0x5ad6e5[_0xc720('0x4c')],util['inspect'](_0x4a24a4,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x25')]=function(_0x5d0e45){try{if(this[_0xc720('0x5e')](_0x5d0e45)){logger[_0xc720('0x4a')]('[%s][voiceQueueReport][varset]',_0x5d0e45[_0xc720('0x4c')],util['inspect'](_0x5d0e45,{'showHidden':![],'depth':null}));this[_0xc720('0xa5')](_0x5d0e45[_0xc720('0x4c')],_['keys'](_0x5d0e45['variable'])[0x0],_0x5d0e45['value']);if(this['queueReports'][_0x5d0e45['uniqueid']]){var _0x4ba3a0=_[_0xc720('0x86')](this[_0xc720('0x10')][_0x5d0e45[_0xc720('0x4c')]]);if(_0x4ba3a0){if(this['isNotNull'](_0x5d0e45[_0xc720('0xa6')])&&this[_0xc720('0x5e')](_0x5d0e45['variable']['queuestatus'])){switch(_0x5d0e45[_0xc720('0xa7')]){case _0xc720('0xa8'):_0x4ba3a0['queuecallerexit']=![];_0x4ba3a0['queuecallerexitAt']=null;break;case _0xc720('0xa9'):_0x4ba3a0['lastevent']=_0xc720('0xaa');_0x4ba3a0[_0xc720('0x92')]=!![];_0x4ba3a0['queuecallerexitAt']=moment()[_0xc720('0x46')](_0xc720('0x80'));_0x4ba3a0[_0xc720('0x87')]=moment()[_0xc720('0x46')](_0xc720('0x80'));logger['debug'](_0xc720('0xab'),_0x5d0e45['uniqueid'],util[_0xc720('0x3c')](_0x4ba3a0,{'showHidden':![],'depth':null}));ami[_0xc720('0x42')](_0xc720('0xac'),_0x4ba3a0);break;default:_0x4ba3a0['queuecallerexit']=!![];_0x4ba3a0['queuecallerexitAt']=moment()[_0xc720('0x46')](_0xc720('0x80'));_0x4ba3a0[_0xc720('0x87')]=moment()['format'](_0xc720('0x80'));}_0x4ba3a0[_0xc720('0x1d')]=![];_0x4ba3a0[_0xc720('0x7f')]=null;_0x4ba3a0[_0xc720('0x81')]=_0x5d0e45[_0xc720('0xa7')];this[_0xc720('0x12')][_0x5d0e45[_0xc720('0x4c')]]=_0x4ba3a0;this[_0xc720('0x41')](_0x4ba3a0,'varset');}else if(this[_0xc720('0x5e')](_0x5d0e45['variable'])&&this[_0xc720('0x5e')](_0x5d0e45[_0xc720('0xa6')]['queueposition'])){if(!_0x4ba3a0[_0xc720('0x1d')]){_0x4ba3a0[_0xc720('0x92')]=!![];_0x4ba3a0['queuecallerexitAt']=moment()[_0xc720('0x46')](_0xc720('0x80'));_0x4ba3a0[_0xc720('0x81')]=_0xc720('0xad');_0x4ba3a0[_0xc720('0x87')]=moment()[_0xc720('0x46')]('YYYY-MM-DD\x20HH:mm:ss');this[_0xc720('0x12')][_0x5d0e45['uniqueid']]=_0x4ba3a0;}}logger['info'](_0xc720('0xae'),_0x5d0e45[_0xc720('0x4c')],_0x4ba3a0['name'],_0x4ba3a0[_0xc720('0x4e')],_['keys'](_0x5d0e45[_0xc720('0xa6')])[0x0],_0x5d0e45['value']);_0x4ba3a0[_0xc720('0x16')]=this[_0xc720('0x16')][_0x5d0e45[_0xc720('0x4c')]];}}}}catch(_0x4f68d3){logger['error'](_0xc720('0xaf'),_0x5d0e45[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x4f68d3,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0xc720('0xb')][_0xc720('0xa5')]=function(_0x150369,_0x1b926a,_0x3dffa7){var _0x293a48=['rtpaudioqos','rtpaudioqosbridged',_0xc720('0xb0'),'rtpaudioqosjitterbridged',_0xc720('0xb1'),_0xc720('0xb2'),_0xc720('0xb3'),_0xc720('0xb4'),_0xc720('0xb5'),_0xc720('0xb6'),'bridgepeer',_0xc720('0xb7'),_0xc720('0xb8'),_0xc720('0xb9'),'memberinterface','memberlastcall',_0xc720('0x91'),_0xc720('0xba'),_0xc720('0xbb')];if(!_[_0xc720('0x36')](_0x1b926a)&&!_[_0xc720('0xbc')](_0x293a48,_0x1b926a)){if(_['isUndefined'](this[_0xc720('0x16')][_0x150369])){this[_0xc720('0x16')][_0x150369]={};}this[_0xc720('0x16')][_0x150369][_0x1b926a]=_0x3dffa7;}};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x27')]=function(_0x37f8b7){try{if(this[_0xc720('0x5e')](_0x37f8b7)){logger[_0xc720('0x4a')](_0xc720('0xbd'),_0x37f8b7[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x37f8b7,{'showHidden':![],'depth':null}));if(this[_0xc720('0x10')][_0x37f8b7[_0xc720('0x4c')]]){for(var _0x45bbd3=0x0,_0x5f3c1c={};_0x45bbd3<this['queueReports'][_0x37f8b7[_0xc720('0x4c')]][_0xc720('0xbe')];_0x45bbd3+=0x1){_0x5f3c1c=this[_0xc720('0x10')][_0x37f8b7[_0xc720('0x4c')]][_0x45bbd3];if(this[_0xc720('0x14')][_0x5f3c1c[_0xc720('0x65')]]){if(_0x5f3c1c[_0xc720('0x92')]&&_0x5f3c1c[_0xc720('0x93')]!=!![]){this[_0xc720('0x14')][_0x5f3c1c[_0xc720('0x65')]][_0xc720('0x57')]+=0x1;}if(_0x5f3c1c[_0xc720('0x1d')]){this[_0xc720('0x14')][_0x5f3c1c[_0xc720('0x65')]][_0xc720('0x58')]+=0x1;}this[_0xc720('0x14')][_0x5f3c1c[_0xc720('0x65')]][_0xc720('0x54')]+=moment(_0x5f3c1c[_0xc720('0x87')])[_0xc720('0xbf')](_0x5f3c1c['queuecallerjoinAt'],_0xc720('0x9a'))||0x0;if(_0x45bbd3===this[_0xc720('0x10')][_0x37f8b7[_0xc720('0x4c')]][_0xc720('0xbe')]-0x1){this['voiceQueues'][_0x5f3c1c[_0xc720('0x65')]][_0xc720('0xc0')]+=moment()[_0xc720('0xc1')](0x0)[_0xc720('0xbf')](_0x5f3c1c[_0xc720('0x72')],_0xc720('0x9a'));this[_0xc720('0x14')][_0x5f3c1c[_0xc720('0x65')]]['total']+=0x1;if(_0x5f3c1c['queuecallercomplete']){this['voiceQueues'][_0x5f3c1c[_0xc720('0x65')]][_0xc720('0x50')]+=0x1;this[_0xc720('0x14')][_0x5f3c1c[_0xc720('0x65')]]['sumBillable']+=moment()[_0xc720('0xc1')](0x0)['diff'](_0x5f3c1c[_0xc720('0x87')],_0xc720('0x9a'));_0x5f3c1c[_0xc720('0x7c')]=moment()[_0xc720('0x46')](_0xc720('0x80'));_0x5f3c1c['queuecallerexit']=![];_0x5f3c1c[_0xc720('0x99')]=null;}if(_0x5f3c1c[_0xc720('0x92')]&&_0x5f3c1c[_0xc720('0x93')]!=!![]){_0x5f3c1c[_0xc720('0xc2')]=_0xc720('0x57');logger[_0xc720('0x4a')]('[%s][voiceQueueReport][hangup]\x20sending\x20queuecallerunmanaged\x20event:',_0x37f8b7[_0xc720('0x4c')],util['inspect'](_0x5f3c1c,{'showHidden':![],'depth':null}));ami[_0xc720('0x42')](_0xc720('0xc3'),_0x5f3c1c);}if(_0x5f3c1c[_0xc720('0x1d')]){_0x5f3c1c[_0xc720('0xc2')]=_0xc720('0x58');logger[_0xc720('0x4a')](_0xc720('0xc4'),_0x37f8b7[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x5f3c1c,{'showHidden':![],'depth':null}));ami[_0xc720('0x42')]('custom:queuecallerabandon',_0x5f3c1c);}}else{this['voiceQueues'][_0x5f3c1c['queue']][_0xc720('0xc0')]+=this[_0xc720('0x14')][_0x5f3c1c[_0xc720('0x65')]][_0xc720('0x54')];}logger[_0xc720('0x75')](_0xc720('0xc5'),_0x37f8b7[_0xc720('0x4c')],_0x5f3c1c['name'],_0x5f3c1c['type'],_0x37f8b7['cause-txt']);this['channels'][_0x37f8b7[_0xc720('0x4c')]]=_0x5f3c1c;this['emitVoiceQueueChannelRemove'](_0x5f3c1c,_0xc720('0x26'));this[_0xc720('0x6c')](this[_0xc720('0x14')][_0x5f3c1c[_0xc720('0x65')]],_0xc720('0x26'));}}logger['debug'](_0xc720('0xc6'),_0x37f8b7[_0xc720('0x4c')],util[_0xc720('0x3c')](this[_0xc720('0x10')][_0x37f8b7['uniqueid']],{'showHidden':![],'depth':null}));ami[_0xc720('0x42')](_0xc720('0xc7'),this[_0xc720('0x10')][_0x37f8b7[_0xc720('0x4c')]]);delete this[_0xc720('0x10')][_0x37f8b7[_0xc720('0x4c')]];delete this['channels'][_0x37f8b7[_0xc720('0x4c')]];}if(this[_0xc720('0x16')][_0x37f8b7[_0xc720('0x4c')]]){delete this[_0xc720('0x16')][_0x37f8b7[_0xc720('0x4c')]];}}}catch(_0x329817){logger[_0xc720('0x3d')]('[%s][voiceQueueReport][hangup]',_0x37f8b7['uniqueid'],util[_0xc720('0x3c')](_0x329817,{'showHidden':![],'depth':null}));}};VoiceQueueReport['prototype'][_0xc720('0xc8')]=function(_0x256ed0){try{if(this[_0xc720('0x5e')](_0x256ed0)){logger[_0xc720('0x4a')](_0xc720('0xc9'),_0x256ed0[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x256ed0,{'showHidden':![],'depth':null}));var _0x2b43c1;if(this[_0xc720('0x10')][_0x256ed0[_0xc720('0xca')]]){_0x2b43c1=_['last'](this[_0xc720('0x10')][_0x256ed0[_0xc720('0xca')]]);_0x2b43c1[_0xc720('0x9d')]=_0x256ed0['secondtransfererexten'];_0x2b43c1['transferuniqueid']=_0x256ed0[_0xc720('0xcb')];_0x2b43c1[_0xc720('0x81')]=_0xc720('0xcc');_0x2b43c1[_0xc720('0x93')]=!![];_0x2b43c1['transfertype']=_0xc720('0xcd');if(this[_0xc720('0x10')][_0x256ed0[_0xc720('0xcb')]]){var _0x584c48=this['queueReports'][_0x256ed0[_0xc720('0xcb')]];this['queueReports'][_0x256ed0[_0xc720('0xcb')]]=this['queueReports'][_0x256ed0[_0xc720('0xca')]];this['queueReports'][_0x256ed0[_0xc720('0xca')]]=_0x584c48;var _0x5d3483=_[_0xc720('0x86')](this[_0xc720('0x10')][_0x256ed0[_0xc720('0xca')]]);_0x5d3483[_0xc720('0xce')]=!![];}logger[_0xc720('0x75')](_0xc720('0xcf'),_0x256ed0['uniqueid'],_0x2b43c1[_0xc720('0x48')],_0x2b43c1[_0xc720('0x4e')],_0x2b43c1['transferexten'],_0x2b43c1['transferuniqueid']);}else if(this[_0xc720('0x10')][_0x256ed0[_0xc720('0xd0')]]){_0x2b43c1=_[_0xc720('0x86')](this['queueReports'][_0x256ed0[_0xc720('0xd0')]]);_0x2b43c1[_0xc720('0x9d')]=_0x256ed0['origtransfererexten'];_0x2b43c1[_0xc720('0x9f')]=_0x256ed0['origtransfereruniqueid'];_0x2b43c1['queuecallerexitreason']='ATTENDEDTRANSFER';_0x2b43c1[_0xc720('0x93')]=!![];_0x2b43c1[_0xc720('0x9b')]=_0xc720('0xcd');if(this[_0xc720('0x10')][_0x256ed0[_0xc720('0xd1')]]){var _0x584c48=this[_0xc720('0x10')][_0x256ed0[_0xc720('0xd1')]];this[_0xc720('0x10')][_0x256ed0[_0xc720('0xd1')]]=this[_0xc720('0x10')][_0x256ed0[_0xc720('0xd0')]];this['queueReports'][_0x256ed0[_0xc720('0xd0')]]=_0x584c48;var _0x5d3483=_['last'](this[_0xc720('0x10')][_0x256ed0[_0xc720('0xd0')]]);_0x5d3483[_0xc720('0xce')]=!![];}logger[_0xc720('0x75')]('[%s][voiceQueueReport][attendedTransfer]\x20name:%s\x20type:%s\x20transferexten:%s\x20transferuniqueid:%s',_0x256ed0[_0xc720('0x4c')],_0x2b43c1['name'],_0x2b43c1[_0xc720('0x4e')],_0x2b43c1[_0xc720('0x9d')],_0x2b43c1[_0xc720('0x9f')]);}}}catch(_0x65a4bc){logger[_0xc720('0x3d')](_0xc720('0xc9'),_0x256ed0['uniqueid'],util[_0xc720('0x3c')](_0x65a4bc,{'showHidden':![],'depth':null}));}};VoiceQueueReport[_0xc720('0xb')][_0xc720('0x2d')]=function(_0x29a1b1){try{if(this[_0xc720('0x5e')](_0x29a1b1)){logger[_0xc720('0x4a')](_0xc720('0xd2'),_0x29a1b1['uniqueid'],util[_0xc720('0x3c')](_0x29a1b1,{'showHidden':![],'depth':null}));if(this[_0xc720('0x10')][_0x29a1b1['transfereeuniqueid']]){var _0x297f7d=_[_0xc720('0x86')](this[_0xc720('0x10')][_0x29a1b1[_0xc720('0xca')]]);_0x297f7d[_0xc720('0x81')]=_0xc720('0xd3');_0x297f7d[_0xc720('0x93')]=!![];_0x297f7d['transfertype']='BLIND';_0x297f7d[_0xc720('0x9d')]=_0x29a1b1['extension'];_0x297f7d[_0xc720('0x9f')]=_0x29a1b1[_0xc720('0xca')];logger[_0xc720('0x75')](_0xc720('0xd4'),_0x29a1b1['uniqueid'],_0x297f7d[_0xc720('0x48')],_0x297f7d[_0xc720('0x4e')],_0x297f7d[_0xc720('0x9d')],_0x297f7d['transferuniqueid']);this['syncHangup']({'event':'BlindTransfer','uniqueid':_0x29a1b1[_0xc720('0xca')],'context':_0x29a1b1[_0xc720('0xd5')],'channel':_0x29a1b1['transfererchannel']});}}}catch(_0x3509eb){logger[_0xc720('0x3d')](_0xc720('0xd2'),_0x29a1b1['uniqueid'],util[_0xc720('0x3c')](_0x3509eb,{'showHidden':![],'depth':null}));}};VoiceQueueReport['prototype'][_0xc720('0x29')]=function(_0xe9e24){try{if(this[_0xc720('0x5e')](_0xe9e24)){logger['debug'](_0xc720('0xd6'),_0xe9e24[_0xc720('0x4c')],util[_0xc720('0x3c')](_0xe9e24,{'showHidden':![],'depth':null}));if(this['queueReports'][_0xe9e24[_0xc720('0x4c')]]){var _0x418d64=_[_0xc720('0x86')](this['queueReports'][_0xe9e24[_0xc720('0x4c')]]);if(!_['isNil'](_0x418d64[_0xc720('0x87')])){_0x418d64[_0xc720('0xd7')]=moment()[_0xc720('0x46')](_0xc720('0x80'));logger[_0xc720('0x75')](_0xc720('0xd8'),_0xe9e24[_0xc720('0x4c')],_0x418d64[_0xc720('0xd7')]);}}}}catch(_0x1b5b2d){logger[_0xc720('0x3d')](_0xc720('0xd6'),_0xe9e24[_0xc720('0x4c')],util['inspect'](_0x1b5b2d,{'showHidden':![],'depth':null}));}};VoiceQueueReport['prototype'][_0xc720('0x2b')]=function(_0x181c2f){try{if(this['isNotNull'](_0x181c2f)){logger[_0xc720('0x4a')](_0xc720('0xd9'),_0x181c2f[_0xc720('0x4c')],util[_0xc720('0x3c')](_0x181c2f,{'showHidden':![],'depth':null}));if(this[_0xc720('0x10')][_0x181c2f['uniqueid']]){var _0x42649f=_[_0xc720('0x86')](this[_0xc720('0x10')][_0x181c2f[_0xc720('0x4c')]]);if(!_['isNil'](_0x42649f[_0xc720('0xd7')])){_0x42649f[_0xc720('0xda')]+=moment()[_0xc720('0xc1')](0x0)[_0xc720('0xbf')](_0x42649f[_0xc720('0xd7')],_0xc720('0x9a'));logger[_0xc720('0x75')](_0xc720('0xdb'),_0x181c2f[_0xc720('0x4c')],_0x42649f['mohtime']);delete _0x42649f[_0xc720('0xd7')];}}}}catch(_0x3139b2){logger[_0xc720('0x3d')](_0xc720('0xd9'),_0x181c2f[_0xc720('0x4c')],util['inspect'](_0x3139b2,{'showHidden':![],'depth':null}));}};module[_0xc720('0xdc')]=VoiceQueueReport;
\ No newline at end of file