Built motion from commit cb845558.|2.6.34
[motion2.git] / server / services / ami / rpc / cmHopperHistory.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 _0xd04b=['startOf','day','endOf','getCampaignHopperHistory','ivr','../client','moment','createHistory','campaign','Request','CreateCmHopperHistory','avgHandleTime','AvgHandleTime','subtract','minutes','format','YYYY-MM-DD\x20HH:mm:ss','GetCmHopperHistory','getVoiceQueueHopperHistory','GetVoiceQueueHopperHistory'];(function(_0x1f9c65,_0x5111f4){var _0x28899d=function(_0x185f87){while(--_0x185f87){_0x1f9c65['push'](_0x1f9c65['shift']());}};_0x28899d(++_0x5111f4);}(_0xd04b,0x145));var _0xbd04=function(_0x4da112,_0xa33442){_0x4da112=_0x4da112-0x0;var _0xc6337d=_0xd04b[_0x4da112];return _0xc6337d;};'use strict';var client=require(_0xbd04('0x0'));var moment=require(_0xbd04('0x1'));exports[_0xbd04('0x2')]=function(_0x5186f0){_0x5186f0[_0xbd04('0x3')]=_0x5186f0['queue'];return client[_0xbd04('0x4')](_0xbd04('0x5'),{'body':_0x5186f0,'log':_0xbd04('0x5')});};exports[_0xbd04('0x6')]=function(_0x36218a){return client[_0xbd04('0x4')](_0xbd04('0x7'),{'options':{'where':{'endtime':{'$between':[moment()[_0xbd04('0x8')](_0x36218a,_0xbd04('0x9'))[_0xbd04('0xa')](_0xbd04('0xb')),moment()['format'](_0xbd04('0xb'))]}},'raw':![]},'log':_0xbd04('0xc')});};exports[_0xbd04('0xd')]=function(){return function(){return client[_0xbd04('0x4')](_0xbd04('0xe'),{'options':{'where':{'createdAt':{'$between':[moment()[_0xbd04('0xf')](_0xbd04('0x10'))[_0xbd04('0xa')]('YYYY-MM-DD\x20HH:mm:ss'),moment()[_0xbd04('0x11')](_0xbd04('0x10'))[_0xbd04('0xa')](_0xbd04('0xb'))]},'campaigntype':'queue'},'raw':![]},'log':_0xbd04('0xe')});};};exports[_0xbd04('0x12')]=function(){return function(){return client[_0xbd04('0x4')]('GetCampaignHopperHistory',{'options':{'where':{'createdAt':{'$between':[moment()['startOf']('day')['format'](_0xbd04('0xb')),moment()[_0xbd04('0x11')](_0xbd04('0x10'))['format']('YYYY-MM-DD\x20HH:mm:ss')]},'campaigntype':_0xbd04('0x13')},'raw':![]},'log':'GetCampaignHopperHistory'});};};