1 // *************************************************************************
3 // * xCALLY Motion - The Omnichannel Contact Center *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved *
6 // *************************************************************************
8 // * Email: info@xcally.com *
9 // * Website: https://www.xcally.com *
11 // *************************************************************************
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. *
17 // *************************************************************************
18 var _0x4c5e=['Request','CreateCmHopperHistory','avgHandleTime','AvgHandleTime','format','YYYY-MM-DD\x20HH:mm:ss','getVoiceQueueHopperHistory','startOf','day','endOf','getCampaignHopperHistory','GetCampaignHopperHistory','ivr','../client','moment','campaign','queue'];(function(_0xa81733,_0x5143a3){var _0x7b90c7=function(_0x7673e7){while(--_0x7673e7){_0xa81733['push'](_0xa81733['shift']());}};_0x7b90c7(++_0x5143a3);}(_0x4c5e,0x73));var _0xe4c5=function(_0x49687f,_0x35ecba){_0x49687f=_0x49687f-0x0;var _0x1842f8=_0x4c5e[_0x49687f];return _0x1842f8;};'use strict';var client=require(_0xe4c5('0x0'));var moment=require(_0xe4c5('0x1'));exports['createHistory']=function(_0x47072a){_0x47072a[_0xe4c5('0x2')]=_0x47072a[_0xe4c5('0x3')];return client[_0xe4c5('0x4')](_0xe4c5('0x5'),{'body':_0x47072a,'log':_0xe4c5('0x5')});};exports[_0xe4c5('0x6')]=function(_0x3b5f0b){return client[_0xe4c5('0x4')](_0xe4c5('0x7'),{'options':{'where':{'endtime':{'$between':[moment()['subtract'](_0x3b5f0b,'minutes')[_0xe4c5('0x8')](_0xe4c5('0x9')),moment()['format'](_0xe4c5('0x9'))]}},'raw':![]},'log':'GetCmHopperHistory'});};exports[_0xe4c5('0xa')]=function(){return function(){return client[_0xe4c5('0x4')]('GetVoiceQueueHopperHistory',{'options':{'where':{'createdAt':{'$between':[moment()[_0xe4c5('0xb')](_0xe4c5('0xc'))['format'](_0xe4c5('0x9')),moment()[_0xe4c5('0xd')](_0xe4c5('0xc'))['format'](_0xe4c5('0x9'))]},'campaigntype':_0xe4c5('0x3')},'raw':![]},'log':'GetVoiceQueueHopperHistory'});};};exports[_0xe4c5('0xe')]=function(){return function(){return client[_0xe4c5('0x4')](_0xe4c5('0xf'),{'options':{'where':{'createdAt':{'$between':[moment()[_0xe4c5('0xb')](_0xe4c5('0xc'))[_0xe4c5('0x8')]('YYYY-MM-DD\x20HH:mm:ss'),moment()[_0xe4c5('0xd')](_0xe4c5('0xc'))[_0xe4c5('0x8')](_0xe4c5('0x9'))]},'campaigntype':_0xe4c5('0x10')},'raw':![]},'log':_0xe4c5('0xf')});};};