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 _0x1394=['merge','calleridnum','context','callerid','DOCUMENTATION','getVoiceCallReports','GetVoiceCallReport','outbound','startOf','day','format','YYYY-MM-DD\x20HH:mm:ss','disposition','duration','billableseconds','GetVoiceCallReports','moment','util','../client','create','Request','CreateVoiceCallReport'];(function(_0xb7ce31,_0x13168d){var _0x3101c4=function(_0x4a8427){while(--_0x4a8427){_0xb7ce31['push'](_0xb7ce31['shift']());}};_0x3101c4(++_0x13168d);}(_0x1394,0x170));var _0x4139=function(_0x5d6704,_0x599319){_0x5d6704=_0x5d6704-0x0;var _0x416fd9=_0x1394[_0x5d6704];return _0x416fd9;};'use strict';var moment=require(_0x4139('0x0'));var util=require(_0x4139('0x1'));var _=require('lodash');var client=require(_0x4139('0x2'));exports[_0x4139('0x3')]=function(_0x1945df){return client[_0x4139('0x4')](_0x4139('0x5'),{'body':_[_0x4139('0x6')](_0x1945df,{'source':_0x1945df[_0x4139('0x7')],'destinationcontext':_0x1945df[_0x4139('0x8')],'callerid':_0x1945df[_0x4139('0x9')],'amaflags':_0x4139('0xa')}),'log':_0x4139('0x5')});};exports[_0x4139('0xb')]=function(){return function(){return client[_0x4139('0x4')](_0x4139('0xc'),{'options':{'where':{'type':[_0x4139('0xd')],'createdAt':{'$between':[moment()[_0x4139('0xe')](_0x4139('0xf'))[_0x4139('0x10')](_0x4139('0x11')),moment()['endOf'](_0x4139('0xf'))[_0x4139('0x10')](_0x4139('0x11'))]}},'attributes':['type',_0x4139('0x12'),_0x4139('0x13'),_0x4139('0x14')]},'log':_0x4139('0x15')});};};