Built motion from commit ce2081a.|0.0.133
[motion.git] / server / utils / voice_extension.js
index 226e393..4464566 100644 (file)
@@ -1 +1 @@
-var _0x20f5=["\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","\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","\x61\x70\x70\x54\x79\x70\x65","\x6F\x75\x74\x62\x6F\x75\x6E\x64\x44\x69\x61\x6C","\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(_0x20f5[0]);var util=require(_0x20f5[1]);var Interval=require(_0x20f5[3])[_0x20f5[2]];var sequelize=require(_0x20f5[3])[_0x20f5[4]];var VoiceExtension=require(_0x20f5[3])[_0x20f5[5]];exports[_0x20f5[6]]= createApplications;exports[_0x20f5[7]]= function(_0x4515x6,_0x4515x7){var sequelize=require(_0x20f5[3])[_0x20f5[4]];var VoiceExtension=require(_0x20f5[3])[_0x20f5[5]];if(_0x4515x6[_0x20f5[9]][_0x20f5[8]]){delete _0x4515x6[_0x20f5[9]][_0x20f5[8]]};return VoiceExtension[_0x20f5[16]](_0x4515x6[_0x20f5[9]],{where:{id:_0x4515x6[_0x20f5[14]][_0x20f5[8]]},transaction:_0x4515x7})[_0x20f5[10]](function(_0x4515x8){if(_0x4515x6[_0x20f5[9]][_0x20f5[11]]){_0x4515x6[_0x20f5[9]][_0x20f5[8]]= _0x4515x6[_0x20f5[14]][_0x20f5[8]];return VoiceExtension[_0x20f5[15]]({where:{VoiceExtensionId:_0x4515x6[_0x20f5[14]][_0x20f5[8]]},transaction:_0x4515x7})}})[_0x20f5[10]](function(){if(_0x4515x6[_0x20f5[9]][_0x20f5[11]]&& Array[_0x20f5[12]](_0x4515x6[_0x20f5[9]].Applications)&& _0x4515x6[_0x20f5[9]][_0x20f5[11]][_0x20f5[13]]){return _0x4515x6[_0x20f5[9]]}})[_0x20f5[10]](createApplications(_0x4515x6[_0x20f5[9]].Applications,_0x4515x7))};function createApplications(_0x4515xa,_0x4515x7){var Interval=require(_0x20f5[3])[_0x20f5[2]];var VoiceExtension=require(_0x20f5[3])[_0x20f5[5]];return function(_0x4515x8){if(_0x4515x8){return Interval[_0x20f5[79]]()[_0x20f5[10]](function(_0x4515xb){var _0x4515xc=2;var _0x4515xd={exten:_0x4515x8[_0x20f5[18]],type:_0x4515x8[_0x20f5[19]],context:_0x4515x8[_0x20f5[20]],VoiceExtensionId:_0x4515x8[_0x20f5[8]]};var _0x4515xe=[];var _0x4515xf=7;var _0x4515x10=[],_0x4515x11=[];_0x4515x10[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[21],appdata:util[_0x20f5[23]](_0x20f5[22],_0x4515x8[_0x20f5[19]]),priority:_0x4515xc},_0x4515xd));_0x4515xc++;if(_0x4515x8[_0x20f5[19]]=== _0x20f5[26]){_0x4515x10[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[21],appdata:util[_0x20f5[23]](_0x20f5[27],_0x4515x8[_0x20f5[28]]|| _0x20f5[29]),priority:_0x4515xc},_0x4515xd));_0x4515xc++};_0x4515xe[_0x20f5[25]](VoiceExtension[_0x20f5[30]](_0x4515x10,{transaction:_0x4515x7}));_0x4515xa[_0x20f5[43]](function(_0x4515x12){var _0x4515x13=[];var _0x4515x14=[];if(_0x4515x12[_0x20f5[31]]){var _0x4515x15=_[_0x20f5[32]](_0x4515xb,{IntervalId:_0x4515x12[_0x20f5[31]]});_0x4515x13= _0x4515x15[_0x20f5[13]]?_[_0x20f5[34]](_0x4515x15,_0x20f5[33]):[_0x20f5[35]];var _0x4515x16=_[_0x20f5[36]](_0x4515xb,{id:_0x4515x12[_0x20f5[31]]});_0x4515x12[_0x20f5[33]]= _0x4515x16?_0x4515x16[_0x20f5[37]]:_0x20f5[35]}else {_0x4515x13= [_0x4515x12[_0x20f5[33]]]};_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[38],appdata:_0x4515x12[_0x20f5[39]]+ _0x20f5[40],priority:_0x4515xc},_0x4515xd));_0x4515xc++;var _0x4515x17=_0x4515x13[_0x20f5[13]];_0x4515x13[_0x20f5[43]](function(_0x4515x18,_0x4515x19){_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[41],appdata:util[_0x20f5[23]](_0x20f5[42],_0x4515x18,_0x4515x8[_0x20f5[20]],_0x4515xc+ (_0x4515x17- _0x4515x19),_0x4515x8[_0x20f5[20]],((_0x4515x19+ 1)< _0x4515x17)?_0x4515xc+ 1:_0x4515xc+ _0x4515xf),priority:_0x4515xc},_0x4515xd));_0x4515xc++});if(_0x4515x12[_0x20f5[39]][_0x20f5[44]]()=== _0x20f5[45]&& _0x4515x8[_0x20f5[19]]=== _0x20f5[26]&& _0x4515x12[_0x20f5[46]][1]){_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[21],appdata:util[_0x20f5[23]](_0x20f5[47],_0x4515x12[_0x20f5[46]][1]),priority:_0x4515xc},_0x4515xd))}else {_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[38],appdata:_0x20f5[48],priority:_0x4515xc},_0x4515xd))};_0x4515xc++;if(_0x4515x12[_0x20f5[39]][_0x20f5[44]]()=== _0x20f5[45]&& _0x4515x8[_0x20f5[49]]&& _0x4515x8[_0x20f5[19]]=== _0x20f5[26]){_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[50],appdata:_0x20f5[51]+ (_0x4515x8[_0x20f5[52]]|| _0x20f5[53])+ _0x20f5[54],priority:_0x4515xc},_0x4515xd))}else {_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[38],appdata:_0x20f5[55],priority:_0x4515xc},_0x4515xd))};_0x4515xc++;if(_0x4515x12[_0x20f5[39]][_0x20f5[44]]()=== _0x20f5[56]&& _0x4515x12[_0x20f5[39]]!== _0x20f5[57]){_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[58],appdata:_0x20f5[59],priority:_0x4515xc},_0x4515xd))}else {_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[38],appdata:_0x20f5[60],priority:_0x4515xc},_0x4515xd))};_0x4515xc++;if(_0x4515x12[_0x20f5[39]][_0x20f5[44]]()=== _0x20f5[45]&& _0x4515x8[_0x20f5[19]]=== _0x20f5[26]){_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[21],appdata:util[_0x20f5[23]](_0x20f5[61],_0x4515x8[_0x20f5[8]]|| _0x20f5[59]),priority:_0x4515xc},_0x4515xd))}else {_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[38],appdata:_0x20f5[62],priority:_0x4515xc},_0x4515xd))};_0x4515xc++;if(_0x4515x12[_0x20f5[39]][_0x20f5[44]]()=== _0x20f5[45]&& _0x4515x12[_0x20f5[63]]=== _0x20f5[64]){_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x4515x12[_0x20f5[39]],appdata:util[_0x20f5[23]](_0x20f5[65],_0x4515x12[_0x20f5[46]][0],_0x4515x12[_0x20f5[46]][2]|| _0x20f5[59],_0x4515x8[_0x20f5[66]]|| 0,_0x4515x12[_0x20f5[46]][3]|| _0x20f5[59],_0x4515x12[_0x20f5[46]][4]|| _0x20f5[59],_0x4515x12[_0x20f5[46]][5]|| _0x20f5[59]),priority:_0x4515xc,IntervalId:_0x4515x12[_0x20f5[31]]|| null,interval:_0x4515x12[_0x20f5[33]]|| _0x20f5[35],isApp:true,callerID:_0x4515x12[_0x20f5[46]][1]|| null,appType:_0x4515x12[_0x20f5[63]]},_0x4515xd))}else {if(_0x4515x12[_0x20f5[39]][_0x20f5[44]]()=== _0x20f5[45]&& _0x4515x12[_0x20f5[63]]=== _0x20f5[67]){_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x4515x12[_0x20f5[39]],appdata:util[_0x20f5[23]](_0x20f5[68],_0x4515x12[_0x20f5[46]][0],_0x4515x12[_0x20f5[46]][1],_0x4515x12[_0x20f5[46]][2]|| _0x20f5[59],_0x4515x12[_0x20f5[46]][3]|| _0x20f5[59],_0x4515x12[_0x20f5[46]][4]|| _0x20f5[59]),priority:_0x4515xc,IntervalId:_0x4515x12[_0x20f5[31]]|| null,interval:_0x4515x12[_0x20f5[33]]|| _0x20f5[35],isApp:true,appType:_0x4515x12[_0x20f5[63]]},_0x4515xd))}else {if(_0x4515x12[_0x20f5[39]][_0x20f5[44]]()=== _0x20f5[45]&& _0x4515x12[_0x20f5[63]]=== _0x20f5[69]){_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x4515x12[_0x20f5[39]],appdata:util[_0x20f5[23]](_0x20f5[70],_0x4515x12[_0x20f5[46]][0],_0x4515x12[_0x20f5[46]][1]|| _0x20f5[59],_0x4515x12[_0x20f5[46]][2]|| _0x20f5[59],_0x4515x12[_0x20f5[46]][3]|| _0x20f5[59]),priority:_0x4515xc,IntervalId:_0x4515x12[_0x20f5[31]]|| null,interval:_0x4515x12[_0x20f5[33]]|| _0x20f5[35],isApp:true,appType:_0x4515x12[_0x20f5[63]]},_0x4515xd))}else {_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x4515x12[_0x20f5[39]],appdata:_0x4515x12[_0x20f5[46]][_0x20f5[72]](_0x20f5[71]),priority:_0x4515xc,IntervalId:_0x4515x12[_0x20f5[31]],interval:_0x4515x12[_0x20f5[33]]|| _0x20f5[35],isApp:true,appType:_0x4515x12[_0x20f5[63]]|| null},_0x4515xd))}}};_0x4515xc++;if(_0x4515x12[_0x20f5[39]][_0x20f5[44]]()=== _0x20f5[45]&& _0x4515x8[_0x20f5[49]]&& _0x4515x8[_0x20f5[19]]=== _0x20f5[26]){_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[73],appdata:_0x20f5[59],priority:_0x4515xc},_0x4515xd))}else {_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[38],appdata:_0x20f5[74],priority:_0x4515xc},_0x4515xd))};_0x4515xc++;_0x4515x14[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[38],appdata:_0x4515x12[_0x20f5[39]]+ _0x20f5[75],priority:_0x4515xc},_0x4515xd));_0x4515xc++;_0x4515xe[_0x20f5[25]](VoiceExtension[_0x20f5[30]](_0x4515x14,{transaction:_0x4515x7}))});_0x4515x11[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[38],appdata:_0x4515x8[_0x20f5[19]]+ _0x20f5[76],priority:_0x4515xc},_0x4515xd));_0x4515xc++;if(_0x4515x8[_0x20f5[19]]=== _0x20f5[77]|| _0x4515x8[_0x20f5[19]]=== _0x20f5[26]){_0x4515x11[_0x20f5[25]](_[_0x20f5[24]]({app:_0x20f5[78],appdata:_0x20f5[59],priority:_0x4515xc},_0x4515xd));_0x4515xc++};_0x4515xe[_0x20f5[25]](VoiceExtension[_0x20f5[30]](_0x4515x11,{transaction:_0x4515x7}));return _0x4515xe})[_0x20f5[17]]()}}}
\ No newline at end of file
+var _0x3488=["\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","\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","\x61\x70\x70\x54\x79\x70\x65","\x6F\x75\x74\x62\x6F\x75\x6E\x64\x44\x69\x61\x6C","\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(_0x3488[0]);var util=require(_0x3488[1]);var Interval=require(_0x3488[3])[_0x3488[2]];var sequelize=require(_0x3488[3])[_0x3488[4]];var VoiceExtension=require(_0x3488[3])[_0x3488[5]];exports[_0x3488[6]]= createApplications;exports[_0x3488[7]]= function(_0x367ax6,_0x367ax7){var sequelize=require(_0x3488[3])[_0x3488[4]];var VoiceExtension=require(_0x3488[3])[_0x3488[5]];if(_0x367ax6[_0x3488[9]][_0x3488[8]]){delete _0x367ax6[_0x3488[9]][_0x3488[8]]};return VoiceExtension[_0x3488[16]](_0x367ax6[_0x3488[9]],{where:{id:_0x367ax6[_0x3488[14]][_0x3488[8]]},transaction:_0x367ax7})[_0x3488[10]](function(_0x367ax8){if(_0x367ax6[_0x3488[9]][_0x3488[11]]){_0x367ax6[_0x3488[9]][_0x3488[8]]= _0x367ax6[_0x3488[14]][_0x3488[8]];return VoiceExtension[_0x3488[15]]({where:{VoiceExtensionId:_0x367ax6[_0x3488[14]][_0x3488[8]]},transaction:_0x367ax7})}})[_0x3488[10]](function(){if(_0x367ax6[_0x3488[9]][_0x3488[11]]&& Array[_0x3488[12]](_0x367ax6[_0x3488[9]].Applications)&& _0x367ax6[_0x3488[9]][_0x3488[11]][_0x3488[13]]){return _0x367ax6[_0x3488[9]]}})[_0x3488[10]](createApplications(_0x367ax6[_0x3488[9]].Applications,_0x367ax7))};function createApplications(_0x367axa,_0x367ax7){var Interval=require(_0x3488[3])[_0x3488[2]];var VoiceExtension=require(_0x3488[3])[_0x3488[5]];return function(_0x367ax8){if(_0x367ax8){return Interval[_0x3488[79]]()[_0x3488[10]](function(_0x367axb){var _0x367axc=2;var _0x367axd={exten:_0x367ax8[_0x3488[18]],type:_0x367ax8[_0x3488[19]],context:_0x367ax8[_0x3488[20]],VoiceExtensionId:_0x367ax8[_0x3488[8]]};var _0x367axe=[];var _0x367axf=7;var _0x367ax10=[],_0x367ax11=[];_0x367ax10[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[21],appdata:util[_0x3488[23]](_0x3488[22],_0x367ax8[_0x3488[19]]),priority:_0x367axc},_0x367axd));_0x367axc++;if(_0x367ax8[_0x3488[19]]=== _0x3488[26]){_0x367ax10[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[21],appdata:util[_0x3488[23]](_0x3488[27],_0x367ax8[_0x3488[28]]|| _0x3488[29]),priority:_0x367axc},_0x367axd));_0x367axc++};_0x367axe[_0x3488[25]](VoiceExtension[_0x3488[30]](_0x367ax10,{transaction:_0x367ax7}));_0x367axa[_0x3488[43]](function(_0x367ax12){var _0x367ax13=[];var _0x367ax14=[];if(_0x367ax12[_0x3488[31]]){var _0x367ax15=_[_0x3488[32]](_0x367axb,{IntervalId:_0x367ax12[_0x3488[31]]});_0x367ax13= _0x367ax15[_0x3488[13]]?_[_0x3488[34]](_0x367ax15,_0x3488[33]):[_0x3488[35]];var _0x367ax16=_[_0x3488[36]](_0x367axb,{id:_0x367ax12[_0x3488[31]]});_0x367ax12[_0x3488[33]]= _0x367ax16?_0x367ax16[_0x3488[37]]:_0x3488[35]}else {_0x367ax13= [_0x367ax12[_0x3488[33]]]};_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[38],appdata:_0x367ax12[_0x3488[39]]+ _0x3488[40],priority:_0x367axc},_0x367axd));_0x367axc++;var _0x367ax17=_0x367ax13[_0x3488[13]];_0x367ax13[_0x3488[43]](function(_0x367ax18,_0x367ax19){_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[41],appdata:util[_0x3488[23]](_0x3488[42],_0x367ax18,_0x367ax8[_0x3488[20]],_0x367axc+ (_0x367ax17- _0x367ax19),_0x367ax8[_0x3488[20]],((_0x367ax19+ 1)< _0x367ax17)?_0x367axc+ 1:_0x367axc+ _0x367axf),priority:_0x367axc},_0x367axd));_0x367axc++});if(_0x367ax12[_0x3488[39]][_0x3488[44]]()=== _0x3488[45]&& _0x367ax8[_0x3488[19]]=== _0x3488[26]&& _0x367ax12[_0x3488[46]][1]){_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[21],appdata:util[_0x3488[23]](_0x3488[47],_0x367ax12[_0x3488[46]][1]),priority:_0x367axc},_0x367axd))}else {_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[38],appdata:_0x3488[48],priority:_0x367axc},_0x367axd))};_0x367axc++;if(_0x367ax12[_0x3488[39]][_0x3488[44]]()=== _0x3488[45]&& _0x367ax8[_0x3488[49]]&& _0x367ax8[_0x3488[19]]=== _0x3488[26]){_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[50],appdata:_0x3488[51]+ (_0x367ax8[_0x3488[52]]|| _0x3488[53])+ _0x3488[54],priority:_0x367axc},_0x367axd))}else {_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[38],appdata:_0x3488[55],priority:_0x367axc},_0x367axd))};_0x367axc++;if(_0x367ax12[_0x3488[39]][_0x3488[44]]()=== _0x3488[56]&& _0x367ax12[_0x3488[39]]!== _0x3488[57]){_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[58],appdata:_0x3488[59],priority:_0x367axc},_0x367axd))}else {_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[38],appdata:_0x3488[60],priority:_0x367axc},_0x367axd))};_0x367axc++;if(_0x367ax12[_0x3488[39]][_0x3488[44]]()=== _0x3488[45]&& _0x367ax8[_0x3488[19]]=== _0x3488[26]){_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[21],appdata:util[_0x3488[23]](_0x3488[61],_0x367ax8[_0x3488[8]]|| _0x3488[59]),priority:_0x367axc},_0x367axd))}else {_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[38],appdata:_0x3488[62],priority:_0x367axc},_0x367axd))};_0x367axc++;if(_0x367ax12[_0x3488[39]][_0x3488[44]]()=== _0x3488[45]&& _0x367ax12[_0x3488[63]]=== _0x3488[64]){_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x367ax12[_0x3488[39]],appdata:util[_0x3488[23]](_0x3488[65],_0x367ax12[_0x3488[46]][0],_0x367ax12[_0x3488[46]][2]|| _0x3488[59],_0x367ax8[_0x3488[66]]|| 0,_0x367ax12[_0x3488[46]][3]|| _0x3488[59],_0x367ax12[_0x3488[46]][4]|| _0x3488[59],_0x367ax12[_0x3488[46]][5]|| _0x3488[59]),priority:_0x367axc,IntervalId:_0x367ax12[_0x3488[31]]|| null,interval:_0x367ax12[_0x3488[33]]|| _0x3488[35],isApp:true,callerID:_0x367ax12[_0x3488[46]][1]|| null,appType:_0x367ax12[_0x3488[63]]},_0x367axd))}else {if(_0x367ax12[_0x3488[39]][_0x3488[44]]()=== _0x3488[45]&& _0x367ax12[_0x3488[63]]=== _0x3488[67]){_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x367ax12[_0x3488[39]],appdata:util[_0x3488[23]](_0x3488[68],_0x367ax12[_0x3488[46]][0],_0x367ax12[_0x3488[46]][1],_0x367ax12[_0x3488[46]][2]|| _0x3488[59],_0x367ax12[_0x3488[46]][3]|| _0x3488[59],_0x367ax12[_0x3488[46]][4]|| _0x3488[59]),priority:_0x367axc,IntervalId:_0x367ax12[_0x3488[31]]|| null,interval:_0x367ax12[_0x3488[33]]|| _0x3488[35],isApp:true,appType:_0x367ax12[_0x3488[63]]},_0x367axd))}else {if(_0x367ax12[_0x3488[39]][_0x3488[44]]()=== _0x3488[45]&& _0x367ax12[_0x3488[63]]=== _0x3488[69]){_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x367ax12[_0x3488[39]],appdata:util[_0x3488[23]](_0x3488[70],_0x367ax12[_0x3488[46]][0],_0x367ax12[_0x3488[46]][1]|| _0x3488[59],_0x367ax12[_0x3488[46]][2]|| _0x3488[59],_0x367ax12[_0x3488[46]][3]|| _0x3488[59]),priority:_0x367axc,IntervalId:_0x367ax12[_0x3488[31]]|| null,interval:_0x367ax12[_0x3488[33]]|| _0x3488[35],isApp:true,appType:_0x367ax12[_0x3488[63]]},_0x367axd))}else {_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x367ax12[_0x3488[39]],appdata:_0x367ax12[_0x3488[46]][_0x3488[72]](_0x3488[71]),priority:_0x367axc,IntervalId:_0x367ax12[_0x3488[31]],interval:_0x367ax12[_0x3488[33]]|| _0x3488[35],isApp:true,appType:_0x367ax12[_0x3488[63]]|| null},_0x367axd))}}};_0x367axc++;if(_0x367ax12[_0x3488[39]][_0x3488[44]]()=== _0x3488[45]&& _0x367ax8[_0x3488[49]]&& _0x367ax8[_0x3488[19]]=== _0x3488[26]){_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[73],appdata:_0x3488[59],priority:_0x367axc},_0x367axd))}else {_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[38],appdata:_0x3488[74],priority:_0x367axc},_0x367axd))};_0x367axc++;_0x367ax14[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[38],appdata:_0x367ax12[_0x3488[39]]+ _0x3488[75],priority:_0x367axc},_0x367axd));_0x367axc++;_0x367axe[_0x3488[25]](VoiceExtension[_0x3488[30]](_0x367ax14,{transaction:_0x367ax7}))});_0x367ax11[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[38],appdata:_0x367ax8[_0x3488[19]]+ _0x3488[76],priority:_0x367axc},_0x367axd));_0x367axc++;if(_0x367ax8[_0x3488[19]]=== _0x3488[77]|| _0x367ax8[_0x3488[19]]=== _0x3488[26]){_0x367ax11[_0x3488[25]](_[_0x3488[24]]({app:_0x3488[78],appdata:_0x3488[59],priority:_0x367axc},_0x367axd));_0x367axc++};_0x367axe[_0x3488[25]](VoiceExtension[_0x3488[30]](_0x367ax11,{transaction:_0x367ax7}));return _0x367axe})[_0x3488[17]]()}}}
\ No newline at end of file