47df92f5879d25dc1eb2b0634651124b69168698
[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 _0x0e66=['GetVoiceQueueReports','moment','lodash','../client','Request','CreateVoiceQueueReport','getVoiceQueueReports','GetVoiceQueueReport','day','format','endOf','YYYY-MM-DD\x20HH:mm:ss','queuecallerjoinAt','queuecallerleaveAt','queuecallercomplete','queuecallercompleteAt','queuecallerexit','queuecallerexitAt','queuecallerabandon','queuecallerabandonAt'];(function(_0x190517,_0x5e2937){var _0x28e76f=function(_0x3c8d4d){while(--_0x3c8d4d){_0x190517['push'](_0x190517['shift']());}};_0x28e76f(++_0x5e2937);}(_0x0e66,0xb5));var _0x60e6=function(_0x531d15,_0x599af5){_0x531d15=_0x531d15-0x0;var _0x271a18=_0x0e66[_0x531d15];return _0x271a18;};'use strict';var moment=require(_0x60e6('0x0'));var _=require(_0x60e6('0x1'));var client=require(_0x60e6('0x2'));exports['create']=function(_0x554552){return client[_0x60e6('0x3')](_0x60e6('0x4'),{'body':_0x554552,'log':_0x60e6('0x4')});};exports[_0x60e6('0x5')]=function(){return function(){return client[_0x60e6('0x3')](_0x60e6('0x6'),{'options':{'where':{'createdAt':{'$between':[moment()['startOf'](_0x60e6('0x7'))[_0x60e6('0x8')]('YYYY-MM-DD\x20HH:mm:ss'),moment()[_0x60e6('0x9')](_0x60e6('0x7'))[_0x60e6('0x8')](_0x60e6('0xa'))]}},'attributes':['uniqueid','queue',_0x60e6('0xb'),_0x60e6('0xc'),_0x60e6('0xd'),_0x60e6('0xe'),_0x60e6('0xf'),_0x60e6('0x10'),_0x60e6('0x11'),_0x60e6('0x12')]},'log':_0x60e6('0x13')});};};