d50412705f125ea4eb488e7bf497f53acd8053a5
[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 _0x1646=['day','format','endOf','uniqueid','queuecallerjoinAt','queuecallerleaveAt','queuecallerexit','queuecallerabandon','GetVoiceQueueReports','lodash','create','Request','CreateVoiceQueueReport','GetVoiceQueueReport','startOf'];(function(_0x16792b,_0x11de9b){var _0x47e251=function(_0x4db7c7){while(--_0x4db7c7){_0x16792b['push'](_0x16792b['shift']());}};_0x47e251(++_0x11de9b);}(_0x1646,0x117));var _0x6164=function(_0x328b1c,_0xec0b4f){_0x328b1c=_0x328b1c-0x0;var _0x4dbeaa=_0x1646[_0x328b1c];return _0x4dbeaa;};'use strict';var moment=require('moment');var _=require(_0x6164('0x0'));var client=require('../client');exports[_0x6164('0x1')]=function(_0x2685f5){return client[_0x6164('0x2')](_0x6164('0x3'),{'body':_0x2685f5,'log':_0x6164('0x3')});};exports['getVoiceQueueReports']=function(){return function(){return client['Request'](_0x6164('0x4'),{'options':{'where':{'createdAt':{'$between':[moment()[_0x6164('0x5')](_0x6164('0x6'))[_0x6164('0x7')]('YYYY-MM-DD\x20HH:mm:ss'),moment()[_0x6164('0x8')]('day')[_0x6164('0x7')]('YYYY-MM-DD\x20HH:mm:ss')]}},'attributes':[_0x6164('0x9'),'queue',_0x6164('0xa'),_0x6164('0xb'),'queuecallercomplete','queuecallercompleteAt',_0x6164('0xc'),'queuecallerexitAt',_0x6164('0xd'),'queuecallerabandonAt']},'log':_0x6164('0xe')});};};