Built motion from commit 3594e56.|0.0.120
[motion.git] / server / api / voice_context / voice_context.controller.js
index 41bccce..1a2834e 100644 (file)
@@ -1 +1 @@
-var _0xdc87=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x75\x74\x69\x6C","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x73\x65\x71\x75\x65\x6C\x69\x7A\x65","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x56\x6F\x69\x63\x65\x43\x6F\x6E\x74\x65\x78\x74","\x56\x6F\x69\x63\x65\x45\x78\x74\x65\x6E\x73\x69\x6F\x6E","\x69\x6E\x64\x65\x78","\x63\x61\x74\x63\x68","\x73\x65\x6E\x64","\x73\x74\x61\x74\x75\x73","\x74\x68\x65\x6E","\x71\x75\x65\x72\x79","\x67\x65\x74\x51\x75\x65\x72\x79","\x66\x69\x6E\x64\x41\x6E\x64\x43\x6F\x75\x6E\x74\x41\x6C\x6C","\x73\x68\x6F\x77","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x69\x64","\x70\x61\x72\x61\x6D\x73","\x66\x69\x6E\x64\x42\x79\x49\x64","\x63\x6F\x6E\x74\x65\x78\x74\x56\x61\x6C\x69\x64\x61\x74\x69\x6F\x6E","\x6E\x61\x6D\x65","\x62\x6F\x64\x79","\x66\x69\x6E\x64\x41\x6C\x6C","\x63\x72\x65\x61\x74\x65","\x6C\x65\x6E\x67\x74\x68","\x4D\x45\x53\x53\x41\x47\x45\x5F\x45\x58\x49\x53\x54\x5F\x52\x4F\x55\x54\x45","\x75\x70\x64\x61\x74\x65","\x6D\x65\x72\x67\x65","\x73\x61\x76\x65","\x64\x65\x73\x74\x72\x6F\x79","\x65\x72\x72","\x6C\x6F\x67","\x4D\x45\x53\x53\x41\x47\x45\x5F\x43\x4F\x4E\x54\x45\x58\x54\x5F\x52\x4F\x55\x54\x45\x5F\x41\x53\x53\x4F\x43\x49\x41\x54\x45\x44","\x62\x75\x6C\x6B\x44\x65\x73\x74\x72\x6F\x79","\x69\x64\x73","\x64\x61\x74\x61\x56\x61\x6C\x75\x65\x73","\x6D\x61\x70"];_0xdc87[0];var _=require(_0xdc87[1]);var util=require(_0xdc87[2]);var Util=require(_0xdc87[3]);var sequelize=require(_0xdc87[5])[_0xdc87[4]];var VoiceContext=require(_0xdc87[5])[_0xdc87[6]];var VoiceExtension=require(_0xdc87[5])[_0xdc87[7]];exports[_0xdc87[8]]=function(_0x2afcx7,_0x2afcx8,_0x2afcx9){return VoiceContext[_0xdc87[15]](Util[_0xdc87[14]](_0x2afcx7[_0xdc87[13]]))[_0xdc87[12]](function(_0x2afcxb){_0x2afcx8[_0xdc87[11]](200)[_0xdc87[10]](_0x2afcxb)})[_0xdc87[9]](function(_0x2afcxa){return handleError(_0x2afcx8,_0x2afcxa)})};exports[_0xdc87[16]]=function(_0x2afcx7,_0x2afcx8){return VoiceContext[_0xdc87[20]](_0x2afcx7[_0xdc87[19]][_0xdc87[18]])[_0xdc87[12]](function(_0x2afcxc){if(!_0x2afcxc){return _0x2afcx8[_0xdc87[17]](404)};return _0x2afcx8[_0xdc87[10]](_0x2afcxc)})[_0xdc87[9]](function(_0x2afcxa){return handleError(_0x2afcx8,_0x2afcxa)})};exports[_0xdc87[21]]=function(_0x2afcx7,_0x2afcx8){return VoiceContext[_0xdc87[24]]({where:{name:_0x2afcx7[_0xdc87[23]][_0xdc87[22]]}})[_0xdc87[12]](function(_0x2afcxd){if(!_0x2afcxd){return _0x2afcx8[_0xdc87[17]](404)};return _0x2afcx8[_0xdc87[10]](_0x2afcxd)})[_0xdc87[9]](function(_0x2afcxa){return handleError(_0x2afcx8,_0x2afcxa)})};exports[_0xdc87[25]]=function(_0x2afcx7,_0x2afcx8){return VoiceContext[_0xdc87[24]]({where:{name:_0x2afcx7[_0xdc87[23]][_0xdc87[22]]}})[_0xdc87[12]](function(_0x2afcxe){if(!_0x2afcxe){return _0x2afcx8[_0xdc87[17]](404)};if(_0x2afcxe[_0xdc87[26]]>0){return _0x2afcx8[_0xdc87[11]](500)[_0xdc87[10]]({message:_0xdc87[27]})};return VoiceContext[_0xdc87[25]](_0x2afcx7[_0xdc87[23]],{include:[{model:VoiceExtension}]})})[_0xdc87[12]](function(_0x2afcxc){return _0x2afcx8[_0xdc87[11]](201)[_0xdc87[10]](_0x2afcxc)})[_0xdc87[9]](function(_0x2afcxa){return handleError(_0x2afcx8,_0x2afcxa)})};exports[_0xdc87[28]]=function(_0x2afcx7,_0x2afcx8){return VoiceContext[_0xdc87[24]]({where:{name:_0x2afcx7[_0xdc87[23]][_0xdc87[22]],id:{$ne:_0x2afcx7[_0xdc87[23]][_0xdc87[18]]}}})[_0xdc87[12]](function(_0x2afcxe){if(!_0x2afcxe){return _0x2afcx8[_0xdc87[17]](404)};if(_0x2afcxe[_0xdc87[26]]>0){return _0x2afcx8[_0xdc87[11]](500)[_0xdc87[10]]({message:_0xdc87[27]})};if(_0x2afcx7[_0xdc87[23]][_0xdc87[18]]){delete _0x2afcx7[_0xdc87[23]][_0xdc87[18]]};return VoiceContext[_0xdc87[20]](_0x2afcx7[_0xdc87[19]][_0xdc87[18]])})[_0xdc87[12]](function(_0x2afcxc){if(!_0x2afcxc){return _0x2afcx8[_0xdc87[17]](404)};var _0x2afcxf=_[_0xdc87[29]](_0x2afcxc,_0x2afcx7[_0xdc87[23]]);return _0x2afcxf[_0xdc87[30]]()})[_0xdc87[12]](function(_0x2afcxc){return _0x2afcx8[_0xdc87[11]](200)[_0xdc87[10]](_0x2afcxc)})[_0xdc87[9]](function(_0x2afcxa){return handleError(_0x2afcx8,_0x2afcxa)})};exports[_0xdc87[31]]=function(_0x2afcx7,_0x2afcx8){var _0x2afcx10;return VoiceContext[_0xdc87[20]](_0x2afcx7[_0xdc87[19]][_0xdc87[18]])[_0xdc87[12]](function(_0x2afcxc){_0x2afcx10=_0x2afcxc;if(!_0x2afcx10){return _0x2afcx8[_0xdc87[17]](404)};return VoiceExtension[_0xdc87[24]]({where:{context:_0x2afcx10[_0xdc87[22]],VoiceContextId:null}})})[_0xdc87[12]](function(_0x2afcx11){console[_0xdc87[33]](_0x2afcx11);if(_0x2afcx11[_0xdc87[26]]>0){return _0x2afcx8[_0xdc87[11]](500)[_0xdc87[10]]({message:_0xdc87[34]})};return _0x2afcx10[_0xdc87[31]]()})[_0xdc87[12]](function(){return _0x2afcx8[_0xdc87[17]](204)})[_0xdc87[9]](function(_0x2afcxa){console[_0xdc87[33]](_0xdc87[32],_0x2afcxa);return handleError(_0x2afcx8,_0x2afcxa)})};exports[_0xdc87[35]]=function(_0x2afcx7,_0x2afcx8){var _0x2afcx12;return VoiceContext[_0xdc87[24]]({where:{id:_0x2afcx7[_0xdc87[13]][_0xdc87[36]]}})[_0xdc87[12]](function(_0x2afcxd){_0x2afcx12=_0x2afcxd;if(!_0x2afcx12){return _0x2afcx8[_0xdc87[17]](404)};var _0x2afcx13=_[_0xdc87[38]](_[_0xdc87[38]](_0x2afcx12,_0xdc87[37]),_0xdc87[22]);return VoiceExtension[_0xdc87[24]]({where:{context:_0x2afcx13}})})[_0xdc87[12]](function(_0x2afcx11){if(_0x2afcx11[_0xdc87[26]]>_0x2afcx12[_0xdc87[26]]){return _0x2afcx8[_0xdc87[11]](500)[_0xdc87[10]]({message:_0xdc87[34]})};return VoiceContext[_0xdc87[31]]({where:{id:_0x2afcx7[_0xdc87[13]][_0xdc87[36]]},individualHooks:true})})[_0xdc87[12]](function(){return _0x2afcx8[_0xdc87[17]](204)})[_0xdc87[9]](function(_0x2afcxa){return handleError(_0x2afcx8,_0x2afcxa)})};function handleError(_0x2afcx8,_0x2afcxa){return _0x2afcx8[_0xdc87[11]](500)[_0xdc87[10]](_0x2afcxa)}
\ No newline at end of file
+var _0x2ce0=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x75\x74\x69\x6C","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x73\x65\x71\x75\x65\x6C\x69\x7A\x65","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x56\x6F\x69\x63\x65\x43\x6F\x6E\x74\x65\x78\x74","\x56\x6F\x69\x63\x65\x45\x78\x74\x65\x6E\x73\x69\x6F\x6E","\x69\x6E\x64\x65\x78","\x63\x61\x74\x63\x68","\x73\x65\x6E\x64","\x73\x74\x61\x74\x75\x73","\x74\x68\x65\x6E","\x71\x75\x65\x72\x79","\x67\x65\x74\x51\x75\x65\x72\x79","\x66\x69\x6E\x64\x41\x6E\x64\x43\x6F\x75\x6E\x74\x41\x6C\x6C","\x73\x68\x6F\x77","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x69\x64","\x70\x61\x72\x61\x6D\x73","\x66\x69\x6E\x64\x42\x79\x49\x64","\x63\x6F\x6E\x74\x65\x78\x74\x56\x61\x6C\x69\x64\x61\x74\x69\x6F\x6E","\x6E\x61\x6D\x65","\x62\x6F\x64\x79","\x66\x69\x6E\x64\x41\x6C\x6C","\x63\x72\x65\x61\x74\x65","\x6D\x65\x73\x73\x61\x67\x65","\x54\x68\x65\x20\x63\x6F\x6E\x74\x65\x78\x74\x20\x6E\x61\x6D\x65\x20\x61\x6C\x72\x65\x61\x64\x79\x20\x65\x78\x69\x73\x74\x73","\x74\x72\x61\x6E\x73\x6C\x61\x74\x65\x64\x4D\x65\x73\x73\x61\x67\x65","\x4D\x45\x53\x53\x41\x47\x45\x5F\x45\x58\x49\x53\x54\x5F\x43\x4F\x4E\x54\x45\x58\x54","\x75\x70\x64\x61\x74\x65","\x6D\x65\x72\x67\x65","\x73\x61\x76\x65","\x6C\x65\x6E\x67\x74\x68","\x64\x65\x73\x74\x72\x6F\x79","\x65\x72\x72","\x6C\x6F\x67","\x54\x68\x65\x20\x63\x6F\x6E\x74\x65\x78\x74\x20\x69\x73\x20\x61\x73\x73\x6F\x63\x69\x61\x74\x65\x64\x20\x74\x6F\x20\x61\x20\x72\x6F\x75\x74\x65\x2C\x20\x64\x65\x6C\x65\x74\x65\x20\x6F\x72\x20\x63\x68\x61\x6E\x67\x65\x20\x69\x74\x20\x66\x69\x72\x73\x74","\x4D\x45\x53\x53\x41\x47\x45\x5F\x43\x4F\x4E\x54\x45\x58\x54\x5F\x52\x4F\x55\x54\x45\x5F\x41\x53\x53\x4F\x43\x49\x41\x54\x45\x44","\x64\x65\x66\x61\x75\x6C\x74\x45\x6E\x74\x72\x79","\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\x65\x6E\x74\x72\x79\x21","\x4D\x45\x53\x53\x41\x47\x45\x5F\x44\x45\x46\x41\x55\x4C\x54\x5F\x45\x4E\x54\x52\x59","\x62\x75\x6C\x6B\x44\x65\x73\x74\x72\x6F\x79","\x69\x64\x73","\x66\x69\x6E\x64","\x64\x61\x74\x61\x56\x61\x6C\x75\x65\x73","\x6D\x61\x70"];_0x2ce0[0];var _=require(_0x2ce0[1]);var util=require(_0x2ce0[2]);var Util=require(_0x2ce0[3]);var sequelize=require(_0x2ce0[5])[_0x2ce0[4]];var VoiceContext=require(_0x2ce0[5])[_0x2ce0[6]];var VoiceExtension=require(_0x2ce0[5])[_0x2ce0[7]];exports[_0x2ce0[8]]= function(_0xa37dx7,_0xa37dx8,_0xa37dx9){return VoiceContext[_0x2ce0[15]](Util[_0x2ce0[14]](_0xa37dx7[_0x2ce0[13]]))[_0x2ce0[12]](function(_0xa37dxb){_0xa37dx8[_0x2ce0[11]](200)[_0x2ce0[10]](_0xa37dxb)})[_0x2ce0[9]](function(_0xa37dxa){return handleError(_0xa37dx8,_0xa37dxa)})};exports[_0x2ce0[16]]= function(_0xa37dx7,_0xa37dx8){return VoiceContext[_0x2ce0[20]](_0xa37dx7[_0x2ce0[19]][_0x2ce0[18]])[_0x2ce0[12]](function(_0xa37dxc){if(!_0xa37dxc){return _0xa37dx8[_0x2ce0[17]](404)};return _0xa37dx8[_0x2ce0[10]](_0xa37dxc)})[_0x2ce0[9]](function(_0xa37dxa){return handleError(_0xa37dx8,_0xa37dxa)})};exports[_0x2ce0[21]]= function(_0xa37dx7,_0xa37dx8){return VoiceContext[_0x2ce0[24]]({where:{name:_0xa37dx7[_0x2ce0[23]][_0x2ce0[22]]}})[_0x2ce0[12]](function(_0xa37dxd){if(!_0xa37dxd){return _0xa37dx8[_0x2ce0[17]](404)};return _0xa37dx8[_0x2ce0[10]](_0xa37dxd)})[_0x2ce0[9]](function(_0xa37dxa){return handleError(_0xa37dx8,_0xa37dxa)})};exports[_0x2ce0[25]]= function(_0xa37dx7,_0xa37dx8){return VoiceContext[_0x2ce0[25]](_0xa37dx7[_0x2ce0[23]])[_0x2ce0[12]](function(_0xa37dxc){return _0xa37dx8[_0x2ce0[11]](201)[_0x2ce0[10]](_0xa37dxc)})[_0x2ce0[9]](sequelize.UniqueConstraintError,function(_0xa37dxa){_0xa37dxa[_0x2ce0[26]]= _0x2ce0[27];_0xa37dxa[_0x2ce0[28]]= _0x2ce0[29];return handleError(_0xa37dx8,_0xa37dxa)})[_0x2ce0[9]](function(_0xa37dxa){return handleError(_0xa37dx8,_0xa37dxa)})};exports[_0x2ce0[30]]= function(_0xa37dx7,_0xa37dx8){return VoiceContext[_0x2ce0[24]]({where:{name:_0xa37dx7[_0x2ce0[23]][_0x2ce0[22]],id:{$ne:_0xa37dx7[_0x2ce0[23]][_0x2ce0[18]]}}})[_0x2ce0[12]](function(_0xa37dxf){if(!_0xa37dxf){return _0xa37dx8[_0x2ce0[17]](404)};if(_0xa37dxf[_0x2ce0[33]]> 0){return _0xa37dx8[_0x2ce0[11]](500)[_0x2ce0[10]]({message:_0x2ce0[29]})};if(_0xa37dx7[_0x2ce0[23]][_0x2ce0[18]]){delete _0xa37dx7[_0x2ce0[23]][_0x2ce0[18]]};return VoiceContext[_0x2ce0[20]](_0xa37dx7[_0x2ce0[19]][_0x2ce0[18]])})[_0x2ce0[12]](function(_0xa37dxc){if(!_0xa37dxc){return _0xa37dx8[_0x2ce0[17]](404)};var _0xa37dxe=_[_0x2ce0[31]](_0xa37dxc,_0xa37dx7[_0x2ce0[23]]);return _0xa37dxe[_0x2ce0[32]]()})[_0x2ce0[12]](function(_0xa37dxc){return _0xa37dx8[_0x2ce0[11]](200)[_0x2ce0[10]](_0xa37dxc)})[_0x2ce0[9]](function(_0xa37dxa){return handleError(_0xa37dx8,_0xa37dxa)})};exports[_0x2ce0[34]]= function(_0xa37dx7,_0xa37dx8){var _0xa37dx10;return VoiceContext[_0x2ce0[20]](_0xa37dx7[_0x2ce0[19]][_0x2ce0[18]])[_0x2ce0[12]](function(_0xa37dxc){_0xa37dx10= _0xa37dxc;if(!_0xa37dx10){return _0xa37dx8[_0x2ce0[17]](404)};if(_0xa37dx10[_0x2ce0[39]]){return _0xa37dx8[_0x2ce0[11]](500)[_0x2ce0[10]]({message:_0x2ce0[40],translatedMessage:_0x2ce0[41]})};return VoiceExtension[_0x2ce0[24]]({where:{context:_0xa37dx10[_0x2ce0[22]],VoiceContextId:null}})})[_0x2ce0[12]](function(_0xa37dx11){console[_0x2ce0[36]](_0xa37dx11);if(_0xa37dx11[_0x2ce0[33]]> 0){return _0xa37dx8[_0x2ce0[11]](500)[_0x2ce0[10]]({message:_0x2ce0[37],translatedMessage:_0x2ce0[38]})};return _0xa37dx10[_0x2ce0[34]]()})[_0x2ce0[12]](function(){return _0xa37dx8[_0x2ce0[17]](204)})[_0x2ce0[9]](function(_0xa37dxa){console[_0x2ce0[36]](_0x2ce0[35],_0xa37dxa);return handleError(_0xa37dx8,_0xa37dxa)})};exports[_0x2ce0[42]]= function(_0xa37dx7,_0xa37dx8){var _0xa37dx12;return VoiceContext[_0x2ce0[24]]({where:{id:_0xa37dx7[_0x2ce0[13]][_0x2ce0[43]]}})[_0x2ce0[12]](function(_0xa37dxd){_0xa37dx12= _0xa37dxd;var _0xa37dx13=_[_0x2ce0[44]](_0xa37dx12,{defaultEntry:true});if(_0xa37dx13){return _0xa37dx8[_0x2ce0[11]](500)[_0x2ce0[10]]({message:_0x2ce0[40],translatedMessage:_0x2ce0[41]})};if(!_0xa37dx12){return _0xa37dx8[_0x2ce0[17]](404)};var _0xa37dx14=_[_0x2ce0[46]](_[_0x2ce0[46]](_0xa37dx12,_0x2ce0[45]),_0x2ce0[22]);return VoiceExtension[_0x2ce0[24]]({where:{context:_0xa37dx14,VoiceContextId:null}})})[_0x2ce0[12]](function(_0xa37dx11){if(_0xa37dx11[_0x2ce0[33]]> _0xa37dx12[_0x2ce0[33]]){return _0xa37dx8[_0x2ce0[11]](500)[_0x2ce0[10]]({message:_0x2ce0[37],translatedMessage:_0x2ce0[38]})};return VoiceContext[_0x2ce0[34]]({where:{id:_0xa37dx7[_0x2ce0[13]][_0x2ce0[43]]},individualHooks:true})})[_0x2ce0[12]](function(){return _0xa37dx8[_0x2ce0[17]](204)})[_0x2ce0[9]](function(_0xa37dxa){console[_0x2ce0[36]](_0xa37dxa);return handleError(_0xa37dx8,_0xa37dxa)})};function handleError(_0xa37dx8,_0xa37dxa){return _0xa37dx8[_0x2ce0[11]](500)[_0x2ce0[10]](_0xa37dxa)}
\ No newline at end of file