Built motion from commit 70c527640.|1.0.24
[motion.git] / server / config / ami / db / voiceQueueReport.js
index 7ab9cb9..9202239 100644 (file)
@@ -1 +1 @@
-var _0x2c4a=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x62\x6C\x75\x65\x62\x69\x72\x64","\x6D\x6F\x6D\x65\x6E\x74","\x6C\x6F\x64\x61\x73\x68","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65","\x2E\x2E\x2F\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x61\x6D\x69","\x2E\x2E\x2F\x2E\x2E\x2F\x6C\x6F\x67\x67\x65\x72\x2E\x6A\x73","\x65\x78\x70\x6F\x72\x74\x73","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x61\x67\x65\x6E\x74\x63\x6F\x6D\x70\x6C\x65\x74\x65","\x65\x72\x72\x6F\x72","\x63\x61\x74\x63\x68","\x6E\x6F\x77","\x75\x70\x64\x61\x74\x65\x41\x74\x74\x72\x69\x62\x75\x74\x65\x73","\x74\x68\x65\x6E","\x75\x6E\x69\x71\x75\x65\x69\x64","\x69\x64\x20\x44\x45\x53\x43","\x66\x69\x6E\x64\x4F\x6E\x65","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x74\x72\x61\x6E\x73\x66\x65\x72","\x74\x72\x61\x6E\x73\x66\x65\x72","\x74\x72\x61\x6E\x73\x66\x65\x72\x74\x79\x70\x65","\x74\x72\x61\x6E\x73\x66\x65\x72\x75\x6E\x69\x71\x75\x65\x69\x64","\x74\x72\x61\x6E\x73\x66\x65\x72\x65\x78\x74\x65\x6E\x73\x69\x6F\x6E","\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x65\x78\x69\x74\x72\x65\x61\x73\x6F\x6E","\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x63\x6F\x6D\x70\x6C\x65\x74\x65","\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x63\x6F\x6D\x70\x6C\x65\x74\x65\x41\x74","\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x6C\x65\x61\x76\x65\x41\x74","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x61\x67\x65\x6E\x74\x63\x6F\x6E\x6E\x65\x63\x74","\x68\x6F\x6C\x64\x74\x69\x6D\x65","\x6D\x65\x6D\x62\x65\x72\x6E\x61\x6D\x65","\x63\x6F\x6E\x6E\x65\x63\x74\x65\x64\x6C\x69\x6E\x65\x6E\x75\x6D","\x63\x6F\x6E\x6E\x65\x63\x74\x65\x64\x6C\x69\x6E\x65\x6E\x61\x6D\x65","\x6D\x65\x72\x67\x65","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x6A\x6F\x69\x6E","\x63\x72\x65\x61\x74\x65","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x61\x62\x61\x6E\x64\x6F\x6E","\x6F\x72\x69\x67\x69\x6E\x61\x6C\x70\x6F\x73\x69\x74\x69\x6F\x6E","\x70\x6F\x73\x69\x74\x69\x6F\x6E","\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x6A\x6F\x69\x6E\x41\x74","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x73\x74\x61\x74\x75\x73\x20\x63\x72\x65\x61\x74\x65","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x73\x74\x61\x74\x75\x73\x20\x75\x70\x64\x61\x74\x65","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x6C\x65\x61\x76\x65"];_0x2c4a[0];var BPromise=require(_0x2c4a[1]);var moment=require(_0x2c4a[2]);var _=require(_0x2c4a[3]);var ReportQueue=require(_0x2c4a[5])[_0x2c4a[4]];var logger=require(_0x2c4a[7])(_0x2c4a[6]);module[_0x2c4a[8]]= function(){return {agentcomplete:function(_0x4c4dx6){return function(_0x4c4dx7){return ReportQueue[_0x2c4a[17]]({where:{uniqueid:_0x4c4dx6[_0x2c4a[15]],queuecallerleaveAt:{$ne:null},transfer:false},order:_0x2c4a[16]})[_0x2c4a[14]](function(_0x4c4dx9){if(_0x4c4dx9){return _0x4c4dx9[_0x2c4a[13]]({queuecallercomplete:true,queuecallercompleteAt:_0x4c4dx6[_0x2c4a[12]]})}})[_0x2c4a[11]](function(_0x4c4dx8){logger[_0x2c4a[10]](_0x2c4a[9],_0x4c4dx8)})}},queuetransfer:function(_0x4c4dx6){return function(_0x4c4dx7){return ReportQueue[_0x2c4a[17]]({where:{uniqueid:_0x4c4dx6[_0x2c4a[15]]},order:_0x2c4a[16]})[_0x2c4a[14]](function(_0x4c4dx9){if(_0x4c4dx9){var _0x4c4dxa={transfer:_0x4c4dx6[_0x2c4a[19]],transfertype:_0x4c4dx6[_0x2c4a[20]],transferuniqueid:_0x4c4dx6[_0x2c4a[21]],transferextension:_0x4c4dx6[_0x2c4a[22]],queuecallerexitreason:_0x4c4dx6[_0x2c4a[23]]};if(!_0x4c4dx9[_0x2c4a[24]]){_0x4c4dxa[_0x2c4a[24]]= true;_0x4c4dxa[_0x2c4a[25]]= _0x4c4dx6[_0x2c4a[12]]};if(!_0x4c4dx9[_0x2c4a[26]]){_0x4c4dxa[_0x2c4a[26]]= _0x4c4dx6[_0x2c4a[12]]};return _0x4c4dx9[_0x2c4a[13]](_0x4c4dxa)}})[_0x2c4a[11]](function(_0x4c4dx8){logger[_0x2c4a[10]](_0x2c4a[18],_0x4c4dx8)})}},agentconnect:function(_0x4c4dx6){return function(_0x4c4dx7){return ReportQueue[_0x2c4a[17]]({where:{uniqueid:_0x4c4dx6[_0x2c4a[15]]},order:_0x2c4a[16]})[_0x2c4a[14]](function(_0x4c4dx9){if(_0x4c4dx9){return _0x4c4dx9[_0x2c4a[13]]({holdtime:_0x4c4dx6[_0x2c4a[28]],assigned:true,lastAssignedTo:_0x4c4dx6[_0x2c4a[29]],connectedlinenum:_0x4c4dx6[_0x2c4a[30]],connectedlinename:_0x4c4dx6[_0x2c4a[31]]})}})[_0x2c4a[11]](function(_0x4c4dx8){logger[_0x2c4a[10]](_0x2c4a[27],_0x4c4dx8)})}},queuecallerjoin:function(_0x4c4dx6){return function(_0x4c4dx7){_[_0x2c4a[32]](_0x4c4dx6,{queuecallerjoinAt:_0x4c4dx6[_0x2c4a[12]]});return ReportQueue[_0x2c4a[34]](_0x4c4dx6,{raw:true})[_0x2c4a[11]](function(_0x4c4dx8){logger[_0x2c4a[10]](_0x2c4a[33],_0x4c4dx8)})}},queuecallerabandon:function(_0x4c4dx6){return function(_0x4c4dx7){return ReportQueue[_0x2c4a[17]]({where:{uniqueid:_0x4c4dx6[_0x2c4a[15]],queuecallercomplete:false,$or:{queuecallerexitreason:null,queuecallerexit:false}},order:_0x2c4a[16]})[_0x2c4a[14]](function(_0x4c4dx9){if(_0x4c4dx9){return _0x4c4dx9[_0x2c4a[13]]({queuecallerabandon:true,queuecallerabandonAt:_0x4c4dx6[_0x2c4a[12]],queuecallerleaveAt:_0x4c4dx6[_0x2c4a[12]],queuecallerexit:false,queuecallerexitAt:null,queuecallerexitreason:null,connectedlinenum:null,connectedlinename:null,originalposition:_0x4c4dx6[_0x2c4a[36]],position:_0x4c4dx6[_0x2c4a[37]],holdtime:_0x4c4dx6[_0x2c4a[28]]})}})[_0x2c4a[11]](function(_0x4c4dx8){logger[_0x2c4a[10]](_0x2c4a[35],_0x4c4dx8)})}},queuecallerunmanaged:function(_0x4c4dx6){return function(_0x4c4dx7){var _0x4c4dxa={queuecallerabandon:false,queuecallerabandonAt:null,queuecallerexit:true,queuecallerexitAt:_0x4c4dx6[_0x2c4a[12]],connectedlinenum:null,connectedlinename:null,queuecallerleaveAt:_0x4c4dx6[_0x2c4a[12]],queuecallerexitreason:_0x4c4dx6[_0x2c4a[23]]};if(_0x4c4dx6[_0x2c4a[34]]){_0x4c4dxa[_0x2c4a[38]]= _0x4c4dx6[_0x2c4a[12]];return ReportQueue[_0x2c4a[34]](_[_0x2c4a[32]](_0x4c4dx6,_0x4c4dxa))[_0x2c4a[11]](function(_0x4c4dx8){logger[_0x2c4a[10]](_0x2c4a[39],_0x4c4dx8)})}else {return ReportQueue[_0x2c4a[17]]({where:{uniqueid:_0x4c4dx6[_0x2c4a[15]],queuecallerexitreason:null},order:_0x2c4a[16]})[_0x2c4a[14]](function(_0x4c4dx9){if(_0x4c4dx9){return _0x4c4dx9[_0x2c4a[13]](_0x4c4dxa)}})[_0x2c4a[11]](function(_0x4c4dx8){logger[_0x2c4a[10]](_0x2c4a[40],_0x4c4dx8)})}}},queuecallerleave:function(_0x4c4dx6){return function(_0x4c4dx7){var _0x4c4dxb={queuecallerleaveAt:_0x4c4dx6[_0x2c4a[12]]};return ReportQueue[_0x2c4a[17]]({where:{uniqueid:_0x4c4dx6[_0x2c4a[15]],queuecallerleaveAt:null},order:_0x2c4a[16]})[_0x2c4a[14]](function(_0x4c4dx9){if(_0x4c4dx9){return _0x4c4dx9[_0x2c4a[13]](_0x4c4dxb)}})[_0x2c4a[11]](function(_0x4c4dx8){logger[_0x2c4a[10]](_0x2c4a[41],_0x4c4dx8)})}}}}
\ No newline at end of file
+var _0x5e05=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x62\x6C\x75\x65\x62\x69\x72\x64","\x6D\x6F\x6D\x65\x6E\x74","\x6C\x6F\x64\x61\x73\x68","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65","\x2E\x2E\x2F\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x61\x6D\x69","\x2E\x2E\x2F\x2E\x2E\x2F\x6C\x6F\x67\x67\x65\x72\x2E\x6A\x73","\x65\x78\x70\x6F\x72\x74\x73","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x61\x67\x65\x6E\x74\x63\x6F\x6D\x70\x6C\x65\x74\x65","\x65\x72\x72\x6F\x72","\x63\x61\x74\x63\x68","\x6E\x6F\x77","\x75\x70\x64\x61\x74\x65\x41\x74\x74\x72\x69\x62\x75\x74\x65\x73","\x74\x68\x65\x6E","\x75\x6E\x69\x71\x75\x65\x69\x64","\x69\x64\x20\x44\x45\x53\x43","\x66\x69\x6E\x64\x4F\x6E\x65","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x74\x72\x61\x6E\x73\x66\x65\x72","\x74\x72\x61\x6E\x73\x66\x65\x72","\x74\x72\x61\x6E\x73\x66\x65\x72\x74\x79\x70\x65","\x74\x72\x61\x6E\x73\x66\x65\x72\x75\x6E\x69\x71\x75\x65\x69\x64","\x74\x72\x61\x6E\x73\x66\x65\x72\x65\x78\x74\x65\x6E\x73\x69\x6F\x6E","\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x65\x78\x69\x74\x72\x65\x61\x73\x6F\x6E","\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x63\x6F\x6D\x70\x6C\x65\x74\x65","\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x63\x6F\x6D\x70\x6C\x65\x74\x65\x41\x74","\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x6C\x65\x61\x76\x65\x41\x74","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x61\x67\x65\x6E\x74\x63\x6F\x6E\x6E\x65\x63\x74","\x68\x6F\x6C\x64\x74\x69\x6D\x65","\x6D\x65\x6D\x62\x65\x72\x6E\x61\x6D\x65","\x63\x6F\x6E\x6E\x65\x63\x74\x65\x64\x6C\x69\x6E\x65\x6E\x75\x6D","\x63\x6F\x6E\x6E\x65\x63\x74\x65\x64\x6C\x69\x6E\x65\x6E\x61\x6D\x65","\x6D\x65\x72\x67\x65","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x6A\x6F\x69\x6E","\x63\x72\x65\x61\x74\x65","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x61\x62\x61\x6E\x64\x6F\x6E","\x6F\x72\x69\x67\x69\x6E\x61\x6C\x70\x6F\x73\x69\x74\x69\x6F\x6E","\x70\x6F\x73\x69\x74\x69\x6F\x6E","\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x6A\x6F\x69\x6E\x41\x74","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x73\x74\x61\x74\x75\x73\x20\x63\x72\x65\x61\x74\x65","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x73\x74\x61\x74\x75\x73\x20\x75\x70\x64\x61\x74\x65","\x52\x65\x70\x6F\x72\x74\x51\x75\x65\x75\x65\x20\x2D\x20\x71\x75\x65\x75\x65\x63\x61\x6C\x6C\x65\x72\x6C\x65\x61\x76\x65"];_0x5e05[0];var BPromise=require(_0x5e05[1]);var moment=require(_0x5e05[2]);var _=require(_0x5e05[3]);var ReportQueue=require(_0x5e05[5])[_0x5e05[4]];var logger=require(_0x5e05[7])(_0x5e05[6]);module[_0x5e05[8]]= function(){return {agentcomplete:function(_0x4511x6){return function(_0x4511x7){return ReportQueue[_0x5e05[17]]({where:{uniqueid:_0x4511x6[_0x5e05[15]],queuecallerleaveAt:{$ne:null},transfer:false},order:_0x5e05[16]})[_0x5e05[14]](function(_0x4511x9){if(_0x4511x9){return _0x4511x9[_0x5e05[13]]({queuecallercomplete:true,queuecallercompleteAt:_0x4511x6[_0x5e05[12]]})}})[_0x5e05[11]](function(_0x4511x8){logger[_0x5e05[10]](_0x5e05[9],_0x4511x8)})}},queuetransfer:function(_0x4511x6){return function(_0x4511x7){return ReportQueue[_0x5e05[17]]({where:{uniqueid:_0x4511x6[_0x5e05[15]]},order:_0x5e05[16]})[_0x5e05[14]](function(_0x4511x9){if(_0x4511x9){var _0x4511xa={transfer:_0x4511x6[_0x5e05[19]],transfertype:_0x4511x6[_0x5e05[20]],transferuniqueid:_0x4511x6[_0x5e05[21]],transferextension:_0x4511x6[_0x5e05[22]],queuecallerexitreason:_0x4511x6[_0x5e05[23]]};if(!_0x4511x9[_0x5e05[24]]){_0x4511xa[_0x5e05[24]]= true;_0x4511xa[_0x5e05[25]]= _0x4511x6[_0x5e05[12]]};if(!_0x4511x9[_0x5e05[26]]){_0x4511xa[_0x5e05[26]]= _0x4511x6[_0x5e05[12]]};return _0x4511x9[_0x5e05[13]](_0x4511xa)}})[_0x5e05[11]](function(_0x4511x8){logger[_0x5e05[10]](_0x5e05[18],_0x4511x8)})}},agentconnect:function(_0x4511x6){return function(_0x4511x7){return ReportQueue[_0x5e05[17]]({where:{uniqueid:_0x4511x6[_0x5e05[15]]},order:_0x5e05[16]})[_0x5e05[14]](function(_0x4511x9){if(_0x4511x9){return _0x4511x9[_0x5e05[13]]({holdtime:_0x4511x6[_0x5e05[28]],assigned:true,lastAssignedTo:_0x4511x6[_0x5e05[29]],connectedlinenum:_0x4511x6[_0x5e05[30]],connectedlinename:_0x4511x6[_0x5e05[31]]})}})[_0x5e05[11]](function(_0x4511x8){logger[_0x5e05[10]](_0x5e05[27],_0x4511x8)})}},queuecallerjoin:function(_0x4511x6){return function(_0x4511x7){_[_0x5e05[32]](_0x4511x6,{queuecallerjoinAt:_0x4511x6[_0x5e05[12]]});return ReportQueue[_0x5e05[34]](_0x4511x6,{raw:true})[_0x5e05[11]](function(_0x4511x8){logger[_0x5e05[10]](_0x5e05[33],_0x4511x8)})}},queuecallerabandon:function(_0x4511x6){return function(_0x4511x7){return ReportQueue[_0x5e05[17]]({where:{uniqueid:_0x4511x6[_0x5e05[15]],queuecallercomplete:false,$or:{queuecallerexitreason:null,queuecallerexit:false}},order:_0x5e05[16]})[_0x5e05[14]](function(_0x4511x9){if(_0x4511x9){return _0x4511x9[_0x5e05[13]]({queuecallerabandon:true,queuecallerabandonAt:_0x4511x6[_0x5e05[12]],queuecallerleaveAt:_0x4511x6[_0x5e05[12]],queuecallerexit:false,queuecallerexitAt:null,queuecallerexitreason:null,connectedlinenum:null,connectedlinename:null,originalposition:_0x4511x6[_0x5e05[36]],position:_0x4511x6[_0x5e05[37]],holdtime:_0x4511x6[_0x5e05[28]]})}})[_0x5e05[11]](function(_0x4511x8){logger[_0x5e05[10]](_0x5e05[35],_0x4511x8)})}},queuecallerunmanaged:function(_0x4511x6){return function(_0x4511x7){var _0x4511xa={queuecallerabandon:false,queuecallerabandonAt:null,queuecallerexit:true,queuecallerexitAt:_0x4511x6[_0x5e05[12]],connectedlinenum:null,connectedlinename:null,queuecallerleaveAt:_0x4511x6[_0x5e05[12]],queuecallerexitreason:_0x4511x6[_0x5e05[23]]};if(_0x4511x6[_0x5e05[34]]){_0x4511xa[_0x5e05[38]]= _0x4511x6[_0x5e05[12]];return ReportQueue[_0x5e05[34]](_[_0x5e05[32]](_0x4511x6,_0x4511xa))[_0x5e05[11]](function(_0x4511x8){logger[_0x5e05[10]](_0x5e05[39],_0x4511x8)})}else {return ReportQueue[_0x5e05[17]]({where:{uniqueid:_0x4511x6[_0x5e05[15]],queuecallerexitreason:null},order:_0x5e05[16]})[_0x5e05[14]](function(_0x4511x9){if(_0x4511x9){return _0x4511x9[_0x5e05[13]](_0x4511xa)}})[_0x5e05[11]](function(_0x4511x8){logger[_0x5e05[10]](_0x5e05[40],_0x4511x8)})}}},queuecallerleave:function(_0x4511x6){return function(_0x4511x7){var _0x4511xb={queuecallerleaveAt:_0x4511x6[_0x5e05[12]]};return ReportQueue[_0x5e05[17]]({where:{uniqueid:_0x4511x6[_0x5e05[15]],queuecallerleaveAt:null},order:_0x5e05[16]})[_0x5e05[14]](function(_0x4511x9){if(_0x4511x9){return _0x4511x9[_0x5e05[13]](_0x4511xb)}})[_0x5e05[11]](function(_0x4511x8){logger[_0x5e05[10]](_0x5e05[41],_0x4511x8)})}}}}
\ No newline at end of file