Built motion from commit (unavailable).|2.4.18
[motion2.git] / server / services / ami / rpc / voiceQueueReport.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 _0x260d=['day','queue','queuecallerjoinAt','queuecallerleaveAt','queuecallercomplete','queuecallercompleteAt','queuecallerexit','queuecallerexitAt','queuecallerabandon','create','CreateVoiceQueueReport','Request','GetVoiceQueueReport','startOf','format','YYYY-MM-DD\x20HH:mm:ss','endOf'];(function(_0x388a98,_0x38c40c){var _0x24352b=function(_0x1a4c7c){while(--_0x1a4c7c){_0x388a98['push'](_0x388a98['shift']());}};_0x24352b(++_0x38c40c);}(_0x260d,0xc4));var _0xd260=function(_0x59b953,_0xb13703){_0x59b953=_0x59b953-0x0;var _0x58cbd0=_0x260d[_0x59b953];return _0x58cbd0;};'use strict';var moment=require('moment');var _=require('lodash');var client=require('../client');exports[_0xd260('0x0')]=function(_0x59338d){return client['Request'](_0xd260('0x1'),{'body':_0x59338d,'log':_0xd260('0x1')});};exports['getVoiceQueueReports']=function(){return function(){return client[_0xd260('0x2')](_0xd260('0x3'),{'options':{'where':{'createdAt':{'$between':[moment()[_0xd260('0x4')]('day')[_0xd260('0x5')](_0xd260('0x6')),moment()[_0xd260('0x7')](_0xd260('0x8'))['format']('YYYY-MM-DD\x20HH:mm:ss')]}},'attributes':['uniqueid',_0xd260('0x9'),_0xd260('0xa'),_0xd260('0xb'),_0xd260('0xc'),_0xd260('0xd'),_0xd260('0xe'),_0xd260('0xf'),_0xd260('0x10'),'queuecallerabandonAt']},'log':'GetVoiceQueueReports'});};};