Built motion from commit dc14b02d.|2.6.27
[motion2.git] / server / services / ami / rpc / cmHopper.js
index 0596e0c..612d277 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xa786=['rescheduleContact','Request','ContactId','VoiceQueueId','CampaignId','DestroyCmHopper','getContactDialer','priority','DESC','scheduledat','ASC','getContactDialerIvr','moveContactManagedDialer','campaign','MoveContactManagedDialer','CountReScheduled','countReScheduled','getContactPreview','GetCmHopperPreview','User','Agent','VoiceQueue','name','getContactRecallMe','GetContactRecallMe','voicePause','db.CmHopper.UserId','resetActiveCalls','ResetActiveCalls','CmHopperHandlePreviewRecallNotifications','handlePreviewRecallNotifications','../client','moment','getContacts','CmContact','Contact','getCmHopper','updateContacts','UpdateCmHopper','format','YYYY-MM-DD\x20HH:mm:ss'];(function(_0x3dd15e,_0x1f0015){var _0x231fd0=function(_0x4f680a){while(--_0x4f680a){_0x3dd15e['push'](_0x3dd15e['shift']());}};_0x231fd0(++_0x1f0015);}(_0xa786,0x71));var _0x6a78=function(_0x2d70fe,_0x42d205){_0x2d70fe=_0x2d70fe-0x0;var _0x5c0c7a=_0xa786[_0x2d70fe];return _0x5c0c7a;};'use strict';var client=require(_0x6a78('0x0'));var moment=require(_0x6a78('0x1'));exports[_0x6a78('0x2')]=function(_0x4a3fd4,_0x30bd42){return function(){return client['Request']('GetCmHopper',{'options':{'where':{'VoiceQueueId':_0x4a3fd4},'include':[{'model':_0x6a78('0x3'),'as':_0x6a78('0x4')}],'limit':_0x30bd42,'raw':![]},'log':_0x6a78('0x5')});};};exports[_0x6a78('0x6')]=function(_0x41bb73,_0x112e35,_0x386861){return function(){return client['Request'](_0x6a78('0x7'),{'body':_0x41bb73,'options':{'where':{'VoiceQueueId':_0x112e35,'scheduledat':{'$lte':moment()[_0x6a78('0x8')](_0x6a78('0x9'))}},'limit':_0x386861},'log':_0x6a78('0x7')});};};exports[_0x6a78('0xa')]=function(_0x217b2c){return client[_0x6a78('0xb')](_0x6a78('0x7'),{'body':_0x217b2c,'options':{'where':{'ContactId':_0x217b2c[_0x6a78('0xc')],'ListId':_0x217b2c['ListId'],'VoiceQueueId':_0x217b2c[_0x6a78('0xd')],'CampaignId':_0x217b2c[_0x6a78('0xe')]}},'log':_0x6a78('0xa')});};exports['destroyContact']=function(_0x2a433a,_0x439ef1,_0x328130){return function(){return client[_0x6a78('0xb')](_0x6a78('0xf'),{'options':{'where':{'VoiceQueueId':_0x2a433a,'ListId':_0x439ef1,'ContactId':_0x328130}},'log':'DestroyCmHopper'});};};exports[_0x6a78('0x10')]=function(_0xb88919,_0x1324c1,_0x4dce44,_0x44c863){return client[_0x6a78('0xb')]('GetContactDialer',{'body':{'active':!![]},'options':{'where':{'VoiceQueueId':_0xb88919,'active':![],'scheduledat':{'$lte':moment()[_0x6a78('0x8')](_0x6a78('0x9'))},'$or':[{'UserId':null},{'UserId':{'$in':_0x1324c1}}]},'order':[[_0x6a78('0x11'),_0x6a78('0x12')],[_0x6a78('0x13'),_0x44c863],['id',_0x6a78('0x14')]],'raw':!![],'limit':_0x4dce44},'log':'GetContactDialer'});};exports[_0x6a78('0x15')]=function(_0x122362,_0x4746c0,_0x265f90){return client['Request']('GetContactDialer',{'body':{'active':!![]},'options':{'where':{'CampaignId':_0x122362,'active':![],'scheduledat':{'$lte':moment()[_0x6a78('0x8')]('YYYY-MM-DD\x20HH:mm:ss')}},'include':[{'model':'CmContact','as':'Contact'}],'order':[[_0x6a78('0x11'),_0x6a78('0x12')],[_0x6a78('0x13'),_0x265f90],['id','ASC']],'raw':!![],'limit':_0x4746c0},'log':'GetContactDialerIvr'});};exports[_0x6a78('0x16')]=function(_0x29dec5,_0x356b93){_0x29dec5[_0x6a78('0x17')]=_0x29dec5['queue'];return client['Request']('MoveContactManagedDialer',{'body':_0x29dec5,'options':{'where':{'ContactId':_0x29dec5[_0x6a78('0xc')],'ListId':_0x29dec5['ListId'],'VoiceQueueId':_0x29dec5[_0x6a78('0xd')],'CampaignId':_0x29dec5[_0x6a78('0xe')],'active':_0x356b93?undefined:!![]}},'log':_0x6a78('0x18')});};exports['countReScheduled']=function(_0x49f711){return client[_0x6a78('0xb')](_0x6a78('0x19'),{'options':{'where':{'VoiceQueueId':_0x49f711['id']?_0x49f711['id']||null:null}},'log':_0x6a78('0x1a')});};exports[_0x6a78('0x1b')]=function(_0xb86669){return function(){return client[_0x6a78('0xb')](_0x6a78('0x1c'),{'options':{'where':{'id':_0xb86669},'include':[{'model':'CmContact','as':_0x6a78('0x4')},{'model':_0x6a78('0x1d'),'as':_0x6a78('0x1e'),'attributes':['id','name']},{'model':_0x6a78('0x1f'),'as':'Queue','attributes':['id',_0x6a78('0x20')]}],'raw':!![]},'log':_0x6a78('0x5')});};};exports['unlockContact']=function(_0x1154d2,_0x159b96,_0xfdd266){return client[_0x6a78('0xb')]('UpdateCmHopper',{'body':_0x1154d2,'options':{'where':{'id':_0x159b96},'limit':_0xfdd266},'log':_0x6a78('0x7')});};exports[_0x6a78('0x21')]=function(_0x273a73,_0x12e0c5){return function(){return client['Request'](_0x6a78('0x22'),{'body':{'active':!![]},'options':{'where':{'VoiceQueueId':_0x273a73,'active':![],'recallme':!![],'scheduledat':{'$lte':moment()[_0x6a78('0x8')](_0x6a78('0x9'))},'UserId':{'$in':_0x12e0c5}},'order':[['priority',_0x6a78('0x12')],[_0x6a78('0x13'),'DESC'],['id',_0x6a78('0x14')]],'include':[{'model':_0x6a78('0x3'),'as':_0x6a78('0x4')},{'model':_0x6a78('0x1d'),'as':_0x6a78('0x1e'),'attributes':['id','name',_0x6a78('0x23')]}],'group':_0x6a78('0x24'),'raw':!![]},'log':'GetContactDialer'});};};exports[_0x6a78('0x25')]=function(_0x25cdf6,_0x19f317){return client[_0x6a78('0xb')](_0x6a78('0x26'),{'body':_0x25cdf6,'options':_0x19f317||{},'log':_0x6a78('0x26')});};exports['handlePreviewRecallNotifications']=function(_0x307661,_0x494a14,_0x23d91f){return function(){return client[_0x6a78('0xb')](_0x6a78('0x27'),{'body':{'where':{'voiceQueueIds':_0x307661,'interval':_0x494a14,'availableAgentsIds':_0x23d91f}},'log':_0x6a78('0x28')});};};
\ No newline at end of file
+var _0x2e88=['DESC','scheduledat','ASC','GetContactDialerIvr','moveContactManagedDialer','campaign','MoveContactManagedDialer','ListId','getContactPreview','GetCmHopperPreview','User','Agent','name','VoiceQueue','Queue','unlockContact','getContactRecallMe','GetContactRecallMe','voicePause','resetActiveCalls','ResetActiveCalls','handlePreviewRecallNotifications','CmHopperHandlePreviewRecallNotifications','../client','moment','getContacts','Request','CmContact','Contact','updateContacts','UpdateCmHopper','format','YYYY-MM-DD\x20HH:mm:ss','rescheduleContact','ContactId','VoiceQueueId','CampaignId','destroyContact','DestroyCmHopper','getContactDialer','GetContactDialer','priority'];(function(_0x465e32,_0x5bd6b8){var _0x4a0e48=function(_0x4710b9){while(--_0x4710b9){_0x465e32['push'](_0x465e32['shift']());}};_0x4a0e48(++_0x5bd6b8);}(_0x2e88,0x95));var _0x82e8=function(_0x4c4037,_0x15054b){_0x4c4037=_0x4c4037-0x0;var _0x357862=_0x2e88[_0x4c4037];return _0x357862;};'use strict';var client=require(_0x82e8('0x0'));var moment=require(_0x82e8('0x1'));exports[_0x82e8('0x2')]=function(_0x2ef18d,_0x9dd860){return function(){return client[_0x82e8('0x3')]('GetCmHopper',{'options':{'where':{'VoiceQueueId':_0x2ef18d},'include':[{'model':_0x82e8('0x4'),'as':_0x82e8('0x5')}],'limit':_0x9dd860,'raw':![]},'log':'getCmHopper'});};};exports[_0x82e8('0x6')]=function(_0x63aedb,_0x4e909a,_0x3162d1){return function(){return client[_0x82e8('0x3')](_0x82e8('0x7'),{'body':_0x63aedb,'options':{'where':{'VoiceQueueId':_0x4e909a,'scheduledat':{'$lte':moment()[_0x82e8('0x8')](_0x82e8('0x9'))}},'limit':_0x3162d1},'log':_0x82e8('0x7')});};};exports[_0x82e8('0xa')]=function(_0x23d5ef){return client[_0x82e8('0x3')](_0x82e8('0x7'),{'body':_0x23d5ef,'options':{'where':{'ContactId':_0x23d5ef[_0x82e8('0xb')],'ListId':_0x23d5ef['ListId'],'VoiceQueueId':_0x23d5ef[_0x82e8('0xc')],'CampaignId':_0x23d5ef[_0x82e8('0xd')]}},'log':_0x82e8('0xa')});};exports[_0x82e8('0xe')]=function(_0x474125,_0x256938,_0x359489){return function(){return client['Request'](_0x82e8('0xf'),{'options':{'where':{'VoiceQueueId':_0x474125,'ListId':_0x256938,'ContactId':_0x359489}},'log':_0x82e8('0xf')});};};exports[_0x82e8('0x10')]=function(_0x2cfe6b,_0x192914,_0x5eb2ca,_0x3353e0){return client[_0x82e8('0x3')](_0x82e8('0x11'),{'body':{'active':!![]},'options':{'where':{'VoiceQueueId':_0x2cfe6b,'active':![],'scheduledat':{'$lte':moment()[_0x82e8('0x8')]('YYYY-MM-DD\x20HH:mm:ss')},'$or':[{'UserId':null},{'UserId':{'$in':_0x192914}}]},'order':[[_0x82e8('0x12'),_0x82e8('0x13')],[_0x82e8('0x14'),_0x3353e0],['id',_0x82e8('0x15')]],'raw':!![],'limit':_0x5eb2ca},'log':_0x82e8('0x11')});};exports['getContactDialerIvr']=function(_0x39e7bc,_0x64e4fa,_0x574ba2){return client[_0x82e8('0x3')](_0x82e8('0x11'),{'body':{'active':!![]},'options':{'where':{'CampaignId':_0x39e7bc,'active':![],'scheduledat':{'$lte':moment()[_0x82e8('0x8')](_0x82e8('0x9'))}},'include':[{'model':_0x82e8('0x4'),'as':_0x82e8('0x5')}],'order':[[_0x82e8('0x12'),'DESC'],[_0x82e8('0x14'),_0x574ba2],['id',_0x82e8('0x15')]],'raw':!![],'limit':_0x64e4fa},'log':_0x82e8('0x16')});};exports[_0x82e8('0x17')]=function(_0xbfecf2,_0x5db337){_0xbfecf2[_0x82e8('0x18')]=_0xbfecf2['queue'];return client[_0x82e8('0x3')](_0x82e8('0x19'),{'body':_0xbfecf2,'options':{'where':{'ContactId':_0xbfecf2[_0x82e8('0xb')],'ListId':_0xbfecf2[_0x82e8('0x1a')],'VoiceQueueId':_0xbfecf2[_0x82e8('0xc')],'CampaignId':_0xbfecf2[_0x82e8('0xd')],'active':_0x5db337?undefined:!![]}},'log':_0x82e8('0x19')});};exports['countReScheduled']=function(_0x2b82eb){return client['Request']('CountReScheduled',{'options':{'where':{'VoiceQueueId':_0x2b82eb['id']?_0x2b82eb['id']||null:null}},'log':'countReScheduled'});};exports[_0x82e8('0x1b')]=function(_0x53e28f){return function(){return client[_0x82e8('0x3')](_0x82e8('0x1c'),{'options':{'where':{'id':_0x53e28f},'include':[{'model':_0x82e8('0x4'),'as':'Contact'},{'model':_0x82e8('0x1d'),'as':_0x82e8('0x1e'),'attributes':['id',_0x82e8('0x1f')]},{'model':_0x82e8('0x20'),'as':_0x82e8('0x21'),'attributes':['id','name']}],'raw':!![]},'log':'getCmHopper'});};};exports[_0x82e8('0x22')]=function(_0xe5ea6f,_0x3eb8ec,_0x3c050e){return client[_0x82e8('0x3')](_0x82e8('0x7'),{'body':_0xe5ea6f,'options':{'where':{'id':_0x3eb8ec},'limit':_0x3c050e},'log':_0x82e8('0x7')});};exports[_0x82e8('0x23')]=function(_0x1c2173,_0xf52391){return function(){return client[_0x82e8('0x3')](_0x82e8('0x24'),{'body':{'active':!![]},'options':{'where':{'VoiceQueueId':_0x1c2173,'active':![],'recallme':!![],'scheduledat':{'$lte':moment()[_0x82e8('0x8')]('YYYY-MM-DD\x20HH:mm:ss')},'UserId':{'$in':_0xf52391}},'order':[[_0x82e8('0x12'),_0x82e8('0x13')],[_0x82e8('0x14'),_0x82e8('0x13')],['id',_0x82e8('0x15')]],'include':[{'model':_0x82e8('0x4'),'as':_0x82e8('0x5')},{'model':_0x82e8('0x1d'),'as':_0x82e8('0x1e'),'attributes':['id',_0x82e8('0x1f'),_0x82e8('0x25')]}],'group':'db.CmHopper.UserId','raw':!![]},'log':_0x82e8('0x11')});};};exports[_0x82e8('0x26')]=function(_0x19ed65,_0x3453ba){return client[_0x82e8('0x3')](_0x82e8('0x27'),{'body':_0x19ed65,'options':_0x3453ba||{},'log':_0x82e8('0x27')});};exports[_0x82e8('0x28')]=function(_0x4a0832,_0x42bcac,_0x4aa077){return function(){return client[_0x82e8('0x3')](_0x82e8('0x29'),{'body':{'where':{'voiceQueueIds':_0x4a0832,'interval':_0x42bcac,'availableAgentsIds':_0x4aa077}},'log':'handlePreviewRecallNotifications'});};};
\ No newline at end of file