Built motion from commit (unavailable).|2.6.0
[motion2.git] / server / api / cmHopperHistory / cmHopperHistory.rpc.js
index ead08f5..b4979c3 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x65e9=['predictiveIntervalAnsweredCalls','`state`\x20=\x2010,\x201,\x20null','predictiveIntervalDroppedCallsTimeout','`state`\x20=\x2011,\x201,\x20null','predictiveIntervalDroppedCallsCallersExit','`state`\x20=\x204,\x20`holdtime`,\x20null','predictiveIntervalAvgTalktime','then','campaign','name','`state`\x20=\x200,\x201,\x20null','outboundNoSuchCallsDay','`state`\x20=\x203,\x201,\x20null','outboundNoAnswerCallsDay','`state`\x20=\x205,\x201,\x20null','outboundBusyCallsDay','`state`\x20=\x208,\x201,\x20null','outboundCongestionCallsDay','`state`\x20=\x2010\x20,\x201,\x20null','`state`\x20=\x2011\x20,\x201,\x20null','outboundDropCallsDayCallersExit','outboundUnknownCallsDay','outboundBlacklistCallsDay','`state`\x20=\x2014,\x201,\x20null','outboundOriginateFailureCallsDay','`state`\x20=\x2018,\x201,\x20null','outboundRejectCallsDay','outboundAnswerAgiCallsDay','GetVoiceQueueHopperHistory','GetCampaignHopperHistory','ivrTotalCallsDays','ivrAnswerCallsDay','lodash','util','moment','bluebird','ioredis','../../config/utils','rpc','../../config/environment','request','info','request\x20sent','debug','CmHopperHistory,\x20%s,\x20%s,\x20%s','error','CmHopperHistory,\x20%s,\x20%s','message','CreateCmHopperHistory','CmHopperHistory','create','body','options','raw','stringify','catch','AvgHandleTime','findAll','where','sequelize','COUNT','col','literal','`state`\x20=\x204,\x201,\x20null'];(function(_0x533f3a,_0x4019f4){var _0x64c095=function(_0x20de6e){while(--_0x20de6e){_0x533f3a['push'](_0x533f3a['shift']());}};_0x64c095(++_0x4019f4);}(_0x65e9,0xa0));var _0x965e=function(_0xa68fd2,_0x56e58b){_0xa68fd2=_0xa68fd2-0x0;var _0x290dbb=_0x65e9[_0xa68fd2];return _0x290dbb;};'use strict';var _=require(_0x965e('0x0'));var util=require(_0x965e('0x1'));var moment=require(_0x965e('0x2'));var BPromise=require(_0x965e('0x3'));var rs=require('randomstring');var fs=require('fs');var Redis=require(_0x965e('0x4'));var db=require('../../mysqldb')['db'];var utils=require(_0x965e('0x5'));var logger=require('../../config/logger')(_0x965e('0x6'));var config=require(_0x965e('0x7'));var jayson=require('jayson/promise');var client=jayson['client']['http']({'port':0x232a});function respondWithRpcPromise(_0x422451,_0x5895ff,_0x353e84){return new BPromise(function(_0x2e3c13,_0x1643c8){return client[_0x965e('0x8')](_0x422451,_0x353e84)['then'](function(_0x159885){logger[_0x965e('0x9')]('CmHopperHistory,\x20%s,\x20%s',_0x5895ff,_0x965e('0xa'));logger[_0x965e('0xb')](_0x965e('0xc'),_0x5895ff,'request\x20sent',JSON['stringify'](_0x159885));if(_0x159885['error']){if(_0x159885[_0x965e('0xd')]['code']===0x1f4){logger[_0x965e('0xd')](_0x965e('0xe'),_0x5895ff,_0x159885[_0x965e('0xd')][_0x965e('0xf')]);return _0x1643c8(_0x159885['error'][_0x965e('0xf')]);}logger['error'](_0x965e('0xe'),_0x5895ff,_0x159885[_0x965e('0xd')][_0x965e('0xf')]);return _0x2e3c13(_0x159885[_0x965e('0xd')][_0x965e('0xf')]);}else{logger[_0x965e('0x9')](_0x965e('0xe'),_0x5895ff,_0x965e('0xa'));_0x2e3c13(_0x159885['result'][_0x965e('0xf')]);}})['catch'](function(_0x2a2083){logger[_0x965e('0xd')](_0x965e('0xe'),_0x5895ff,_0x2a2083);_0x1643c8(_0x2a2083);});});}exports[_0x965e('0x10')]=function(_0x3f3ce5){var _0x589930=this;return new Promise(function(_0x1d38fd,_0x517f19){return db[_0x965e('0x11')][_0x965e('0x12')](_0x3f3ce5[_0x965e('0x13')],{'raw':_0x3f3ce5[_0x965e('0x14')]?_0x3f3ce5[_0x965e('0x14')][_0x965e('0x15')]===undefined?!![]:![]:!![]})['then'](function(_0x2956df){logger[_0x965e('0x9')](_0x965e('0x10'),_0x3f3ce5);logger[_0x965e('0xb')]('CreateCmHopperHistory',_0x3f3ce5,JSON[_0x965e('0x16')](_0x2956df));_0x1d38fd(_0x2956df);})[_0x965e('0x17')](function(_0x47a43e){logger[_0x965e('0xd')](_0x965e('0x10'),_0x47a43e['message'],_0x3f3ce5);_0x517f19(_0x589930[_0x965e('0xd')](0x1f4,_0x47a43e['message']));});});};exports[_0x965e('0x18')]=function(_0x1ebfce){var _0x2c9437=this;return new Promise(function(_0x184bb9,_0x3a73ec){return db[_0x965e('0x11')][_0x965e('0x19')]({'raw':_0x1ebfce[_0x965e('0x14')]?_0x1ebfce['options'][_0x965e('0x15')]===undefined?!![]:![]:!![],'where':_0x1ebfce[_0x965e('0x14')]?_0x1ebfce[_0x965e('0x14')][_0x965e('0x1a')]||null:null,'attributes':[[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')][_0x965e('0x1d')]('id')),'predictiveIntervalTotalCalls'],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')](_0x965e('0x1f')))),_0x965e('0x20')],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')](_0x965e('0x21')))),_0x965e('0x22')],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db['sequelize']['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')](_0x965e('0x23')))),_0x965e('0x24')],[db[_0x965e('0x1b')]['fn']('AVG',db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')](_0x965e('0x25')))),'predictiveIntervalAvgHoldtime'],[db['sequelize']['fn']('AVG',db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')]('`state`\x20=\x204,\x20`talktime`,\x20null'))),_0x965e('0x26')]]})[_0x965e('0x27')](function(_0x2cd58f){logger[_0x965e('0x9')]('AvgHandleTime',_0x1ebfce);logger['debug']('AvgHandleTime',_0x1ebfce,JSON[_0x965e('0x16')](_0x2cd58f));_0x184bb9(_0x2cd58f);})[_0x965e('0x17')](function(_0xc1808f){logger[_0x965e('0xd')](_0x965e('0x18'),_0xc1808f[_0x965e('0xf')],_0x1ebfce);_0x3a73ec(_0x2c9437[_0x965e('0xd')](0x1f4,_0xc1808f[_0x965e('0xf')]));});});};exports['GetVoiceQueueHopperHistory']=function(_0x18f2bb){var _0x585b2e=this;return new Promise(function(_0x42e082,_0x5054b9){return db['CmHopperHistory'][_0x965e('0x19')]({'raw':_0x18f2bb[_0x965e('0x14')]?_0x18f2bb[_0x965e('0x14')][_0x965e('0x15')]===undefined?!![]:![]:!![],'where':_0x18f2bb[_0x965e('0x14')]?_0x18f2bb['options']['where']||null:null,'attributes':[[_0x965e('0x28'),_0x965e('0x29')],[db['sequelize']['fn'](_0x965e('0x1c'),db['sequelize']['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')](_0x965e('0x2a')))),_0x965e('0x2b')],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')](_0x965e('0x2c')))),_0x965e('0x2d')],[db[_0x965e('0x1b')]['fn']('COUNT',db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')](_0x965e('0x1f')))),'outboundAnswerCallsDay'],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db['sequelize']['fn']('IF',db[_0x965e('0x1b')]['literal'](_0x965e('0x2e')))),_0x965e('0x2f')],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')]['literal'](_0x965e('0x30')))),_0x965e('0x31')],[db[_0x965e('0x1b')]['fn']('COUNT',db['sequelize']['fn']('IF',db['sequelize'][_0x965e('0x1e')](_0x965e('0x32')))),'outboundDropCallsDayTimeout'],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')]['literal'](_0x965e('0x33')))),_0x965e('0x34')],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')]['fn']('IF',db['sequelize'][_0x965e('0x1e')]('`state`\x20=\x2012,\x201,\x20null'))),_0x965e('0x35')],[db[_0x965e('0x1b')]['fn']('COUNT',db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')]('`state`\x20=\x2013,\x201,\x20null'))),_0x965e('0x36')],[db[_0x965e('0x1b')]['fn']('COUNT',db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')](_0x965e('0x37')))),_0x965e('0x38')],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db['sequelize']['fn']('IF',db[_0x965e('0x1b')][_0x965e('0x1e')](_0x965e('0x39')))),_0x965e('0x3a')],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')]['fn']('IF',db['sequelize'][_0x965e('0x1e')]('`state`\x20=\x2016,\x201,\x20null'))),_0x965e('0x3b')],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')]['fn']('IF',db['sequelize'][_0x965e('0x1e')]('`state`\x20=\x2020,\x201,\x20null'))),'outboundRejectCallsDay'],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')]['fn']('IF',db[_0x965e('0x1b')]['literal']('`state`\x20=\x2022\x20or\x20`state`\x20=\x2023,\x201,\x20null'))),'outboundReCallsDay']],'group':[_0x965e('0x28')]})['then'](function(_0x4df191){logger[_0x965e('0x9')](_0x965e('0x3c'),_0x18f2bb);logger['debug'](_0x965e('0x3c'),_0x18f2bb,JSON['stringify'](_0x4df191));_0x42e082(_0x4df191);})[_0x965e('0x17')](function(_0xb5a38b){logger[_0x965e('0xd')]('GetVoiceQueueHopperHistory',_0xb5a38b[_0x965e('0xf')],_0x18f2bb);_0x5054b9(_0x585b2e[_0x965e('0xd')](0x1f4,_0xb5a38b[_0x965e('0xf')]));});});};exports[_0x965e('0x3d')]=function(_0x445303){var _0x43346f=this;return new Promise(function(_0xe91cc,_0x18dbfc){return db[_0x965e('0x11')]['findAll']({'raw':_0x445303[_0x965e('0x14')]?_0x445303[_0x965e('0x14')][_0x965e('0x15')]===undefined?!![]:![]:!![],'where':_0x445303['options']?_0x445303[_0x965e('0x14')][_0x965e('0x1a')]||null:null,'attributes':[[_0x965e('0x28'),_0x965e('0x29')],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db[_0x965e('0x1b')]['col']('id')),_0x965e('0x3e')],[db[_0x965e('0x1b')]['fn'](_0x965e('0x1c'),db['sequelize']['fn']('IF',db['sequelize']['literal'](_0x965e('0x1f')))),_0x965e('0x3f')]],'group':['campaign']})[_0x965e('0x27')](function(_0x56e452){logger[_0x965e('0x9')](_0x965e('0x3d'),_0x445303);logger[_0x965e('0xb')](_0x965e('0x3d'),_0x445303,JSON['stringify'](_0x56e452));_0xe91cc(_0x56e452);})[_0x965e('0x17')](function(_0x37ca66){logger[_0x965e('0xd')](_0x965e('0x3d'),_0x37ca66['message'],_0x445303);_0x18dbfc(_0x43346f[_0x965e('0xd')](0x1f4,_0x37ca66[_0x965e('0xf')]));});});};
\ No newline at end of file
+var _0x4d02=['`state`\x20=\x2012,\x201,\x20null','outboundBlacklistCallsDay','outboundOriginateFailureCallsDay','`state`\x20=\x2018,\x201,\x20null','`state`\x20=\x2016,\x201,\x20null','outboundRejectCallsDay','`state`\x20=\x2022\x20or\x20`state`\x20=\x2023,\x201,\x20null','outboundReCallsDay','GetCampaignHopperHistory','col','ivrAnswerCallsDay','lodash','bluebird','ioredis','../../mysqldb','../../config/utils','../../config/logger','http','request','then','info','CmHopperHistory,\x20%s,\x20%s','debug','CmHopperHistory,\x20%s,\x20%s,\x20%s','request\x20sent','stringify','error','code','message','catch','CreateCmHopperHistory','create','options','raw','CmHopperHistory','findAll','where','sequelize','predictiveIntervalTotalCalls','COUNT','literal','`state`\x20=\x204,\x201,\x20null','predictiveIntervalAnsweredCalls','predictiveIntervalDroppedCallsTimeout','`state`\x20=\x2011,\x201,\x20null','predictiveIntervalDroppedCallsCallersExit','AVG','`state`\x20=\x204,\x20`holdtime`,\x20null','predictiveIntervalAvgHoldtime','AvgHandleTime','GetVoiceQueueHopperHistory','campaign','name','`state`\x20=\x200,\x201,\x20null','outboundNoSuchCallsDay','`state`\x20=\x203,\x201,\x20null','outboundNoAnswerCallsDay','outboundAnswerCallsDay','`state`\x20=\x205,\x201,\x20null','`state`\x20=\x208,\x201,\x20null','`state`\x20=\x2011\x20,\x201,\x20null'];(function(_0x25fd7f,_0x1fc310){var _0x558eac=function(_0x47c161){while(--_0x47c161){_0x25fd7f['push'](_0x25fd7f['shift']());}};_0x558eac(++_0x1fc310);}(_0x4d02,0xff));var _0x24d0=function(_0x2e316a,_0x36559f){_0x2e316a=_0x2e316a-0x0;var _0x5c9790=_0x4d02[_0x2e316a];return _0x5c9790;};'use strict';var _=require(_0x24d0('0x0'));var util=require('util');var moment=require('moment');var BPromise=require(_0x24d0('0x1'));var rs=require('randomstring');var fs=require('fs');var Redis=require(_0x24d0('0x2'));var db=require(_0x24d0('0x3'))['db'];var utils=require(_0x24d0('0x4'));var logger=require(_0x24d0('0x5'))('rpc');var config=require('../../config/environment');var jayson=require('jayson/promise');var client=jayson['client'][_0x24d0('0x6')]({'port':0x232a});function respondWithRpcPromise(_0x4851a0,_0x34cfd2,_0x2cf9e9){return new BPromise(function(_0x4247a5,_0x4ae8a5){return client[_0x24d0('0x7')](_0x4851a0,_0x2cf9e9)[_0x24d0('0x8')](function(_0x25cf37){logger[_0x24d0('0x9')](_0x24d0('0xa'),_0x34cfd2,'request\x20sent');logger[_0x24d0('0xb')](_0x24d0('0xc'),_0x34cfd2,_0x24d0('0xd'),JSON[_0x24d0('0xe')](_0x25cf37));if(_0x25cf37[_0x24d0('0xf')]){if(_0x25cf37[_0x24d0('0xf')][_0x24d0('0x10')]===0x1f4){logger[_0x24d0('0xf')](_0x24d0('0xa'),_0x34cfd2,_0x25cf37[_0x24d0('0xf')][_0x24d0('0x11')]);return _0x4ae8a5(_0x25cf37[_0x24d0('0xf')]['message']);}logger['error'](_0x24d0('0xa'),_0x34cfd2,_0x25cf37[_0x24d0('0xf')]['message']);return _0x4247a5(_0x25cf37['error'][_0x24d0('0x11')]);}else{logger['info'](_0x24d0('0xa'),_0x34cfd2,_0x24d0('0xd'));_0x4247a5(_0x25cf37['result'][_0x24d0('0x11')]);}})[_0x24d0('0x12')](function(_0x316e38){logger[_0x24d0('0xf')](_0x24d0('0xa'),_0x34cfd2,_0x316e38);_0x4ae8a5(_0x316e38);});});}exports[_0x24d0('0x13')]=function(_0x585154){var _0x39ae63=this;return new Promise(function(_0x27cc59,_0x2ada22){return db['CmHopperHistory'][_0x24d0('0x14')](_0x585154['body'],{'raw':_0x585154[_0x24d0('0x15')]?_0x585154[_0x24d0('0x15')][_0x24d0('0x16')]===undefined?!![]:![]:!![]})[_0x24d0('0x8')](function(_0x423ac1){logger[_0x24d0('0x9')](_0x24d0('0x13'),_0x585154);logger[_0x24d0('0xb')]('CreateCmHopperHistory',_0x585154,JSON['stringify'](_0x423ac1));_0x27cc59(_0x423ac1);})[_0x24d0('0x12')](function(_0x517774){logger[_0x24d0('0xf')](_0x24d0('0x13'),_0x517774['message'],_0x585154);_0x2ada22(_0x39ae63[_0x24d0('0xf')](0x1f4,_0x517774['message']));});});};exports['AvgHandleTime']=function(_0x14eda2){var _0x12ee7d=this;return new Promise(function(_0x261980,_0x5e0b81){return db[_0x24d0('0x17')][_0x24d0('0x18')]({'raw':_0x14eda2['options']?_0x14eda2[_0x24d0('0x15')]['raw']===undefined?!![]:![]:!![],'where':_0x14eda2[_0x24d0('0x15')]?_0x14eda2[_0x24d0('0x15')][_0x24d0('0x19')]||null:null,'attributes':[[db[_0x24d0('0x1a')]['fn']('COUNT',db[_0x24d0('0x1a')]['col']('id')),_0x24d0('0x1b')],[db['sequelize']['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db['sequelize'][_0x24d0('0x1d')](_0x24d0('0x1e')))),_0x24d0('0x1f')],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db['sequelize']['literal']('`state`\x20=\x2010,\x201,\x20null'))),_0x24d0('0x20')],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db[_0x24d0('0x1a')][_0x24d0('0x1d')](_0x24d0('0x21')))),_0x24d0('0x22')],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x23'),db[_0x24d0('0x1a')]['fn']('IF',db['sequelize'][_0x24d0('0x1d')](_0x24d0('0x24')))),_0x24d0('0x25')],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x23'),db[_0x24d0('0x1a')]['fn']('IF',db['sequelize'][_0x24d0('0x1d')]('`state`\x20=\x204,\x20`talktime`,\x20null'))),'predictiveIntervalAvgTalktime']]})[_0x24d0('0x8')](function(_0x3061b9){logger[_0x24d0('0x9')](_0x24d0('0x26'),_0x14eda2);logger[_0x24d0('0xb')](_0x24d0('0x26'),_0x14eda2,JSON[_0x24d0('0xe')](_0x3061b9));_0x261980(_0x3061b9);})['catch'](function(_0x35ca11){logger[_0x24d0('0xf')](_0x24d0('0x26'),_0x35ca11[_0x24d0('0x11')],_0x14eda2);_0x5e0b81(_0x12ee7d['error'](0x1f4,_0x35ca11['message']));});});};exports[_0x24d0('0x27')]=function(_0x34531b){var _0x12fdfa=this;return new Promise(function(_0x325f28,_0x445d8b){return db[_0x24d0('0x17')][_0x24d0('0x18')]({'raw':_0x34531b[_0x24d0('0x15')]?_0x34531b['options'][_0x24d0('0x16')]===undefined?!![]:![]:!![],'where':_0x34531b[_0x24d0('0x15')]?_0x34531b[_0x24d0('0x15')][_0x24d0('0x19')]||null:null,'attributes':[[_0x24d0('0x28'),_0x24d0('0x29')],[db[_0x24d0('0x1a')]['fn']('COUNT',db[_0x24d0('0x1a')]['fn']('IF',db[_0x24d0('0x1a')][_0x24d0('0x1d')](_0x24d0('0x2a')))),_0x24d0('0x2b')],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db[_0x24d0('0x1a')][_0x24d0('0x1d')](_0x24d0('0x2c')))),_0x24d0('0x2d')],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db[_0x24d0('0x1a')][_0x24d0('0x1d')](_0x24d0('0x1e')))),_0x24d0('0x2e')],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db['sequelize'][_0x24d0('0x1d')](_0x24d0('0x2f')))),'outboundBusyCallsDay'],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db[_0x24d0('0x1a')][_0x24d0('0x1d')](_0x24d0('0x30')))),'outboundCongestionCallsDay'],[db['sequelize']['fn']('COUNT',db['sequelize']['fn']('IF',db[_0x24d0('0x1a')][_0x24d0('0x1d')]('`state`\x20=\x2010\x20,\x201,\x20null'))),'outboundDropCallsDayTimeout'],[db['sequelize']['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db[_0x24d0('0x1a')][_0x24d0('0x1d')](_0x24d0('0x31')))),'outboundDropCallsDayCallersExit'],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db['sequelize'][_0x24d0('0x1d')](_0x24d0('0x32')))),'outboundUnknownCallsDay'],[db['sequelize']['fn']('COUNT',db[_0x24d0('0x1a')]['fn']('IF',db[_0x24d0('0x1a')]['literal']('`state`\x20=\x2013,\x201,\x20null'))),_0x24d0('0x33')],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db[_0x24d0('0x1a')][_0x24d0('0x1d')]('`state`\x20=\x2014,\x201,\x20null'))),_0x24d0('0x34')],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db['sequelize'][_0x24d0('0x1d')](_0x24d0('0x35')))),'outboundRejectCallsDay'],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db['sequelize'][_0x24d0('0x1d')](_0x24d0('0x36')))),'outboundAnswerAgiCallsDay'],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db['sequelize']['fn']('IF',db[_0x24d0('0x1a')]['literal']('`state`\x20=\x2020,\x201,\x20null'))),_0x24d0('0x37')],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db[_0x24d0('0x1a')][_0x24d0('0x1d')](_0x24d0('0x38')))),_0x24d0('0x39')]],'group':[_0x24d0('0x28')]})[_0x24d0('0x8')](function(_0x6886cc){logger[_0x24d0('0x9')]('GetVoiceQueueHopperHistory',_0x34531b);logger[_0x24d0('0xb')]('GetVoiceQueueHopperHistory',_0x34531b,JSON[_0x24d0('0xe')](_0x6886cc));_0x325f28(_0x6886cc);})[_0x24d0('0x12')](function(_0x2491c4){logger[_0x24d0('0xf')](_0x24d0('0x27'),_0x2491c4[_0x24d0('0x11')],_0x34531b);_0x445d8b(_0x12fdfa[_0x24d0('0xf')](0x1f4,_0x2491c4[_0x24d0('0x11')]));});});};exports[_0x24d0('0x3a')]=function(_0x738a3e){var _0x1896af=this;return new Promise(function(_0x4de976,_0x102129){return db[_0x24d0('0x17')][_0x24d0('0x18')]({'raw':_0x738a3e[_0x24d0('0x15')]?_0x738a3e[_0x24d0('0x15')][_0x24d0('0x16')]===undefined?!![]:![]:!![],'where':_0x738a3e['options']?_0x738a3e[_0x24d0('0x15')]['where']||null:null,'attributes':[['campaign',_0x24d0('0x29')],[db['sequelize']['fn']('COUNT',db['sequelize'][_0x24d0('0x3b')]('id')),'ivrTotalCallsDays'],[db[_0x24d0('0x1a')]['fn'](_0x24d0('0x1c'),db[_0x24d0('0x1a')]['fn']('IF',db[_0x24d0('0x1a')][_0x24d0('0x1d')](_0x24d0('0x1e')))),_0x24d0('0x3c')]],'group':['campaign']})[_0x24d0('0x8')](function(_0x5a7934){logger[_0x24d0('0x9')](_0x24d0('0x3a'),_0x738a3e);logger[_0x24d0('0xb')]('GetCampaignHopperHistory',_0x738a3e,JSON['stringify'](_0x5a7934));_0x4de976(_0x5a7934);})[_0x24d0('0x12')](function(_0xd64df9){logger[_0x24d0('0xf')](_0x24d0('0x3a'),_0xd64df9['message'],_0x738a3e);_0x102129(_0x1896af[_0x24d0('0xf')](0x1f4,_0xd64df9[_0x24d0('0x11')]));});});};
\ No newline at end of file