Built motion from commit 16cc8f1.|1.0.14
[motion.git] / server / utils / voice_extension.js
index 3429032..68fce91 100644 (file)
@@ -1 +1 @@
-var _0x3389=["\x6C\x6F\x64\x61\x73\x68","\x75\x74\x69\x6C","\x49\x6E\x74\x65\x72\x76\x61\x6C","\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x73\x65\x71\x75\x65\x6C\x69\x7A\x65","\x56\x6F\x69\x63\x65\x45\x78\x74\x65\x6E\x73\x69\x6F\x6E","\x63\x72\x65\x61\x74\x65\x41\x70\x70\x73","\x72\x6F\x75\x74\x65\x55\x70\x64\x61\x74\x65","\x69\x64","\x62\x6F\x64\x79","\x74\x68\x65\x6E","\x41\x70\x70\x6C\x69\x63\x61\x74\x69\x6F\x6E\x73","\x69\x73\x41\x72\x72\x61\x79","\x6C\x65\x6E\x67\x74\x68","\x70\x61\x72\x61\x6D\x73","\x64\x65\x73\x74\x72\x6F\x79","\x75\x70\x64\x61\x74\x65","\x61\x6C\x6C","\x65\x78\x74\x65\x6E","\x74\x79\x70\x65","\x63\x6F\x6E\x74\x65\x78\x74","\x53\x65\x74","\x43\x44\x52\x28\x74\x79\x70\x65\x29\x3D\x25\x73","\x66\x6F\x72\x6D\x61\x74","\x6D\x65\x72\x67\x65","\x70\x75\x73\x68","\x6F\x75\x74\x62\x6F\x75\x6E\x64","\x43\x44\x52\x28\x74\x61\x67\x29\x3D\x25\x73","\x74\x61\x67","\x2D\x2D","\x62\x75\x6C\x6B\x43\x72\x65\x61\x74\x65","\x49\x6E\x74\x65\x72\x76\x61\x6C\x49\x64","\x66\x69\x6C\x74\x65\x72","\x69\x6E\x74\x65\x72\x76\x61\x6C","\x6D\x61\x70","\x2A\x2C\x2A\x2C\x2A\x2C\x2A","\x66\x69\x6E\x64","\x6E\x61\x6D\x65","\x4E\x6F\x4F\x50","\x61\x70\x70","\x20\x41\x70\x70\x6C\x69\x63\x61\x74\x69\x6F\x6E\x20\x53\x74\x61\x72\x74","\x47\x6F\x74\x6F\x49\x66\x54\x69\x6D\x65","\x25\x73\x3F\x25\x73\x2C\x24\x7B\x45\x58\x54\x45\x4E\x7D\x2C\x25\x73\x3A\x25\x73\x2C\x24\x7B\x45\x58\x54\x45\x4E\x7D\x2C\x25\x73","\x66\x6F\x72\x45\x61\x63\x68","\x74\x6F\x4C\x6F\x77\x65\x72\x43\x61\x73\x65","\x64\x69\x61\x6C","\x61\x70\x70\x64\x61\x74\x61","\x43\x41\x4C\x4C\x45\x52\x49\x44\x28\x61\x6C\x6C\x29\x3D\x25\x73","\x53\x6B\x69\x70\x70\x65\x64\x20\x43\x61\x6C\x6C\x65\x72\x49\x44\x20\x53\x65\x74","\x72\x65\x63\x6F\x72\x64","\x4D\x69\x78\x4D\x6F\x6E\x69\x74\x6F\x72","\x24\x7B\x55\x4E\x49\x51\x55\x45\x49\x44\x7D\x2E","\x72\x65\x63\x6F\x72\x64\x69\x6E\x67\x46\x6F\x72\x6D\x61\x74","\x77\x61\x76","\x2C\x61\x62","\x53\x6B\x69\x70\x70\x65\x64\x20\x4D\x69\x78\x4D\x6F\x6E\x69\x74\x6F\x72","\x71\x75\x65\x75\x65","\x61\x70\x70\x54\x79\x70\x65","\x63\x75\x73\x74\x6F\x6D","\x50\x72\x6F\x67\x72\x65\x73\x73","","\x53\x6B\x69\x70\x70\x65\x64\x20\x50\x72\x6F\x67\x72\x65\x73\x73","\x6F\x75\x74\x62\x6F\x75\x6E\x64\x72\x6F\x75\x74\x65\x69\x64\x3D\x25\x64","\x53\x6B\x69\x70\x70\x65\x64\x20\x4F\x75\x74\x6F\x75\x6E\x64\x20\x52\x6F\x75\x74\x65\x20\x49\x64\x20\x53\x65\x74","\x6F\x75\x74\x62\x6F\x75\x6E\x64\x44\x69\x61\x6C","\x78","\x69\x6E\x63\x6C\x75\x64\x65\x73","\x58","\x53\x49\x50\x2F\x25\x73\x2F\x25\x73\x24\x7B\x45\x58\x54\x45\x4E\x3A\x25\x73\x7D\x2C\x25\x73\x2C\x25\x73\x2C\x25\x73","\x63\x75\x74\x64\x69\x67\x69\x74\x73","\x65\x78\x74\x65\x72\x6E\x61\x6C\x44\x69\x61\x6C","\x53\x49\x50\x2F\x25\x73\x2F\x25\x73\x2C\x25\x73\x2C\x25\x73\x2C\x25\x73","\x69\x6E\x74\x65\x72\x6E\x61\x6C\x44\x69\x61\x6C","\x53\x49\x50\x2F\x25\x73\x2C\x25\x73\x2C\x25\x73\x2C\x25\x73","\x2C","\x6A\x6F\x69\x6E","\x53\x74\x6F\x70\x4D\x69\x78\x4D\x6F\x6E\x69\x74\x6F\x72","\x53\x6B\x69\x70\x70\x65\x64\x20\x53\x74\x6F\x70\x4D\x69\x78\x4D\x6F\x6E\x69\x74\x6F\x72","\x20\x41\x70\x70\x6C\x69\x63\x61\x74\x69\x6F\x6E\x20\x45\x6E\x64","\x20\x63\x61\x6C\x6C\x20\x65\x6E\x64","\x69\x6E\x74\x65\x72\x6E\x61\x6C","\x48\x61\x6E\x67\x75\x70","\x66\x69\x6E\x64\x41\x6C\x6C"];var _=require(_0x3389[0]);var util=require(_0x3389[1]);var Interval=require(_0x3389[3])[_0x3389[2]];var sequelize=require(_0x3389[3])[_0x3389[4]];var VoiceExtension=require(_0x3389[3])[_0x3389[5]];exports[_0x3389[6]]= createApplications;exports[_0x3389[7]]= function(_0x8ef8x6,_0x8ef8x7){var sequelize=require(_0x3389[3])[_0x3389[4]];var VoiceExtension=require(_0x3389[3])[_0x3389[5]];if(_0x8ef8x6[_0x3389[9]][_0x3389[8]]){delete _0x8ef8x6[_0x3389[9]][_0x3389[8]]};return VoiceExtension[_0x3389[16]](_0x8ef8x6[_0x3389[9]],{where:{id:_0x8ef8x6[_0x3389[14]][_0x3389[8]]},transaction:_0x8ef8x7})[_0x3389[10]](function(_0x8ef8x8){if(_0x8ef8x6[_0x3389[9]][_0x3389[11]]){_0x8ef8x6[_0x3389[9]][_0x3389[8]]= _0x8ef8x6[_0x3389[14]][_0x3389[8]];return VoiceExtension[_0x3389[15]]({where:{VoiceExtensionId:_0x8ef8x6[_0x3389[14]][_0x3389[8]]},transaction:_0x8ef8x7})}})[_0x3389[10]](function(){if(_0x8ef8x6[_0x3389[9]][_0x3389[11]]&& Array[_0x3389[12]](_0x8ef8x6[_0x3389[9]].Applications)&& _0x8ef8x6[_0x3389[9]][_0x3389[11]][_0x3389[13]]){return _0x8ef8x6[_0x3389[9]]}})[_0x3389[10]](createApplications(_0x8ef8x6[_0x3389[9]].Applications,_0x8ef8x7))};function createApplications(_0x8ef8xa,_0x8ef8x7){var Interval=require(_0x3389[3])[_0x3389[2]];var VoiceExtension=require(_0x3389[3])[_0x3389[5]];return function(_0x8ef8x8){if(_0x8ef8x8){return Interval[_0x3389[82]]()[_0x3389[10]](function(_0x8ef8xb){var _0x8ef8xc=2;var _0x8ef8xd={exten:_0x8ef8x8[_0x3389[18]],type:_0x8ef8x8[_0x3389[19]],context:_0x8ef8x8[_0x3389[20]],VoiceExtensionId:_0x8ef8x8[_0x3389[8]]};var _0x8ef8xe=[];var _0x8ef8xf=7;var _0x8ef8x10=[],_0x8ef8x11=[];_0x8ef8x10[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[21],appdata:util[_0x3389[23]](_0x3389[22],_0x8ef8x8[_0x3389[19]]),priority:_0x8ef8xc},_0x8ef8xd));_0x8ef8xc++;if(_0x8ef8x8[_0x3389[19]]=== _0x3389[26]){_0x8ef8x10[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[21],appdata:util[_0x3389[23]](_0x3389[27],_0x8ef8x8[_0x3389[28]]|| _0x3389[29]),priority:_0x8ef8xc},_0x8ef8xd));_0x8ef8xc++};_0x8ef8xe[_0x3389[25]](VoiceExtension[_0x3389[30]](_0x8ef8x10,{transaction:_0x8ef8x7}));_0x8ef8xa[_0x3389[43]](function(_0x8ef8x12){var _0x8ef8x13=[];var _0x8ef8x14=[];if(_0x8ef8x12[_0x3389[31]]){var _0x8ef8x15=_[_0x3389[32]](_0x8ef8xb,{IntervalId:_0x8ef8x12[_0x3389[31]]});_0x8ef8x13= _0x8ef8x15[_0x3389[13]]?_[_0x3389[34]](_0x8ef8x15,_0x3389[33]):[_0x3389[35]];var _0x8ef8x16=_[_0x3389[36]](_0x8ef8xb,{id:_0x8ef8x12[_0x3389[31]]});_0x8ef8x12[_0x3389[33]]= _0x8ef8x16?_0x8ef8x16[_0x3389[37]]:_0x3389[35]}else {_0x8ef8x13= [_0x8ef8x12[_0x3389[33]]]};_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[38],appdata:_0x8ef8x12[_0x3389[39]]+ _0x3389[40],priority:_0x8ef8xc},_0x8ef8xd));_0x8ef8xc++;var _0x8ef8x17=_0x8ef8x13[_0x3389[13]];_0x8ef8x13[_0x3389[43]](function(_0x8ef8x18,_0x8ef8x19){_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[41],appdata:util[_0x3389[23]](_0x3389[42],_0x8ef8x18,_0x8ef8x8[_0x3389[20]],_0x8ef8xc+ (_0x8ef8x17- _0x8ef8x19),_0x8ef8x8[_0x3389[20]],((_0x8ef8x19+ 1)< _0x8ef8x17)?_0x8ef8xc+ 1:_0x8ef8xc+ _0x8ef8xf),priority:_0x8ef8xc},_0x8ef8xd));_0x8ef8xc++});if(_0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[45]&& _0x8ef8x8[_0x3389[19]]=== _0x3389[26]&& _0x8ef8x12[_0x3389[46]][1]){_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[21],appdata:util[_0x3389[23]](_0x3389[47],_0x8ef8x12[_0x3389[46]][1]),priority:_0x8ef8xc},_0x8ef8xd))}else {_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[38],appdata:_0x3389[48],priority:_0x8ef8xc},_0x8ef8xd))};_0x8ef8xc++;if(_0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[45]&& _0x8ef8x8[_0x3389[49]]&& _0x8ef8x8[_0x3389[19]]=== _0x3389[26]){_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[50],appdata:_0x3389[51]+ (_0x8ef8x8[_0x3389[52]]|| _0x3389[53])+ _0x3389[54],priority:_0x8ef8xc},_0x8ef8xd))}else {_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[38],appdata:_0x3389[55],priority:_0x8ef8xc},_0x8ef8xd))};_0x8ef8xc++;if(_0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[56]&& _0x8ef8x12[_0x3389[57]]!== _0x3389[58]){_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[59],appdata:_0x3389[60],priority:_0x8ef8xc},_0x8ef8xd))}else {_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[38],appdata:_0x3389[61],priority:_0x8ef8xc},_0x8ef8xd))};_0x8ef8xc++;if(_0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[45]&& _0x8ef8x8[_0x3389[19]]=== _0x3389[26]){_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[21],appdata:util[_0x3389[23]](_0x3389[62],_0x8ef8x8[_0x3389[8]]|| _0x3389[60]),priority:_0x8ef8xc},_0x8ef8xd))}else {_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[38],appdata:_0x3389[63],priority:_0x8ef8xc},_0x8ef8xd))};_0x8ef8xc++;if(_0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[45]&& _0x8ef8x12[_0x3389[57]]=== _0x3389[64]){_0x8ef8x12[_0x3389[46]][4]= _0x8ef8x12[_0x3389[46]][4]|| _0x3389[60];_0x8ef8x12[_0x3389[46]][4]+= (_[_0x3389[66]](_0x8ef8x12[_0x3389[46]][4],_0x3389[65])?_0x3389[60]:_0x3389[65])+ (_[_0x3389[66]](_0x8ef8x12[_0x3389[46]][4],_0x3389[67])?_0x3389[60]:_0x3389[67]);_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x8ef8x12[_0x3389[39]],appdata:util[_0x3389[23]](_0x3389[68],_0x8ef8x12[_0x3389[46]][0],_0x8ef8x12[_0x3389[46]][2]|| _0x3389[60],_0x8ef8x8[_0x3389[69]]|| 0,_0x8ef8x12[_0x3389[46]][3]|| _0x3389[60],_0x8ef8x12[_0x3389[46]][4]|| _0x3389[60],_0x8ef8x12[_0x3389[46]][5]|| _0x3389[60]),priority:_0x8ef8xc,IntervalId:_0x8ef8x12[_0x3389[31]]|| null,interval:_0x8ef8x12[_0x3389[33]]|| _0x3389[35],isApp:true,callerID:_0x8ef8x12[_0x3389[46]][1]|| null,appType:_0x8ef8x12[_0x3389[57]]},_0x8ef8xd))}else {if(_0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[45]&& _0x8ef8x12[_0x3389[57]]=== _0x3389[70]){_0x8ef8x12[_0x3389[46]][3]= _0x8ef8x12[_0x3389[46]][3]|| _0x3389[60];_0x8ef8x12[_0x3389[46]][3]+= (_[_0x3389[66]](_0x8ef8x12[_0x3389[46]][3],_0x3389[65])?_0x3389[60]:_0x3389[65])+ (_[_0x3389[66]](_0x8ef8x12[_0x3389[46]][3],_0x3389[67])?_0x3389[60]:_0x3389[67]);_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x8ef8x12[_0x3389[39]],appdata:util[_0x3389[23]](_0x3389[71],_0x8ef8x12[_0x3389[46]][0],_0x8ef8x12[_0x3389[46]][1],_0x8ef8x12[_0x3389[46]][2]|| _0x3389[60],_0x8ef8x12[_0x3389[46]][3]|| _0x3389[60],_0x8ef8x12[_0x3389[46]][4]|| _0x3389[60]),priority:_0x8ef8xc,IntervalId:_0x8ef8x12[_0x3389[31]]|| null,interval:_0x8ef8x12[_0x3389[33]]|| _0x3389[35],isApp:true,appType:_0x8ef8x12[_0x3389[57]]},_0x8ef8xd))}else {if(_0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[45]&& _0x8ef8x12[_0x3389[57]]=== _0x3389[72]){_0x8ef8x12[_0x3389[46]][2]= _0x8ef8x12[_0x3389[46]][2]|| _0x3389[60];_0x8ef8x12[_0x3389[46]][2]+= (_[_0x3389[66]](_0x8ef8x12[_0x3389[46]][2],_0x3389[65])?_0x3389[60]:_0x3389[65])+ (_[_0x3389[66]](_0x8ef8x12[_0x3389[46]][2],_0x3389[67])?_0x3389[60]:_0x3389[67]);_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x8ef8x12[_0x3389[39]],appdata:util[_0x3389[23]](_0x3389[73],_0x8ef8x12[_0x3389[46]][0],_0x8ef8x12[_0x3389[46]][1]|| _0x3389[60],_0x8ef8x12[_0x3389[46]][2]|| _0x3389[60],_0x8ef8x12[_0x3389[46]][3]|| _0x3389[60]),priority:_0x8ef8xc,IntervalId:_0x8ef8x12[_0x3389[31]]|| null,interval:_0x8ef8x12[_0x3389[33]]|| _0x3389[35],isApp:true,appType:_0x8ef8x12[_0x3389[57]]},_0x8ef8xd))}else {if((_0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[45]|| _0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[56])&& _0x8ef8x12[_0x3389[57]]!== _0x3389[58]){var _0x8ef8x1a=_0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[45]?2:1;_0x8ef8x12[_0x3389[46]][_0x8ef8x1a]= _0x8ef8x12[_0x3389[46]][_0x8ef8x1a]|| _0x3389[60];_0x8ef8x12[_0x3389[46]][_0x8ef8x1a]+= (_[_0x3389[66]](_0x8ef8x12[_0x3389[46]][_0x8ef8x1a],_0x3389[65])?_0x3389[60]:_0x3389[65])+ (_[_0x3389[66]](_0x8ef8x12[_0x3389[46]][_0x8ef8x1a],_0x3389[67])?_0x3389[60]:_0x3389[67])};_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x8ef8x12[_0x3389[39]],appdata:_0x8ef8x12[_0x3389[46]][_0x3389[75]](_0x3389[74]),priority:_0x8ef8xc,IntervalId:_0x8ef8x12[_0x3389[31]],interval:_0x8ef8x12[_0x3389[33]]|| _0x3389[35],isApp:true,appType:_0x8ef8x12[_0x3389[57]]|| null},_0x8ef8xd))}}};_0x8ef8xc++;if(_0x8ef8x12[_0x3389[39]][_0x3389[44]]()=== _0x3389[45]&& _0x8ef8x8[_0x3389[49]]&& _0x8ef8x8[_0x3389[19]]=== _0x3389[26]){_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[76],appdata:_0x3389[60],priority:_0x8ef8xc},_0x8ef8xd))}else {_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[38],appdata:_0x3389[77],priority:_0x8ef8xc},_0x8ef8xd))};_0x8ef8xc++;_0x8ef8x14[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[38],appdata:_0x8ef8x12[_0x3389[39]]+ _0x3389[78],priority:_0x8ef8xc},_0x8ef8xd));_0x8ef8xc++;_0x8ef8xe[_0x3389[25]](VoiceExtension[_0x3389[30]](_0x8ef8x14,{transaction:_0x8ef8x7}))});_0x8ef8x11[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[38],appdata:_0x8ef8x8[_0x3389[19]]+ _0x3389[79],priority:_0x8ef8xc},_0x8ef8xd));_0x8ef8xc++;if(_0x8ef8x8[_0x3389[19]]=== _0x3389[80]|| _0x8ef8x8[_0x3389[19]]=== _0x3389[26]){_0x8ef8x11[_0x3389[25]](_[_0x3389[24]]({app:_0x3389[81],appdata:_0x3389[60],priority:_0x8ef8xc},_0x8ef8xd));_0x8ef8xc++};_0x8ef8xe[_0x3389[25]](VoiceExtension[_0x3389[30]](_0x8ef8x11,{transaction:_0x8ef8x7}));return _0x8ef8xe})[_0x3389[17]]()}}}
\ No newline at end of file
+var _0xc457=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x75\x74\x69\x6C","\x49\x6E\x74\x65\x72\x76\x61\x6C","\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x73\x65\x71\x75\x65\x6C\x69\x7A\x65","\x56\x6F\x69\x63\x65\x45\x78\x74\x65\x6E\x73\x69\x6F\x6E","\x63\x72\x65\x61\x74\x65\x41\x70\x70\x73","\x72\x6F\x75\x74\x65\x55\x70\x64\x61\x74\x65","\x69\x64","\x62\x6F\x64\x79","\x74\x68\x65\x6E","\x41\x70\x70\x6C\x69\x63\x61\x74\x69\x6F\x6E\x73","\x69\x73\x41\x72\x72\x61\x79","\x6C\x65\x6E\x67\x74\x68","\x70\x61\x72\x61\x6D\x73","\x64\x65\x73\x74\x72\x6F\x79","\x75\x70\x64\x61\x74\x65","\x61\x6C\x6C","\x65\x78\x74\x65\x6E","\x74\x79\x70\x65","\x63\x6F\x6E\x74\x65\x78\x74","\x53\x65\x74","\x43\x44\x52\x28\x74\x79\x70\x65\x29\x3D\x25\x73","\x66\x6F\x72\x6D\x61\x74","\x6D\x65\x72\x67\x65","\x70\x75\x73\x68","\x6F\x75\x74\x62\x6F\x75\x6E\x64","\x43\x44\x52\x28\x74\x61\x67\x29\x3D\x25\x73","\x74\x61\x67","\x2D\x2D","\x74\x6F\x4C\x6F\x77\x65\x72\x43\x61\x73\x65","\x61\x70\x70","\x61\x67\x69","\x66\x69\x6E\x64","\x56\x4F\x4C\x55\x4D\x45\x28\x52\x58\x29\x3D\x30","\x62\x75\x6C\x6B\x43\x72\x65\x61\x74\x65","\x49\x6E\x74\x65\x72\x76\x61\x6C\x49\x64","\x66\x69\x6C\x74\x65\x72","\x69\x6E\x74\x65\x72\x76\x61\x6C","\x6D\x61\x70","\x2A\x2C\x2A\x2C\x2A\x2C\x2A","\x6E\x61\x6D\x65","\x4E\x6F\x4F\x50","\x20\x41\x70\x70\x6C\x69\x63\x61\x74\x69\x6F\x6E\x20\x53\x74\x61\x72\x74","\x47\x6F\x74\x6F\x49\x66\x54\x69\x6D\x65","\x25\x73\x3F\x25\x73\x2C\x24\x7B\x45\x58\x54\x45\x4E\x7D\x2C\x25\x73\x3A\x25\x73\x2C\x24\x7B\x45\x58\x54\x45\x4E\x7D\x2C\x25\x73","\x66\x6F\x72\x45\x61\x63\x68","\x64\x69\x61\x6C","\x6F\x75\x74\x62\x6F\x75\x6E\x64\x72\x6F\x75\x74\x65\x69\x64\x3D\x25\x64","","\x53\x6B\x69\x70\x70\x65\x64\x20\x4F\x75\x74\x62\x6F\x75\x6E\x64\x20\x52\x6F\x75\x74\x65\x20\x49\x64\x20\x53\x65\x74","\x61\x70\x70\x64\x61\x74\x61","\x43\x41\x4C\x4C\x45\x52\x49\x44\x28\x61\x6C\x6C\x29\x3D\x25\x73","\x53\x6B\x69\x70\x70\x65\x64\x20\x43\x61\x6C\x6C\x65\x72\x49\x44\x20\x53\x65\x74","\x72\x65\x63\x6F\x72\x64","\x4D\x69\x78\x4D\x6F\x6E\x69\x74\x6F\x72","\x24\x7B\x55\x4E\x49\x51\x55\x45\x49\x44\x7D\x2E","\x72\x65\x63\x6F\x72\x64\x69\x6E\x67\x46\x6F\x72\x6D\x61\x74","\x77\x61\x76","\x2C\x61\x62","\x53\x6B\x69\x70\x70\x65\x64\x20\x4D\x69\x78\x4D\x6F\x6E\x69\x74\x6F\x72","\x71\x75\x65\x75\x65","\x61\x70\x70\x54\x79\x70\x65","\x63\x75\x73\x74\x6F\x6D","\x61\x6E\x73\x77\x65\x72","\x50\x72\x6F\x67\x72\x65\x73\x73","\x53\x6B\x69\x70\x70\x65\x64\x20\x50\x72\x6F\x67\x72\x65\x73\x73","\x70\x6C\x61\x79\x62\x61\x63\x6B","\x41\x6E\x73\x77\x65\x72","\x53\x6B\x69\x70\x70\x65\x64\x20\x41\x6E\x73\x77\x65\x72","\x6F\x75\x74\x62\x6F\x75\x6E\x64\x44\x69\x61\x6C","\x78","\x69\x6E\x63\x6C\x75\x64\x65\x73","\x58","\x53\x49\x50\x2F\x25\x73\x2F\x25\x73\x24\x7B\x45\x58\x54\x45\x4E\x3A\x25\x73\x7D\x2C\x25\x73\x2C\x25\x73\x2C\x25\x73","\x63\x75\x74\x64\x69\x67\x69\x74\x73","\x65\x78\x74\x65\x72\x6E\x61\x6C\x44\x69\x61\x6C","\x53\x49\x50\x2F\x25\x73\x2F\x25\x73\x2C\x25\x73\x2C\x25\x73\x2C\x25\x73","\x69\x6E\x74\x65\x72\x6E\x61\x6C\x44\x69\x61\x6C","\x53\x49\x50\x2F\x25\x73\x2C\x25\x73\x2C\x25\x73\x2C\x25\x73","\x2C","\x6A\x6F\x69\x6E","\x53\x74\x6F\x70\x4D\x69\x78\x4D\x6F\x6E\x69\x74\x6F\x72","\x53\x6B\x69\x70\x70\x65\x64\x20\x53\x74\x6F\x70\x4D\x69\x78\x4D\x6F\x6E\x69\x74\x6F\x72","\x20\x41\x70\x70\x6C\x69\x63\x61\x74\x69\x6F\x6E\x20\x45\x6E\x64","\x20\x63\x61\x6C\x6C\x20\x65\x6E\x64","\x69\x6E\x74\x65\x72\x6E\x61\x6C","\x48\x61\x6E\x67\x75\x70","\x66\x69\x6E\x64\x41\x6C\x6C"];_0xc457[0];var _=require(_0xc457[1]);var util=require(_0xc457[2]);var Interval=require(_0xc457[4])[_0xc457[3]];var sequelize=require(_0xc457[4])[_0xc457[5]];var VoiceExtension=require(_0xc457[4])[_0xc457[6]];exports[_0xc457[7]]= createApplications;exports[_0xc457[8]]= function(_0xfd9ax6,_0xfd9ax7){var sequelize=require(_0xc457[4])[_0xc457[5]];var VoiceExtension=require(_0xc457[4])[_0xc457[6]];if(_0xfd9ax6[_0xc457[10]][_0xc457[9]]){delete _0xfd9ax6[_0xc457[10]][_0xc457[9]]};return VoiceExtension[_0xc457[17]](_0xfd9ax6[_0xc457[10]],{where:{id:_0xfd9ax6[_0xc457[15]][_0xc457[9]]},transaction:_0xfd9ax7})[_0xc457[11]](function(_0xfd9ax8){if(_0xfd9ax6[_0xc457[10]][_0xc457[12]]){_0xfd9ax6[_0xc457[10]][_0xc457[9]]= _0xfd9ax6[_0xc457[15]][_0xc457[9]];return VoiceExtension[_0xc457[16]]({where:{VoiceExtensionId:_0xfd9ax6[_0xc457[15]][_0xc457[9]]},transaction:_0xfd9ax7})}})[_0xc457[11]](function(){if(_0xfd9ax6[_0xc457[10]][_0xc457[12]]&& Array[_0xc457[13]](_0xfd9ax6[_0xc457[10]].Applications)&& _0xfd9ax6[_0xc457[10]][_0xc457[12]][_0xc457[14]]){return _0xfd9ax6[_0xc457[10]]}})[_0xc457[11]](createApplications(_0xfd9ax6[_0xc457[10]].Applications,_0xfd9ax7))};function createApplications(_0xfd9axa,_0xfd9ax7){var Interval=require(_0xc457[4])[_0xc457[3]];var VoiceExtension=require(_0xc457[4])[_0xc457[6]];return function(_0xfd9ax8){if(_0xfd9ax8){return Interval[_0xc457[89]]()[_0xc457[11]](function(_0xfd9axb){var _0xfd9axc=false;var _0xfd9axd=false;var _0xfd9axe=2;var _0xfd9axf={exten:_0xfd9ax8[_0xc457[19]],type:_0xfd9ax8[_0xc457[20]],context:_0xfd9ax8[_0xc457[21]],VoiceExtensionId:_0xfd9ax8[_0xc457[9]]};var _0xfd9ax10=[];var _0xfd9ax11=8;var _0xfd9ax12=[],_0xfd9ax13=[];_0xfd9ax12[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[22],appdata:util[_0xc457[24]](_0xc457[23],_0xfd9ax8[_0xc457[20]]),priority:_0xfd9axe},_0xfd9axf));_0xfd9axe++;if(_0xfd9ax8[_0xc457[20]]=== _0xc457[27]){_0xfd9ax12[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[22],appdata:util[_0xc457[24]](_0xc457[28],_0xfd9ax8[_0xc457[29]]|| _0xc457[30]),priority:_0xfd9axe},_0xfd9axf));_0xfd9axe++};var _0xfd9ax14=_[_0xc457[34]](_0xfd9axa,function(_0xfd9ax15){return _0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[33]});if(_0xfd9ax14){_0xfd9ax12[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[22],appdata:_0xc457[35],priority:_0xfd9axe},_0xfd9axf));_0xfd9axe++};_0xfd9ax10[_0xc457[26]](VoiceExtension[_0xc457[36]](_0xfd9ax12,{transaction:_0xfd9ax7}));_0xfd9axa[_0xc457[47]](function(_0xfd9ax15){var _0xfd9ax16=[];var _0xfd9ax17=[];if(_0xfd9ax15[_0xc457[37]]){var _0xfd9ax18=_[_0xc457[38]](_0xfd9axb,{IntervalId:_0xfd9ax15[_0xc457[37]]});_0xfd9ax16= _0xfd9ax18[_0xc457[14]]?_[_0xc457[40]](_0xfd9ax18,_0xc457[39]):[_0xc457[41]];var _0xfd9ax19=_[_0xc457[34]](_0xfd9axb,{id:_0xfd9ax15[_0xc457[37]]});_0xfd9ax15[_0xc457[39]]= _0xfd9ax19?_0xfd9ax19[_0xc457[42]]:_0xc457[41]}else {_0xfd9ax16= [_0xfd9ax15[_0xc457[39]]]};_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[43],appdata:_0xfd9ax15[_0xc457[32]]+ _0xc457[44],priority:_0xfd9axe},_0xfd9axf));_0xfd9axe++;var _0xfd9ax1a=_0xfd9ax16[_0xc457[14]];_0xfd9ax16[_0xc457[47]](function(_0xfd9ax1b,_0xfd9ax1c){_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[45],appdata:util[_0xc457[24]](_0xc457[46],_0xfd9ax1b,_0xfd9ax8[_0xc457[21]],_0xfd9axe+ (_0xfd9ax1a- _0xfd9ax1c),_0xfd9ax8[_0xc457[21]],((_0xfd9ax1c+ 1)< _0xfd9ax1a)?_0xfd9axe+ 1:_0xfd9axe+ _0xfd9ax11),priority:_0xfd9axe},_0xfd9axf));_0xfd9axe++});if(_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[48]&& _0xfd9ax8[_0xc457[20]]=== _0xc457[27]){_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[22],appdata:util[_0xc457[24]](_0xc457[49],_0xfd9ax8[_0xc457[9]]|| _0xc457[50]),priority:_0xfd9axe},_0xfd9axf))}else {_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[43],appdata:_0xc457[51],priority:_0xfd9axe},_0xfd9axf))};_0xfd9axe++;if(_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[48]&& _0xfd9ax8[_0xc457[20]]=== _0xc457[27]&& _0xfd9ax15[_0xc457[52]][1]){_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[22],appdata:util[_0xc457[24]](_0xc457[53],_0xfd9ax15[_0xc457[52]][1]),priority:_0xfd9axe},_0xfd9axf))}else {_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[43],appdata:_0xc457[54],priority:_0xfd9axe},_0xfd9axf))};_0xfd9axe++;if(_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[48]&& _0xfd9ax8[_0xc457[55]]&& _0xfd9ax8[_0xc457[20]]=== _0xc457[27]){_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[56],appdata:_0xc457[57]+ (_0xfd9ax8[_0xc457[58]]|| _0xc457[59])+ _0xc457[60],priority:_0xfd9axe},_0xfd9axf))}else {_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[43],appdata:_0xc457[61],priority:_0xfd9axe},_0xfd9axf))};_0xfd9axe++;if(_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[62]&& _0xfd9ax15[_0xc457[63]]!== _0xc457[64]&&  !_0xfd9ax15[_0xc457[65]]&&  !_0xfd9axd&&  !_0xfd9axc){_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[66],appdata:_0xc457[50],priority:_0xfd9axe},_0xfd9axf));_0xfd9axd= true}else {_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[43],appdata:_0xc457[67],priority:_0xfd9axe},_0xfd9axf))};_0xfd9axe++;if((_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[62]|| _0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[68])&& _0xfd9ax15[_0xc457[63]]!== _0xc457[64]&& _0xfd9ax15[_0xc457[65]]&&  !_0xfd9axc){_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[69],appdata:_0xc457[50],priority:_0xfd9axe},_0xfd9axf));_0xfd9axc= true;_0xfd9axd= true}else {_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[43],appdata:_0xc457[70],priority:_0xfd9axe},_0xfd9axf))};_0xfd9axe++;if(_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[48]&& _0xfd9ax15[_0xc457[63]]=== _0xc457[71]){_0xfd9ax15[_0xc457[52]][4]= _0xfd9ax15[_0xc457[52]][4]|| _0xc457[50];_0xfd9ax15[_0xc457[52]][4]+= (_[_0xc457[73]](_0xfd9ax15[_0xc457[52]][4],_0xc457[72])?_0xc457[50]:_0xc457[72])+ (_[_0xc457[73]](_0xfd9ax15[_0xc457[52]][4],_0xc457[74])?_0xc457[50]:_0xc457[74]);_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xfd9ax15[_0xc457[32]],appdata:util[_0xc457[24]](_0xc457[75],_0xfd9ax15[_0xc457[52]][0],_0xfd9ax15[_0xc457[52]][2]|| _0xc457[50],_0xfd9ax8[_0xc457[76]]|| 0,_0xfd9ax15[_0xc457[52]][3]|| _0xc457[50],_0xfd9ax15[_0xc457[52]][4]|| _0xc457[50],_0xfd9ax15[_0xc457[52]][5]|| _0xc457[50]),priority:_0xfd9axe,IntervalId:_0xfd9ax15[_0xc457[37]]|| null,interval:_0xfd9ax15[_0xc457[39]]|| _0xc457[41],isApp:true,callerID:_0xfd9ax15[_0xc457[52]][1]|| null,appType:_0xfd9ax15[_0xc457[63]]},_0xfd9axf))}else {if(_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[48]&& _0xfd9ax15[_0xc457[63]]=== _0xc457[77]){_0xfd9ax15[_0xc457[52]][3]= _0xfd9ax15[_0xc457[52]][3]|| _0xc457[50];_0xfd9ax15[_0xc457[52]][3]+= (_[_0xc457[73]](_0xfd9ax15[_0xc457[52]][3],_0xc457[72])?_0xc457[50]:_0xc457[72])+ (_[_0xc457[73]](_0xfd9ax15[_0xc457[52]][3],_0xc457[74])?_0xc457[50]:_0xc457[74]);_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xfd9ax15[_0xc457[32]],appdata:util[_0xc457[24]](_0xc457[78],_0xfd9ax15[_0xc457[52]][0],_0xfd9ax15[_0xc457[52]][1],_0xfd9ax15[_0xc457[52]][2]|| _0xc457[50],_0xfd9ax15[_0xc457[52]][3]|| _0xc457[50],_0xfd9ax15[_0xc457[52]][4]|| _0xc457[50]),priority:_0xfd9axe,IntervalId:_0xfd9ax15[_0xc457[37]]|| null,interval:_0xfd9ax15[_0xc457[39]]|| _0xc457[41],isApp:true,appType:_0xfd9ax15[_0xc457[63]]},_0xfd9axf))}else {if(_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[48]&& _0xfd9ax15[_0xc457[63]]=== _0xc457[79]){_0xfd9ax15[_0xc457[52]][2]= _0xfd9ax15[_0xc457[52]][2]|| _0xc457[50];_0xfd9ax15[_0xc457[52]][2]+= (_[_0xc457[73]](_0xfd9ax15[_0xc457[52]][2],_0xc457[72])?_0xc457[50]:_0xc457[72])+ (_[_0xc457[73]](_0xfd9ax15[_0xc457[52]][2],_0xc457[74])?_0xc457[50]:_0xc457[74]);_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xfd9ax15[_0xc457[32]],appdata:util[_0xc457[24]](_0xc457[80],_0xfd9ax15[_0xc457[52]][0],_0xfd9ax15[_0xc457[52]][1]|| _0xc457[50],_0xfd9ax15[_0xc457[52]][2]|| _0xc457[50],_0xfd9ax15[_0xc457[52]][3]|| _0xc457[50]),priority:_0xfd9axe,IntervalId:_0xfd9ax15[_0xc457[37]]|| null,interval:_0xfd9ax15[_0xc457[39]]|| _0xc457[41],isApp:true,appType:_0xfd9ax15[_0xc457[63]]},_0xfd9axf))}else {if((_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[48]|| _0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[62])&& _0xfd9ax15[_0xc457[63]]!== _0xc457[64]){var _0xfd9ax1d=_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[48]?2:1;_0xfd9ax15[_0xc457[52]][_0xfd9ax1d]= _0xfd9ax15[_0xc457[52]][_0xfd9ax1d]|| _0xc457[50];_0xfd9ax15[_0xc457[52]][_0xfd9ax1d]+= (_[_0xc457[73]](_0xfd9ax15[_0xc457[52]][_0xfd9ax1d],_0xc457[72])?_0xc457[50]:_0xc457[72])+ (_[_0xc457[73]](_0xfd9ax15[_0xc457[52]][_0xfd9ax1d],_0xc457[74])?_0xc457[50]:_0xc457[74])};_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xfd9ax15[_0xc457[32]],appdata:_0xfd9ax15[_0xc457[52]][_0xc457[82]](_0xc457[81]),priority:_0xfd9axe,IntervalId:_0xfd9ax15[_0xc457[37]],interval:_0xfd9ax15[_0xc457[39]]|| _0xc457[41],isApp:true,appType:_0xfd9ax15[_0xc457[63]]|| null,answer:_0xfd9ax15[_0xc457[65]]|| false},_0xfd9axf))}}};_0xfd9axe++;if(_0xfd9ax15[_0xc457[32]][_0xc457[31]]()=== _0xc457[48]&& _0xfd9ax8[_0xc457[55]]&& _0xfd9ax8[_0xc457[20]]=== _0xc457[27]){_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[83],appdata:_0xc457[50],priority:_0xfd9axe},_0xfd9axf))}else {_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[43],appdata:_0xc457[84],priority:_0xfd9axe},_0xfd9axf))};_0xfd9axe++;_0xfd9ax17[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[43],appdata:_0xfd9ax15[_0xc457[32]]+ _0xc457[85],priority:_0xfd9axe},_0xfd9axf));_0xfd9axe++;_0xfd9ax10[_0xc457[26]](VoiceExtension[_0xc457[36]](_0xfd9ax17,{transaction:_0xfd9ax7}))});_0xfd9ax13[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[43],appdata:_0xfd9ax8[_0xc457[20]]+ _0xc457[86],priority:_0xfd9axe},_0xfd9axf));_0xfd9axe++;if(_0xfd9ax8[_0xc457[20]]=== _0xc457[87]|| _0xfd9ax8[_0xc457[20]]=== _0xc457[27]){_0xfd9ax13[_0xc457[26]](_[_0xc457[25]]({app:_0xc457[88],appdata:_0xc457[50],priority:_0xfd9axe},_0xfd9axf));_0xfd9axe++};_0xfd9ax10[_0xc457[26]](VoiceExtension[_0xc457[36]](_0xfd9ax13,{transaction:_0xfd9ax7}));return _0xfd9ax10})[_0xc457[18]]()}}}
\ No newline at end of file