Built motion from commit d9055ebe5.|1.0.37
[motion.git] / server / api / voice_context / voice_context.controller.js
index db1c1f0..907f7ef 100644 (file)
@@ -1 +1 @@
-var _0xb7f8=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x75\x74\x69\x6C","\x61\x70\x69","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x6C\x6F\x67\x67\x65\x72\x2E\x6A\x73","\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","\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","\x73\x74\x61\x63\x6B","\x65\x72\x72\x6F\x72"];_0xb7f8[0];var _=require(_0xb7f8[1]);var util=require(_0xb7f8[2]);var logger=require(_0xb7f8[4])(_0xb7f8[3]);var Util=require(_0xb7f8[5]);var sequelize=require(_0xb7f8[7])[_0xb7f8[6]];var VoiceContext=require(_0xb7f8[7])[_0xb7f8[8]];var VoiceExtension=require(_0xb7f8[7])[_0xb7f8[9]];exports[_0xb7f8[10]]= function(_0xf7aax8,_0xf7aax9,_0xf7aaxa){return VoiceContext[_0xb7f8[17]](Util[_0xb7f8[16]](_0xf7aax8[_0xb7f8[15]]))[_0xb7f8[14]](function(_0xf7aaxc){_0xf7aax9[_0xb7f8[13]](200)[_0xb7f8[12]](_0xf7aaxc)})[_0xb7f8[11]](function(_0xf7aaxb){return handleError(_0xf7aax9,_0xf7aaxb)})};exports[_0xb7f8[18]]= function(_0xf7aax8,_0xf7aax9){return VoiceContext[_0xb7f8[22]](_0xf7aax8[_0xb7f8[21]][_0xb7f8[20]])[_0xb7f8[14]](function(_0xf7aaxd){if(!_0xf7aaxd){return _0xf7aax9[_0xb7f8[19]](404)};return _0xf7aax9[_0xb7f8[12]](_0xf7aaxd)})[_0xb7f8[11]](function(_0xf7aaxb){return handleError(_0xf7aax9,_0xf7aaxb)})};exports[_0xb7f8[23]]= function(_0xf7aax8,_0xf7aax9){return VoiceContext[_0xb7f8[26]]({where:{name:_0xf7aax8[_0xb7f8[25]][_0xb7f8[24]]}})[_0xb7f8[14]](function(_0xf7aaxe){if(!_0xf7aaxe){return _0xf7aax9[_0xb7f8[19]](404)};return _0xf7aax9[_0xb7f8[12]](_0xf7aaxe)})[_0xb7f8[11]](function(_0xf7aaxb){return handleError(_0xf7aax9,_0xf7aaxb)})};exports[_0xb7f8[27]]= function(_0xf7aax8,_0xf7aax9){return VoiceContext[_0xb7f8[27]](_0xf7aax8[_0xb7f8[25]])[_0xb7f8[14]](function(_0xf7aaxd){return _0xf7aax9[_0xb7f8[13]](201)[_0xb7f8[12]](_0xf7aaxd)})[_0xb7f8[11]](sequelize.UniqueConstraintError,function(_0xf7aaxb){_0xf7aaxb[_0xb7f8[28]]= _0xb7f8[29];_0xf7aaxb[_0xb7f8[30]]= _0xb7f8[31];return handleError(_0xf7aax9,_0xf7aaxb)})[_0xb7f8[11]](function(_0xf7aaxb){return handleError(_0xf7aax9,_0xf7aaxb)})};exports[_0xb7f8[32]]= function(_0xf7aax8,_0xf7aax9){return VoiceContext[_0xb7f8[26]]({where:{name:_0xf7aax8[_0xb7f8[25]][_0xb7f8[24]],id:{$ne:_0xf7aax8[_0xb7f8[25]][_0xb7f8[20]]}}})[_0xb7f8[14]](function(_0xf7aax10){if(!_0xf7aax10){return _0xf7aax9[_0xb7f8[19]](404)};if(_0xf7aax10[_0xb7f8[35]]> 0){return _0xf7aax9[_0xb7f8[13]](500)[_0xb7f8[12]]({message:_0xb7f8[31]})};if(_0xf7aax8[_0xb7f8[25]][_0xb7f8[20]]){delete _0xf7aax8[_0xb7f8[25]][_0xb7f8[20]]};return VoiceContext[_0xb7f8[22]](_0xf7aax8[_0xb7f8[21]][_0xb7f8[20]])})[_0xb7f8[14]](function(_0xf7aaxd){if(!_0xf7aaxd){return _0xf7aax9[_0xb7f8[19]](404)};var _0xf7aaxf=_[_0xb7f8[33]](_0xf7aaxd,_0xf7aax8[_0xb7f8[25]]);return _0xf7aaxf[_0xb7f8[34]]()})[_0xb7f8[14]](function(_0xf7aaxd){return _0xf7aax9[_0xb7f8[13]](200)[_0xb7f8[12]](_0xf7aaxd)})[_0xb7f8[11]](function(_0xf7aaxb){return handleError(_0xf7aax9,_0xf7aaxb)})};exports[_0xb7f8[36]]= function(_0xf7aax8,_0xf7aax9){var _0xf7aax11;return VoiceContext[_0xb7f8[22]](_0xf7aax8[_0xb7f8[21]][_0xb7f8[20]])[_0xb7f8[14]](function(_0xf7aaxd){_0xf7aax11= _0xf7aaxd;if(!_0xf7aax11){return _0xf7aax9[_0xb7f8[19]](404)};if(_0xf7aax11[_0xb7f8[39]]){return _0xf7aax9[_0xb7f8[13]](500)[_0xb7f8[12]]({message:_0xb7f8[40],translatedMessage:_0xb7f8[41]})};return VoiceExtension[_0xb7f8[26]]({where:{context:_0xf7aax11[_0xb7f8[24]],VoiceContextId:null}})})[_0xb7f8[14]](function(_0xf7aax12){if(_0xf7aax12[_0xb7f8[35]]> 0){return _0xf7aax9[_0xb7f8[13]](500)[_0xb7f8[12]]({message:_0xb7f8[37],translatedMessage:_0xb7f8[38]})};return _0xf7aax11[_0xb7f8[36]]()})[_0xb7f8[14]](function(){return _0xf7aax9[_0xb7f8[19]](204)})[_0xb7f8[11]](function(_0xf7aaxb){return handleError(_0xf7aax9,_0xf7aaxb)})};exports[_0xb7f8[42]]= function(_0xf7aax8,_0xf7aax9){var _0xf7aax13;return VoiceContext[_0xb7f8[26]]({where:{id:_0xf7aax8[_0xb7f8[15]][_0xb7f8[43]]}})[_0xb7f8[14]](function(_0xf7aaxe){_0xf7aax13= _0xf7aaxe;var _0xf7aax14=_[_0xb7f8[44]](_0xf7aax13,{defaultEntry:true});if(_0xf7aax14){return _0xf7aax9[_0xb7f8[13]](500)[_0xb7f8[12]]({message:_0xb7f8[40],translatedMessage:_0xb7f8[41]})};if(!_0xf7aax13){return _0xf7aax9[_0xb7f8[19]](404)};var _0xf7aax15=_[_0xb7f8[46]](_[_0xb7f8[46]](_0xf7aax13,_0xb7f8[45]),_0xb7f8[24]);return VoiceExtension[_0xb7f8[26]]({where:{context:_0xf7aax15,VoiceContextId:null}})})[_0xb7f8[14]](function(_0xf7aax12){if(_0xf7aax12[_0xb7f8[35]]> _0xf7aax13[_0xb7f8[35]]){return _0xf7aax9[_0xb7f8[13]](500)[_0xb7f8[12]]({message:_0xb7f8[37],translatedMessage:_0xb7f8[38]})};return VoiceContext[_0xb7f8[36]]({where:{id:_0xf7aax8[_0xb7f8[15]][_0xb7f8[43]]},individualHooks:true})})[_0xb7f8[14]](function(){return _0xf7aax9[_0xb7f8[19]](204)})[_0xb7f8[11]](function(_0xf7aaxb){return handleError(_0xf7aax9,_0xf7aaxb)})};function handleError(_0xf7aax9,_0xf7aaxb){logger[_0xb7f8[48]](_0xf7aaxb[_0xb7f8[47]]);return _0xf7aax9[_0xb7f8[13]](500)[_0xb7f8[12]](_0xf7aaxb)}
\ No newline at end of file
+var _0x5cdc=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x75\x74\x69\x6C","\x61\x70\x69","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x6C\x6F\x67\x67\x65\x72\x2E\x6A\x73","\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","\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","\x73\x74\x61\x63\x6B","\x65\x72\x72\x6F\x72"];_0x5cdc[0];var _=require(_0x5cdc[1]);var util=require(_0x5cdc[2]);var logger=require(_0x5cdc[4])(_0x5cdc[3]);var Util=require(_0x5cdc[5]);var sequelize=require(_0x5cdc[7])[_0x5cdc[6]];var VoiceContext=require(_0x5cdc[7])[_0x5cdc[8]];var VoiceExtension=require(_0x5cdc[7])[_0x5cdc[9]];exports[_0x5cdc[10]]= function(_0x987ex8,_0x987ex9,_0x987exa){return VoiceContext[_0x5cdc[17]](Util[_0x5cdc[16]](_0x987ex8[_0x5cdc[15]]))[_0x5cdc[14]](function(_0x987exc){_0x987ex9[_0x5cdc[13]](200)[_0x5cdc[12]](_0x987exc)})[_0x5cdc[11]](function(_0x987exb){return handleError(_0x987ex9,_0x987exb)})};exports[_0x5cdc[18]]= function(_0x987ex8,_0x987ex9){return VoiceContext[_0x5cdc[22]](_0x987ex8[_0x5cdc[21]][_0x5cdc[20]])[_0x5cdc[14]](function(_0x987exd){if(!_0x987exd){return _0x987ex9[_0x5cdc[19]](404)};return _0x987ex9[_0x5cdc[12]](_0x987exd)})[_0x5cdc[11]](function(_0x987exb){return handleError(_0x987ex9,_0x987exb)})};exports[_0x5cdc[23]]= function(_0x987ex8,_0x987ex9){return VoiceContext[_0x5cdc[26]]({where:{name:_0x987ex8[_0x5cdc[25]][_0x5cdc[24]]}})[_0x5cdc[14]](function(_0x987exe){if(!_0x987exe){return _0x987ex9[_0x5cdc[19]](404)};return _0x987ex9[_0x5cdc[12]](_0x987exe)})[_0x5cdc[11]](function(_0x987exb){return handleError(_0x987ex9,_0x987exb)})};exports[_0x5cdc[27]]= function(_0x987ex8,_0x987ex9){return VoiceContext[_0x5cdc[27]](_0x987ex8[_0x5cdc[25]])[_0x5cdc[14]](function(_0x987exd){return _0x987ex9[_0x5cdc[13]](201)[_0x5cdc[12]](_0x987exd)})[_0x5cdc[11]](sequelize.UniqueConstraintError,function(_0x987exb){_0x987exb[_0x5cdc[28]]= _0x5cdc[29];_0x987exb[_0x5cdc[30]]= _0x5cdc[31];return handleError(_0x987ex9,_0x987exb)})[_0x5cdc[11]](function(_0x987exb){return handleError(_0x987ex9,_0x987exb)})};exports[_0x5cdc[32]]= function(_0x987ex8,_0x987ex9){return VoiceContext[_0x5cdc[26]]({where:{name:_0x987ex8[_0x5cdc[25]][_0x5cdc[24]],id:{$ne:_0x987ex8[_0x5cdc[25]][_0x5cdc[20]]}}})[_0x5cdc[14]](function(_0x987ex10){if(!_0x987ex10){return _0x987ex9[_0x5cdc[19]](404)};if(_0x987ex10[_0x5cdc[35]]> 0){return _0x987ex9[_0x5cdc[13]](500)[_0x5cdc[12]]({message:_0x5cdc[31]})};if(_0x987ex8[_0x5cdc[25]][_0x5cdc[20]]){delete _0x987ex8[_0x5cdc[25]][_0x5cdc[20]]};return VoiceContext[_0x5cdc[22]](_0x987ex8[_0x5cdc[21]][_0x5cdc[20]])})[_0x5cdc[14]](function(_0x987exd){if(!_0x987exd){return _0x987ex9[_0x5cdc[19]](404)};var _0x987exf=_[_0x5cdc[33]](_0x987exd,_0x987ex8[_0x5cdc[25]]);return _0x987exf[_0x5cdc[34]]()})[_0x5cdc[14]](function(_0x987exd){return _0x987ex9[_0x5cdc[13]](200)[_0x5cdc[12]](_0x987exd)})[_0x5cdc[11]](function(_0x987exb){return handleError(_0x987ex9,_0x987exb)})};exports[_0x5cdc[36]]= function(_0x987ex8,_0x987ex9){var _0x987ex11;return VoiceContext[_0x5cdc[22]](_0x987ex8[_0x5cdc[21]][_0x5cdc[20]])[_0x5cdc[14]](function(_0x987exd){_0x987ex11= _0x987exd;if(!_0x987ex11){return _0x987ex9[_0x5cdc[19]](404)};if(_0x987ex11[_0x5cdc[39]]){return _0x987ex9[_0x5cdc[13]](500)[_0x5cdc[12]]({message:_0x5cdc[40],translatedMessage:_0x5cdc[41]})};return VoiceExtension[_0x5cdc[26]]({where:{context:_0x987ex11[_0x5cdc[24]],VoiceContextId:null}})})[_0x5cdc[14]](function(_0x987ex12){if(_0x987ex12[_0x5cdc[35]]> 0){return _0x987ex9[_0x5cdc[13]](500)[_0x5cdc[12]]({message:_0x5cdc[37],translatedMessage:_0x5cdc[38]})};return _0x987ex11[_0x5cdc[36]]()})[_0x5cdc[14]](function(){return _0x987ex9[_0x5cdc[19]](204)})[_0x5cdc[11]](function(_0x987exb){return handleError(_0x987ex9,_0x987exb)})};exports[_0x5cdc[42]]= function(_0x987ex8,_0x987ex9){var _0x987ex13;return VoiceContext[_0x5cdc[26]]({where:{id:_0x987ex8[_0x5cdc[15]][_0x5cdc[43]]}})[_0x5cdc[14]](function(_0x987exe){_0x987ex13= _0x987exe;var _0x987ex14=_[_0x5cdc[44]](_0x987ex13,{defaultEntry:true});if(_0x987ex14){return _0x987ex9[_0x5cdc[13]](500)[_0x5cdc[12]]({message:_0x5cdc[40],translatedMessage:_0x5cdc[41]})};if(!_0x987ex13){return _0x987ex9[_0x5cdc[19]](404)};var _0x987ex15=_[_0x5cdc[46]](_[_0x5cdc[46]](_0x987ex13,_0x5cdc[45]),_0x5cdc[24]);return VoiceExtension[_0x5cdc[26]]({where:{context:_0x987ex15,VoiceContextId:null}})})[_0x5cdc[14]](function(_0x987ex12){if(_0x987ex12[_0x5cdc[35]]> _0x987ex13[_0x5cdc[35]]){return _0x987ex9[_0x5cdc[13]](500)[_0x5cdc[12]]({message:_0x5cdc[37],translatedMessage:_0x5cdc[38]})};return VoiceContext[_0x5cdc[36]]({where:{id:_0x987ex8[_0x5cdc[15]][_0x5cdc[43]]},individualHooks:true})})[_0x5cdc[14]](function(){return _0x987ex9[_0x5cdc[19]](204)})[_0x5cdc[11]](function(_0x987exb){return handleError(_0x987ex9,_0x987exb)})};function handleError(_0x987ex9,_0x987exb){logger[_0x5cdc[48]](_0x987exb[_0x5cdc[47]]);return _0x987ex9[_0x5cdc[13]](500)[_0x5cdc[12]](_0x987exb)}
\ No newline at end of file