Built motion from commit 0630df9.|0.0.136
[motion.git] / server / config / ami / voice_context.js
index b87d453..d1282f4 100644 (file)
@@ -1 +1 @@
-var _0xff4c=["\x56\x6F\x69\x63\x65\x43\x6F\x6E\x74\x65\x78\x74","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x56\x6F\x69\x63\x65\x45\x78\x74\x65\x6E\x73\x69\x6F\x6E","\x66\x73","\x75\x74\x69\x6C","\x70\x61\x74\x68","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x65\x6E\x76\x69\x72\x6F\x6E\x6D\x65\x6E\x74","\x6E\x61\x6D\x65","\x63\x68\x61\x6E\x67\x65\x64","\x59\x6F\x75\x20\x63\x61\x6E\x27\x74\x20\x6D\x6F\x64\x69\x66\x79\x20\x61\x20\x63\x6F\x6E\x74\x65\x78\x74\x20\x6E\x61\x6D\x65","\x64\x65\x66\x61\x75\x6C\x74\x45\x6E\x74\x72\x79","\x59\x6F\x75\x20\x63\x61\x6E\x27\x74\x20\x6D\x6F\x64\x69\x66\x79\x20\x61\x20\x64\x65\x66\x61\x75\x6C\x74\x20\x63\x6F\x6E\x74\x65\x78\x74","\x62\x65\x66\x6F\x72\x65\x55\x70\x64\x61\x74\x65","\x59\x6F\x75\x20\x63\x61\x6E\x27\x74\x20\x64\x65\x6C\x65\x74\x65\x20\x61\x20\x64\x65\x66\x61\x75\x6C\x74\x20\x63\x6F\x6E\x74\x65\x78\x74","\x62\x65\x66\x6F\x72\x65\x44\x65\x6C\x65\x74\x65","\x61\x66\x74\x65\x72\x43\x72\x65\x61\x74\x65","\x61\x66\x74\x65\x72\x44\x65\x6C\x65\x74\x65","","\x5B\x25\x73\x5D\x0A\x69\x6E\x63\x6C\x75\x64\x65\x20\x3D\x3E\x20\x25\x73\x2D\x63\x75\x73\x74\x6F\x6D\x0A\x73\x77\x69\x74\x63\x68\x20\x3D\x3E\x20\x52\x65\x61\x6C\x74\x69\x6D\x65\x0A","\x66\x6F\x72\x6D\x61\x74","\x6C\x6F\x67","\x63\x61\x74\x63\x68","\x66\x6F\x72\x45\x61\x63\x68","\x61\x73\x74\x65\x72\x69\x73\x6B\x43\x6F\x6E\x66","\x65\x78\x74\x65\x6E\x73\x69\x6F\x6E\x73\x5F\x78\x63\x61\x6C\x6C\x79\x5F\x63\x6F\x6E\x74\x65\x78\x74\x73\x2E\x63\x6F\x6E\x66","\x6A\x6F\x69\x6E","\x77","\x30\x37\x37\x37","\x43\x6F\x6E\x74\x65\x78\x74\x73\x20\x66\x69\x6C\x65\x20\x73\x61\x76\x65\x64\x21","\x52\x65\x6C\x6F\x61\x64","\x65\x72\x72\x6F\x72","\x61\x63\x74\x69\x6F\x6E","\x77\x72\x69\x74\x65\x46\x69\x6C\x65","\x74\x68\x65\x6E","\x69\x64","\x66\x69\x6E\x64\x41\x6C\x6C","\x63\x72\x65\x61\x74\x65\x20\x63\x6F\x6E\x74\x65\x78\x74\x20\x68\x61\x6E\x67\x75\x70","\x68","\x31","\x73\x79\x73\x74\x65\x6D","\x48\x61\x6E\x67\x75\x70","\x66\x61\x69\x6C\x65\x64","\x68\x61\x6E\x67\x75\x70\x20\x65\x78\x74\x65\x6E\x73\x69\x6F\x6E\x20\x63\x72\x65\x61\x74\x65\x64","\x62\x75\x6C\x6B\x43\x72\x65\x61\x74\x65","\x65\x78\x70\x6F\x72\x74\x73"];var VoiceContext=require(_0xff4c[1])[_0xff4c[0]];var VoiceExtension=require(_0xff4c[1])[_0xff4c[2]];var fs=require(_0xff4c[3]);var util=require(_0xff4c[4]);var path=require(_0xff4c[5]);var config=require(_0xff4c[6]);function Context(_0x3f97x8){VoiceContext[_0xff4c[12]](function(_0x3f97x9){if(_0x3f97x9[_0xff4c[8]](_0xff4c[7])){throw  new Error(_0xff4c[9])};if(_0x3f97x9[_0xff4c[10]]){throw  new Error(_0xff4c[11])}});VoiceContext[_0xff4c[14]](function(_0x3f97xa){if(_0x3f97xa[_0xff4c[10]]){throw  new Error(_0xff4c[13])}});VoiceContext[_0xff4c[15]](function(_0x3f97xb){rewriteContexts(_0x3f97xb,_0x3f97x8,false);createHangup(_0x3f97xb)});VoiceContext[_0xff4c[16]](function(_0x3f97xb){rewriteContexts(_0x3f97xb,_0x3f97x8,true)})}function rewriteContexts(_0x3f97xb,_0x3f97x8,_0x3f97xd){var _0x3f97xe=_0xff4c[17];if(!_0x3f97xd){_0x3f97xe= util[_0xff4c[19]](_0xff4c[18],_0x3f97xb[_0xff4c[7]],_0x3f97xb[_0xff4c[7]])};VoiceContext[_0xff4c[35]]({where:{id:{$ne:_0x3f97xb[_0xff4c[34]]}}})[_0xff4c[33]](function(_0x3f97x10){_0x3f97x10[_0xff4c[22]](function(_0x3f97x11){_0x3f97xe+= util[_0xff4c[19]](_0xff4c[18],_0x3f97x11[_0xff4c[7]],_0x3f97x11[_0xff4c[7]])});fs[_0xff4c[32]](path[_0xff4c[25]](config[_0xff4c[23]],_0xff4c[24]),_0x3f97xe,{flags:_0xff4c[26],mode:parseInt(_0xff4c[27],8)},function(_0x3f97xf){if(_0x3f97xf){throw _0x3f97xf};console[_0xff4c[20]](_0xff4c[28]);_0x3f97x8[_0xff4c[31]]({Action:_0xff4c[29]},function(_0x3f97xf,_0x3f97x12){if(_0x3f97xf){console[_0xff4c[30]](_0x3f97xf)}else {console[_0xff4c[20]](_0x3f97x12)}})})})[_0xff4c[21]](function(_0x3f97xf){console[_0xff4c[20]](_0x3f97xf)})}function createHangup(_0x3f97xb){console[_0xff4c[20]](_0xff4c[36],_0x3f97xb[_0xff4c[7]]);var _0x3f97x14=[{context:_0x3f97xb[_0xff4c[7]],exten:_0xff4c[37],priority:_0xff4c[38],VoiceContextId:_0x3f97xb[_0xff4c[34]],type:_0xff4c[39],app:_0xff4c[40]},{context:_0x3f97xb[_0xff4c[7]],exten:_0xff4c[41],priority:_0xff4c[38],VoiceContextId:_0x3f97xb[_0xff4c[34]],type:_0xff4c[39],app:_0xff4c[40]}];return VoiceExtension[_0xff4c[43]](_0x3f97x14)[_0xff4c[33]](function(_0x3f97x12){console[_0xff4c[20]](_0xff4c[42])})[_0xff4c[21]](function(_0x3f97xf){console[_0xff4c[20]](_0x3f97xf)})}module[_0xff4c[44]]= Context
\ No newline at end of file
+var _0xd8ec=["\x56\x6F\x69\x63\x65\x43\x6F\x6E\x74\x65\x78\x74","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x56\x6F\x69\x63\x65\x45\x78\x74\x65\x6E\x73\x69\x6F\x6E","\x66\x73","\x75\x74\x69\x6C","\x70\x61\x74\x68","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x65\x6E\x76\x69\x72\x6F\x6E\x6D\x65\x6E\x74","\x6E\x61\x6D\x65","\x63\x68\x61\x6E\x67\x65\x64","\x59\x6F\x75\x20\x63\x61\x6E\x27\x74\x20\x6D\x6F\x64\x69\x66\x79\x20\x61\x20\x63\x6F\x6E\x74\x65\x78\x74\x20\x6E\x61\x6D\x65","\x64\x65\x66\x61\x75\x6C\x74\x45\x6E\x74\x72\x79","\x59\x6F\x75\x20\x63\x61\x6E\x27\x74\x20\x6D\x6F\x64\x69\x66\x79\x20\x61\x20\x64\x65\x66\x61\x75\x6C\x74\x20\x63\x6F\x6E\x74\x65\x78\x74","\x62\x65\x66\x6F\x72\x65\x55\x70\x64\x61\x74\x65","\x59\x6F\x75\x20\x63\x61\x6E\x27\x74\x20\x64\x65\x6C\x65\x74\x65\x20\x61\x20\x64\x65\x66\x61\x75\x6C\x74\x20\x63\x6F\x6E\x74\x65\x78\x74","\x62\x65\x66\x6F\x72\x65\x44\x65\x6C\x65\x74\x65","\x61\x66\x74\x65\x72\x43\x72\x65\x61\x74\x65","\x61\x66\x74\x65\x72\x44\x65\x6C\x65\x74\x65","","\x5B\x25\x73\x5D\x0A\x69\x6E\x63\x6C\x75\x64\x65\x20\x3D\x3E\x20\x25\x73\x2D\x63\x75\x73\x74\x6F\x6D\x0A\x73\x77\x69\x74\x63\x68\x20\x3D\x3E\x20\x52\x65\x61\x6C\x74\x69\x6D\x65\x0A","\x66\x6F\x72\x6D\x61\x74","\x6C\x6F\x67","\x63\x61\x74\x63\x68","\x66\x6F\x72\x45\x61\x63\x68","\x61\x73\x74\x65\x72\x69\x73\x6B\x43\x6F\x6E\x66","\x65\x78\x74\x65\x6E\x73\x69\x6F\x6E\x73\x5F\x78\x63\x61\x6C\x6C\x79\x5F\x63\x6F\x6E\x74\x65\x78\x74\x73\x2E\x63\x6F\x6E\x66","\x6A\x6F\x69\x6E","\x77","\x30\x37\x37\x37","\x43\x6F\x6E\x74\x65\x78\x74\x73\x20\x66\x69\x6C\x65\x20\x73\x61\x76\x65\x64\x21","\x52\x65\x6C\x6F\x61\x64","\x65\x72\x72\x6F\x72","\x61\x63\x74\x69\x6F\x6E","\x77\x72\x69\x74\x65\x46\x69\x6C\x65","\x74\x68\x65\x6E","\x69\x64","\x66\x69\x6E\x64\x41\x6C\x6C","\x63\x72\x65\x61\x74\x65\x20\x63\x6F\x6E\x74\x65\x78\x74\x20\x68\x61\x6E\x67\x75\x70","\x68","\x31","\x73\x79\x73\x74\x65\x6D","\x48\x61\x6E\x67\x75\x70","\x66\x61\x69\x6C\x65\x64","\x68\x61\x6E\x67\x75\x70\x20\x65\x78\x74\x65\x6E\x73\x69\x6F\x6E\x20\x63\x72\x65\x61\x74\x65\x64","\x62\x75\x6C\x6B\x43\x72\x65\x61\x74\x65","\x65\x78\x70\x6F\x72\x74\x73"];var VoiceContext=require(_0xd8ec[1])[_0xd8ec[0]];var VoiceExtension=require(_0xd8ec[1])[_0xd8ec[2]];var fs=require(_0xd8ec[3]);var util=require(_0xd8ec[4]);var path=require(_0xd8ec[5]);var config=require(_0xd8ec[6]);function Context(_0x22c3x8){VoiceContext[_0xd8ec[12]](function(_0x22c3x9){if(_0x22c3x9[_0xd8ec[8]](_0xd8ec[7])){throw  new Error(_0xd8ec[9])};if(_0x22c3x9[_0xd8ec[10]]){throw  new Error(_0xd8ec[11])}});VoiceContext[_0xd8ec[14]](function(_0x22c3xa){if(_0x22c3xa[_0xd8ec[10]]){throw  new Error(_0xd8ec[13])}});VoiceContext[_0xd8ec[15]](function(_0x22c3xb){rewriteContexts(_0x22c3xb,_0x22c3x8,false);createHangup(_0x22c3xb)});VoiceContext[_0xd8ec[16]](function(_0x22c3xb){rewriteContexts(_0x22c3xb,_0x22c3x8,true)})}function rewriteContexts(_0x22c3xb,_0x22c3x8,_0x22c3xd){var _0x22c3xe=_0xd8ec[17];if(!_0x22c3xd){_0x22c3xe= util[_0xd8ec[19]](_0xd8ec[18],_0x22c3xb[_0xd8ec[7]],_0x22c3xb[_0xd8ec[7]])};VoiceContext[_0xd8ec[35]]({where:{id:{$ne:_0x22c3xb[_0xd8ec[34]]}}})[_0xd8ec[33]](function(_0x22c3x10){_0x22c3x10[_0xd8ec[22]](function(_0x22c3x11){_0x22c3xe+= util[_0xd8ec[19]](_0xd8ec[18],_0x22c3x11[_0xd8ec[7]],_0x22c3x11[_0xd8ec[7]])});fs[_0xd8ec[32]](path[_0xd8ec[25]](config[_0xd8ec[23]],_0xd8ec[24]),_0x22c3xe,{flags:_0xd8ec[26],mode:parseInt(_0xd8ec[27],8)},function(_0x22c3xf){if(_0x22c3xf){throw _0x22c3xf};console[_0xd8ec[20]](_0xd8ec[28]);_0x22c3x8[_0xd8ec[31]]({Action:_0xd8ec[29]},function(_0x22c3xf,_0x22c3x12){if(_0x22c3xf){console[_0xd8ec[30]](_0x22c3xf)}else {console[_0xd8ec[20]](_0x22c3x12)}})})})[_0xd8ec[21]](function(_0x22c3xf){console[_0xd8ec[20]](_0x22c3xf)})}function createHangup(_0x22c3xb){console[_0xd8ec[20]](_0xd8ec[36],_0x22c3xb[_0xd8ec[7]]);var _0x22c3x14=[{context:_0x22c3xb[_0xd8ec[7]],exten:_0xd8ec[37],priority:_0xd8ec[38],VoiceContextId:_0x22c3xb[_0xd8ec[34]],type:_0xd8ec[39],app:_0xd8ec[40]},{context:_0x22c3xb[_0xd8ec[7]],exten:_0xd8ec[41],priority:_0xd8ec[38],VoiceContextId:_0x22c3xb[_0xd8ec[34]],type:_0xd8ec[39],app:_0xd8ec[40]}];return VoiceExtension[_0xd8ec[43]](_0x22c3x14)[_0xd8ec[33]](function(_0x22c3x12){console[_0xd8ec[20]](_0xd8ec[42])})[_0xd8ec[21]](function(_0x22c3xf){console[_0xd8ec[20]](_0x22c3xf)})}module[_0xd8ec[44]]= Context
\ No newline at end of file