Built motion from commit bab6f49e.|2.6.17
[motion2.git] / server / api / cmHopperHistory / cmHopperHistory.rpc.js
index ab90a0e..ab5feb8 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xcd56=['body','options','raw','stringify','CreateCmHopperHistory','AvgHandleTime','findAll','sequelize','COUNT','col','literal','`state`\x20=\x204,\x201,\x20null','predictiveIntervalAnsweredCalls','`state`\x20=\x2010,\x201,\x20null','predictiveIntervalDroppedCallsTimeout','predictiveIntervalDroppedCallsCallersExit','AVG','`state`\x20=\x204,\x20`holdtime`,\x20null','predictiveIntervalAvgHoldtime','`state`\x20=\x204,\x20`talktime`,\x20null','GetVoiceQueueHopperHistory','name','`state`\x20=\x200,\x201,\x20null','`state`\x20=\x203,\x201,\x20null','outboundNoAnswerCallsDay','`state`\x20=\x205,\x201,\x20null','`state`\x20=\x208,\x201,\x20null','outboundCongestionCallsDay','outboundDropCallsDayTimeout','outboundDropCallsDayCallersExit','`state`\x20=\x2012,\x201,\x20null','outboundUnknownCallsDay','`state`\x20=\x2013,\x201,\x20null','outboundOriginateFailureCallsDay','`state`\x20=\x2018,\x201,\x20null','`state`\x20=\x2016,\x201,\x20null','outboundAnswerAgiCallsDay','`state`\x20=\x2020,\x201,\x20null','outboundRejectCallsDay','GetCampaignHopperHistory','where','ivrTotalCallsDays','ivrAnswerCallsDay','lodash','util','moment','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','rpc','../../config/environment','jayson/promise','http','request','then','info','CmHopperHistory,\x20%s,\x20%s','request\x20sent','debug','CmHopperHistory,\x20%s,\x20%s,\x20%s','error','code','message','result','catch','CmHopperHistory','create'];(function(_0x3dd15e,_0x1f0015){var _0x231fd0=function(_0x4f680a){while(--_0x4f680a){_0x3dd15e['push'](_0x3dd15e['shift']());}};_0x231fd0(++_0x1f0015);}(_0xcd56,0x1c9));var _0x6cd5=function(_0x226012,_0x4a2ad7){_0x226012=_0x226012-0x0;var _0x1de528=_0xcd56[_0x226012];return _0x1de528;};'use strict';var _=require(_0x6cd5('0x0'));var util=require(_0x6cd5('0x1'));var moment=require(_0x6cd5('0x2'));var BPromise=require('bluebird');var rs=require(_0x6cd5('0x3'));var fs=require('fs');var Redis=require(_0x6cd5('0x4'));var db=require(_0x6cd5('0x5'))['db'];var utils=require(_0x6cd5('0x6'));var logger=require(_0x6cd5('0x7'))(_0x6cd5('0x8'));var config=require(_0x6cd5('0x9'));var jayson=require(_0x6cd5('0xa'));var client=jayson['client'][_0x6cd5('0xb')]({'port':0x232a});function respondWithRpcPromise(_0x6a4a9c,_0x1c4af9,_0x25e9a3){return new BPromise(function(_0x589bf9,_0x52c80b){return client[_0x6cd5('0xc')](_0x6a4a9c,_0x25e9a3)[_0x6cd5('0xd')](function(_0x474eb7){logger[_0x6cd5('0xe')](_0x6cd5('0xf'),_0x1c4af9,_0x6cd5('0x10'));logger[_0x6cd5('0x11')](_0x6cd5('0x12'),_0x1c4af9,_0x6cd5('0x10'),JSON['stringify'](_0x474eb7));if(_0x474eb7[_0x6cd5('0x13')]){if(_0x474eb7['error'][_0x6cd5('0x14')]===0x1f4){logger[_0x6cd5('0x13')]('CmHopperHistory,\x20%s,\x20%s',_0x1c4af9,_0x474eb7['error']['message']);return _0x52c80b(_0x474eb7[_0x6cd5('0x13')]['message']);}logger[_0x6cd5('0x13')](_0x6cd5('0xf'),_0x1c4af9,_0x474eb7['error'][_0x6cd5('0x15')]);return _0x589bf9(_0x474eb7[_0x6cd5('0x13')]['message']);}else{logger[_0x6cd5('0xe')](_0x6cd5('0xf'),_0x1c4af9,_0x6cd5('0x10'));_0x589bf9(_0x474eb7[_0x6cd5('0x16')][_0x6cd5('0x15')]);}})[_0x6cd5('0x17')](function(_0x382547){logger[_0x6cd5('0x13')](_0x6cd5('0xf'),_0x1c4af9,_0x382547);_0x52c80b(_0x382547);});});}exports['CreateCmHopperHistory']=function(_0xb696b9){var _0xe42af0=this;return new Promise(function(_0x1bef3d,_0x50724d){return db[_0x6cd5('0x18')][_0x6cd5('0x19')](_0xb696b9[_0x6cd5('0x1a')],{'raw':_0xb696b9[_0x6cd5('0x1b')]?_0xb696b9['options'][_0x6cd5('0x1c')]===undefined?!![]:![]:!![]})[_0x6cd5('0xd')](function(_0x1b2bce){logger[_0x6cd5('0xe')]('CreateCmHopperHistory',_0xb696b9);logger[_0x6cd5('0x11')]('CreateCmHopperHistory',_0xb696b9,JSON[_0x6cd5('0x1d')](_0x1b2bce));_0x1bef3d(_0x1b2bce);})[_0x6cd5('0x17')](function(_0x314b5a){logger['error'](_0x6cd5('0x1e'),_0x314b5a['message'],_0xb696b9);_0x50724d(_0xe42af0[_0x6cd5('0x13')](0x1f4,_0x314b5a['message']));});});};exports[_0x6cd5('0x1f')]=function(_0x234648){var _0x2feb60=this;return new Promise(function(_0x4e502a,_0xba6cb9){return db[_0x6cd5('0x18')][_0x6cd5('0x20')]({'raw':_0x234648[_0x6cd5('0x1b')]?_0x234648[_0x6cd5('0x1b')][_0x6cd5('0x1c')]===undefined?!![]:![]:!![],'where':_0x234648['options']?_0x234648['options']['where']||null:null,'attributes':[[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')][_0x6cd5('0x23')]('id')),'predictiveIntervalTotalCalls'],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x25')))),_0x6cd5('0x26')],[db[_0x6cd5('0x21')]['fn']('COUNT',db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x27')))),_0x6cd5('0x28')],[db[_0x6cd5('0x21')]['fn']('COUNT',db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')]['literal']('`state`\x20=\x2011,\x201,\x20null'))),_0x6cd5('0x29')],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x2a'),db[_0x6cd5('0x21')]['fn']('IF',db['sequelize'][_0x6cd5('0x24')](_0x6cd5('0x2b')))),_0x6cd5('0x2c')],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x2a'),db['sequelize']['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x2d')))),'predictiveIntervalAvgTalktime']]})[_0x6cd5('0xd')](function(_0x28d5c6){logger[_0x6cd5('0xe')]('AvgHandleTime',_0x234648);logger[_0x6cd5('0x11')](_0x6cd5('0x1f'),_0x234648,JSON[_0x6cd5('0x1d')](_0x28d5c6));_0x4e502a(_0x28d5c6);})[_0x6cd5('0x17')](function(_0x3a0435){logger[_0x6cd5('0x13')]('AvgHandleTime',_0x3a0435[_0x6cd5('0x15')],_0x234648);_0xba6cb9(_0x2feb60[_0x6cd5('0x13')](0x1f4,_0x3a0435[_0x6cd5('0x15')]));});});};exports[_0x6cd5('0x2e')]=function(_0x1bb7d0){var _0x3d5ff3=this;return new Promise(function(_0x57f709,_0x304015){return db['CmHopperHistory']['findAll']({'raw':_0x1bb7d0['options']?_0x1bb7d0[_0x6cd5('0x1b')]['raw']===undefined?!![]:![]:!![],'where':_0x1bb7d0[_0x6cd5('0x1b')]?_0x1bb7d0[_0x6cd5('0x1b')]['where']||null:null,'attributes':[['campaign',_0x6cd5('0x2f')],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x30')))),'outboundNoSuchCallsDay'],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x31')))),_0x6cd5('0x32')],[db['sequelize']['fn']('COUNT',db[_0x6cd5('0x21')]['fn']('IF',db['sequelize']['literal'](_0x6cd5('0x25')))),'outboundAnswerCallsDay'],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x33')))),'outboundBusyCallsDay'],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db['sequelize']['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x34')))),_0x6cd5('0x35')],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')]('`state`\x20=\x2010\x20,\x201,\x20null'))),_0x6cd5('0x36')],[db['sequelize']['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')]('`state`\x20=\x2011\x20,\x201,\x20null'))),_0x6cd5('0x37')],[db['sequelize']['fn'](_0x6cd5('0x22'),db['sequelize']['fn']('IF',db[_0x6cd5('0x21')]['literal'](_0x6cd5('0x38')))),_0x6cd5('0x39')],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x3a')))),'outboundBlacklistCallsDay'],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')]('`state`\x20=\x2014,\x201,\x20null'))),_0x6cd5('0x3b')],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x3c')))),'outboundRejectCallsDay'],[db[_0x6cd5('0x21')]['fn']('COUNT',db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x3d')))),_0x6cd5('0x3e')],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')](_0x6cd5('0x3f')))),_0x6cd5('0x40')],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')][_0x6cd5('0x24')]('`state`\x20=\x2022\x20or\x20`state`\x20=\x2023,\x201,\x20null'))),'outboundReCallsDay']],'group':['campaign']})['then'](function(_0xa44dc4){logger[_0x6cd5('0xe')]('GetVoiceQueueHopperHistory',_0x1bb7d0);logger[_0x6cd5('0x11')](_0x6cd5('0x2e'),_0x1bb7d0,JSON[_0x6cd5('0x1d')](_0xa44dc4));_0x57f709(_0xa44dc4);})[_0x6cd5('0x17')](function(_0x271c9a){logger[_0x6cd5('0x13')](_0x6cd5('0x2e'),_0x271c9a[_0x6cd5('0x15')],_0x1bb7d0);_0x304015(_0x3d5ff3[_0x6cd5('0x13')](0x1f4,_0x271c9a[_0x6cd5('0x15')]));});});};exports[_0x6cd5('0x41')]=function(_0x45ffdf){var _0x4b66d9=this;return new Promise(function(_0x320b78,_0x27970f){return db['CmHopperHistory']['findAll']({'raw':_0x45ffdf[_0x6cd5('0x1b')]?_0x45ffdf[_0x6cd5('0x1b')][_0x6cd5('0x1c')]===undefined?!![]:![]:!![],'where':_0x45ffdf[_0x6cd5('0x1b')]?_0x45ffdf['options'][_0x6cd5('0x42')]||null:null,'attributes':[['campaign',_0x6cd5('0x2f')],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['col']('id')),_0x6cd5('0x43')],[db[_0x6cd5('0x21')]['fn'](_0x6cd5('0x22'),db[_0x6cd5('0x21')]['fn']('IF',db[_0x6cd5('0x21')]['literal']('`state`\x20=\x204,\x201,\x20null'))),_0x6cd5('0x44')]],'group':['campaign']})[_0x6cd5('0xd')](function(_0x52b120){logger[_0x6cd5('0xe')](_0x6cd5('0x41'),_0x45ffdf);logger['debug'](_0x6cd5('0x41'),_0x45ffdf,JSON[_0x6cd5('0x1d')](_0x52b120));_0x320b78(_0x52b120);})[_0x6cd5('0x17')](function(_0x2bdc13){logger[_0x6cd5('0x13')]('GetCampaignHopperHistory',_0x2bdc13[_0x6cd5('0x15')],_0x45ffdf);_0x27970f(_0x4b66d9[_0x6cd5('0x13')](0x1f4,_0x2bdc13[_0x6cd5('0x15')]));});});};
\ No newline at end of file
+var _0x4e09=['GetVoiceQueueHopperHistory','findAll','campaign','name','`state`\x20=\x200,\x201,\x20null','outboundNoSuchCallsDay','`state`\x20=\x203,\x201,\x20null','outboundAnswerCallsDay','outboundBusyCallsDay','`state`\x20=\x208,\x201,\x20null','`state`\x20=\x2010\x20,\x201,\x20null','`state`\x20=\x2011\x20,\x201,\x20null','outboundDropCallsDayCallersExit','`state`\x20=\x2012,\x201,\x20null','outboundUnknownCallsDay','`state`\x20=\x2014,\x201,\x20null','outboundOriginateFailureCallsDay','`state`\x20=\x2018,\x201,\x20null','outboundRejectCallsDay','`state`\x20=\x2016,\x201,\x20null','outboundAnswerAgiCallsDay','`state`\x20=\x2022\x20or\x20`state`\x20=\x2023,\x201,\x20null','outboundReCallsDay','ivrTotalCallsDays','ivrAnswerCallsDay','GetCampaignHopperHistory','lodash','moment','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','rpc','../../config/environment','jayson/promise','client','http','then','CmHopperHistory,\x20%s,\x20%s','request\x20sent','stringify','error','message','result','catch','CreateCmHopperHistory','CmHopperHistory','body','options','raw','info','debug','AvgHandleTime','where','sequelize','COUNT','col','predictiveIntervalTotalCalls','literal','`state`\x20=\x204,\x201,\x20null','predictiveIntervalAnsweredCalls','predictiveIntervalDroppedCallsCallersExit','`state`\x20=\x204,\x20`holdtime`,\x20null','predictiveIntervalAvgHoldtime','AVG','`state`\x20=\x204,\x20`talktime`,\x20null','predictiveIntervalAvgTalktime'];(function(_0x3ad57a,_0x12ee6c){var _0xf60ddc=function(_0x2360dd){while(--_0x2360dd){_0x3ad57a['push'](_0x3ad57a['shift']());}};_0xf60ddc(++_0x12ee6c);}(_0x4e09,0xa2));var _0x94e0=function(_0x413feb,_0x10477f){_0x413feb=_0x413feb-0x0;var _0x40ee88=_0x4e09[_0x413feb];return _0x40ee88;};'use strict';var _=require(_0x94e0('0x0'));var util=require('util');var moment=require(_0x94e0('0x1'));var BPromise=require('bluebird');var rs=require(_0x94e0('0x2'));var fs=require('fs');var Redis=require(_0x94e0('0x3'));var db=require(_0x94e0('0x4'))['db'];var utils=require(_0x94e0('0x5'));var logger=require(_0x94e0('0x6'))(_0x94e0('0x7'));var config=require(_0x94e0('0x8'));var jayson=require(_0x94e0('0x9'));var client=jayson[_0x94e0('0xa')][_0x94e0('0xb')]({'port':0x232a});function respondWithRpcPromise(_0x198399,_0x4ead23,_0xa0620){return new BPromise(function(_0x45350e,_0x27a12c){return client['request'](_0x198399,_0xa0620)[_0x94e0('0xc')](function(_0x2536f0){logger['info'](_0x94e0('0xd'),_0x4ead23,_0x94e0('0xe'));logger['debug']('CmHopperHistory,\x20%s,\x20%s,\x20%s',_0x4ead23,_0x94e0('0xe'),JSON[_0x94e0('0xf')](_0x2536f0));if(_0x2536f0[_0x94e0('0x10')]){if(_0x2536f0[_0x94e0('0x10')]['code']===0x1f4){logger[_0x94e0('0x10')]('CmHopperHistory,\x20%s,\x20%s',_0x4ead23,_0x2536f0[_0x94e0('0x10')][_0x94e0('0x11')]);return _0x27a12c(_0x2536f0[_0x94e0('0x10')]['message']);}logger['error'](_0x94e0('0xd'),_0x4ead23,_0x2536f0[_0x94e0('0x10')][_0x94e0('0x11')]);return _0x45350e(_0x2536f0[_0x94e0('0x10')][_0x94e0('0x11')]);}else{logger['info'](_0x94e0('0xd'),_0x4ead23,_0x94e0('0xe'));_0x45350e(_0x2536f0[_0x94e0('0x12')][_0x94e0('0x11')]);}})[_0x94e0('0x13')](function(_0x3480bb){logger[_0x94e0('0x10')](_0x94e0('0xd'),_0x4ead23,_0x3480bb);_0x27a12c(_0x3480bb);});});}exports[_0x94e0('0x14')]=function(_0x2341a4){var _0x4143c3=this;return new Promise(function(_0x2b3004,_0x8071c5){return db[_0x94e0('0x15')]['create'](_0x2341a4[_0x94e0('0x16')],{'raw':_0x2341a4['options']?_0x2341a4[_0x94e0('0x17')][_0x94e0('0x18')]===undefined?!![]:![]:!![]})['then'](function(_0x44921d){logger[_0x94e0('0x19')](_0x94e0('0x14'),_0x2341a4);logger[_0x94e0('0x1a')]('CreateCmHopperHistory',_0x2341a4,JSON[_0x94e0('0xf')](_0x44921d));_0x2b3004(_0x44921d);})[_0x94e0('0x13')](function(_0x3db0b4){logger[_0x94e0('0x10')](_0x94e0('0x14'),_0x3db0b4[_0x94e0('0x11')],_0x2341a4);_0x8071c5(_0x4143c3[_0x94e0('0x10')](0x1f4,_0x3db0b4[_0x94e0('0x11')]));});});};exports[_0x94e0('0x1b')]=function(_0x3729ec){var _0x2c0b4c=this;return new Promise(function(_0x1f1892,_0x2aa2ae){return db[_0x94e0('0x15')]['findAll']({'raw':_0x3729ec['options']?_0x3729ec[_0x94e0('0x17')][_0x94e0('0x18')]===undefined?!![]:![]:!![],'where':_0x3729ec[_0x94e0('0x17')]?_0x3729ec[_0x94e0('0x17')][_0x94e0('0x1c')]||null:null,'attributes':[[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')][_0x94e0('0x1f')]('id')),_0x94e0('0x20')],[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')]['fn']('IF',db['sequelize'][_0x94e0('0x21')](_0x94e0('0x22')))),_0x94e0('0x23')],[db[_0x94e0('0x1d')]['fn']('COUNT',db[_0x94e0('0x1d')]['fn']('IF',db['sequelize'][_0x94e0('0x21')]('`state`\x20=\x2010,\x201,\x20null'))),'predictiveIntervalDroppedCallsTimeout'],[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')]['fn']('IF',db[_0x94e0('0x1d')][_0x94e0('0x21')]('`state`\x20=\x2011,\x201,\x20null'))),_0x94e0('0x24')],[db['sequelize']['fn']('AVG',db['sequelize']['fn']('IF',db[_0x94e0('0x1d')]['literal'](_0x94e0('0x25')))),_0x94e0('0x26')],[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x27'),db['sequelize']['fn']('IF',db[_0x94e0('0x1d')]['literal'](_0x94e0('0x28')))),_0x94e0('0x29')]]})[_0x94e0('0xc')](function(_0x1b57f1){logger[_0x94e0('0x19')](_0x94e0('0x1b'),_0x3729ec);logger['debug']('AvgHandleTime',_0x3729ec,JSON[_0x94e0('0xf')](_0x1b57f1));_0x1f1892(_0x1b57f1);})['catch'](function(_0x13e1e9){logger[_0x94e0('0x10')](_0x94e0('0x1b'),_0x13e1e9[_0x94e0('0x11')],_0x3729ec);_0x2aa2ae(_0x2c0b4c['error'](0x1f4,_0x13e1e9['message']));});});};exports[_0x94e0('0x2a')]=function(_0x521db4){var _0x15f481=this;return new Promise(function(_0x4b4821,_0x1845c4){return db[_0x94e0('0x15')][_0x94e0('0x2b')]({'raw':_0x521db4[_0x94e0('0x17')]?_0x521db4[_0x94e0('0x17')]['raw']===undefined?!![]:![]:!![],'where':_0x521db4['options']?_0x521db4[_0x94e0('0x17')]['where']||null:null,'attributes':[[_0x94e0('0x2c'),_0x94e0('0x2d')],[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x1e'),db['sequelize']['fn']('IF',db[_0x94e0('0x1d')]['literal'](_0x94e0('0x2e')))),_0x94e0('0x2f')],[db['sequelize']['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')]['fn']('IF',db[_0x94e0('0x1d')][_0x94e0('0x21')](_0x94e0('0x30')))),'outboundNoAnswerCallsDay'],[db[_0x94e0('0x1d')]['fn']('COUNT',db[_0x94e0('0x1d')]['fn']('IF',db[_0x94e0('0x1d')][_0x94e0('0x21')]('`state`\x20=\x204,\x201,\x20null'))),_0x94e0('0x31')],[db['sequelize']['fn']('COUNT',db[_0x94e0('0x1d')]['fn']('IF',db[_0x94e0('0x1d')][_0x94e0('0x21')]('`state`\x20=\x205,\x201,\x20null'))),_0x94e0('0x32')],[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x1e'),db['sequelize']['fn']('IF',db[_0x94e0('0x1d')]['literal'](_0x94e0('0x33')))),'outboundCongestionCallsDay'],[db['sequelize']['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')]['fn']('IF',db[_0x94e0('0x1d')][_0x94e0('0x21')](_0x94e0('0x34')))),'outboundDropCallsDayTimeout'],[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x1e'),db['sequelize']['fn']('IF',db[_0x94e0('0x1d')]['literal'](_0x94e0('0x35')))),_0x94e0('0x36')],[db['sequelize']['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')]['fn']('IF',db[_0x94e0('0x1d')][_0x94e0('0x21')](_0x94e0('0x37')))),_0x94e0('0x38')],[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')]['fn']('IF',db[_0x94e0('0x1d')][_0x94e0('0x21')]('`state`\x20=\x2013,\x201,\x20null'))),'outboundBlacklistCallsDay'],[db['sequelize']['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')]['fn']('IF',db['sequelize'][_0x94e0('0x21')](_0x94e0('0x39')))),_0x94e0('0x3a')],[db['sequelize']['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')]['fn']('IF',db['sequelize'][_0x94e0('0x21')](_0x94e0('0x3b')))),_0x94e0('0x3c')],[db['sequelize']['fn'](_0x94e0('0x1e'),db['sequelize']['fn']('IF',db[_0x94e0('0x1d')]['literal'](_0x94e0('0x3d')))),_0x94e0('0x3e')],[db['sequelize']['fn']('COUNT',db[_0x94e0('0x1d')]['fn']('IF',db['sequelize']['literal']('`state`\x20=\x2020,\x201,\x20null'))),'outboundRejectCallsDay'],[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')]['fn']('IF',db[_0x94e0('0x1d')][_0x94e0('0x21')](_0x94e0('0x3f')))),_0x94e0('0x40')]],'group':[_0x94e0('0x2c')]})[_0x94e0('0xc')](function(_0x353fb8){logger[_0x94e0('0x19')](_0x94e0('0x2a'),_0x521db4);logger[_0x94e0('0x1a')]('GetVoiceQueueHopperHistory',_0x521db4,JSON[_0x94e0('0xf')](_0x353fb8));_0x4b4821(_0x353fb8);})[_0x94e0('0x13')](function(_0x459fc0){logger[_0x94e0('0x10')](_0x94e0('0x2a'),_0x459fc0[_0x94e0('0x11')],_0x521db4);_0x1845c4(_0x15f481[_0x94e0('0x10')](0x1f4,_0x459fc0['message']));});});};exports['GetCampaignHopperHistory']=function(_0x1790d8){var _0xb2cd80=this;return new Promise(function(_0x5cd44e,_0x595b38){return db[_0x94e0('0x15')][_0x94e0('0x2b')]({'raw':_0x1790d8[_0x94e0('0x17')]?_0x1790d8[_0x94e0('0x17')][_0x94e0('0x18')]===undefined?!![]:![]:!![],'where':_0x1790d8['options']?_0x1790d8[_0x94e0('0x17')][_0x94e0('0x1c')]||null:null,'attributes':[[_0x94e0('0x2c'),_0x94e0('0x2d')],[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')][_0x94e0('0x1f')]('id')),_0x94e0('0x41')],[db[_0x94e0('0x1d')]['fn'](_0x94e0('0x1e'),db[_0x94e0('0x1d')]['fn']('IF',db[_0x94e0('0x1d')][_0x94e0('0x21')](_0x94e0('0x22')))),_0x94e0('0x42')]],'group':[_0x94e0('0x2c')]})[_0x94e0('0xc')](function(_0x245f67){logger[_0x94e0('0x19')](_0x94e0('0x43'),_0x1790d8);logger[_0x94e0('0x1a')]('GetCampaignHopperHistory',_0x1790d8,JSON[_0x94e0('0xf')](_0x245f67));_0x5cd44e(_0x245f67);})[_0x94e0('0x13')](function(_0x1a424a){logger[_0x94e0('0x10')]('GetCampaignHopperHistory',_0x1a424a[_0x94e0('0x11')],_0x1790d8);_0x595b38(_0xb2cd80['error'](0x1f4,_0x1a424a[_0x94e0('0x11')]));});});};
\ No newline at end of file