Built motion from commit (unavailable).|2.5.4
[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 _0x1eba=['minutes','format','YYYY-MM-DD\x20HH:mm:ss','getVoiceQueueHopperHistory','startOf','endOf','day','queue','GetVoiceQueueHopperHistory','ivr','GetCampaignHopperHistory','../client','moment','createHistory','campaign','CreateCmHopperHistory','avgHandleTime','Request','AvgHandleTime','subtract'];(function(_0x29d9d5,_0x5a1bd8){var _0x1be395=function(_0x54e84f){while(--_0x54e84f){_0x29d9d5['push'](_0x29d9d5['shift']());}};_0x1be395(++_0x5a1bd8);}(_0x1eba,0x1d7));var _0xa1eb=function(_0x43941d,_0x45fd0d){_0x43941d=_0x43941d-0x0;var _0x27b82a=_0x1eba[_0x43941d];return _0x27b82a;};'use strict';var client=require(_0xa1eb('0x0'));var moment=require(_0xa1eb('0x1'));exports[_0xa1eb('0x2')]=function(_0x2158d5){return function(){_0x2158d5[_0xa1eb('0x3')]=_0x2158d5['queue'];return client['Request'](_0xa1eb('0x4'),{'body':_0x2158d5,'log':_0xa1eb('0x4')});};};exports[_0xa1eb('0x5')]=function(_0xf9d704){return function(){return client[_0xa1eb('0x6')](_0xa1eb('0x7'),{'options':{'where':{'endtime':{'$between':[moment()[_0xa1eb('0x8')](_0xf9d704,_0xa1eb('0x9'))[_0xa1eb('0xa')](_0xa1eb('0xb')),moment()[_0xa1eb('0xa')](_0xa1eb('0xb'))]}},'raw':![]},'log':'GetCmHopperHistory'});};};exports[_0xa1eb('0xc')]=function(_0x4d4aaf){return function(){return client[_0xa1eb('0x6')]('GetVoiceQueueHopperHistory',{'options':{'where':{'createdAt':{'$between':[moment()[_0xa1eb('0xd')]('day')[_0xa1eb('0xa')]('YYYY-MM-DD\x20HH:mm:ss'),moment()[_0xa1eb('0xe')](_0xa1eb('0xf'))[_0xa1eb('0xa')]('YYYY-MM-DD\x20HH:mm:ss')]},'campaigntype':_0xa1eb('0x10')},'raw':![]},'log':_0xa1eb('0x11')});};};exports['getCampaignHopperHistory']=function(_0x16a623){return function(){return client['Request']('GetCampaignHopperHistory',{'options':{'where':{'createdAt':{'$between':[moment()[_0xa1eb('0xd')]('day')[_0xa1eb('0xa')](_0xa1eb('0xb')),moment()[_0xa1eb('0xe')](_0xa1eb('0xf'))[_0xa1eb('0xa')](_0xa1eb('0xb'))]},'campaigntype':_0xa1eb('0x12')},'raw':![]},'log':_0xa1eb('0x13')});};};