Built motion from commit 82438f7.|0.0.115
[motion.git] / server / api / agent / agent.controller.js
index 975c465..a14b8a6 100644 (file)
@@ -1 +1 @@
-var _0xc97f=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x75\x74\x69\x6C","\x55\x73\x65\x72","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x54\x65\x61\x6D","\x69\x6E\x64\x65\x78","\x66\x75\x6C\x6C\x6E\x61\x6D\x65","\x6E\x61\x6D\x65","\x65\x6D\x61\x69\x6C","\x70\x65\x72\x5F\x70\x61\x67\x65","\x71\x75\x65\x72\x79","\x70\x61\x67\x65","\x61\x67\x65\x6E\x74","\x6F\x72\x64\x65\x72","\x25\x73\x20\x25\x73","\x73\x6F\x72\x74\x5F\x62\x79","\x73\x6F\x72\x74\x5F\x6F\x72\x64\x65\x72","\x41\x53\x43","\x66\x6F\x72\x6D\x61\x74","\x24\x6F\x72","\x77\x68\x65\x72\x65","\x25","\x70\x75\x73\x68","\x66\x6F\x72\x45\x61\x63\x68","\x24","\x24\x6C\x69\x6B\x65","\x66\x6F\x72\x49\x6E","\x53\x6F\x6D\x65\x74\x68\x69\x6E\x67\x20\x62\x6C\x65\x77\x20\x75\x70\x21","\x73\x65\x6E\x64","\x73\x74\x61\x74\x75\x73","\x63\x61\x74\x63\x68","\x63\x6F\x75\x6E\x74","\x63\x65\x69\x6C","\x6F\x66\x66\x73\x65\x74","\x25\x73\x3A\x2F\x2F\x25\x73\x25\x73\x3F\x70\x61\x67\x65\x3D\x25\x64","\x70\x72\x6F\x74\x6F\x63\x6F\x6C","\x68\x6F\x73\x74","\x68\x65\x61\x64\x65\x72\x73","\x62\x61\x73\x65\x55\x72\x6C","\x72\x6F\x77\x73","\x74\x68\x65\x6E","\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","\x69\x6E\x74\x65\x72\x6E\x61\x6C\x56\x61\x6C\x69\x64\x61\x74\x69\x6F\x6E","\x69\x6E\x74\x65\x72\x6E\x61\x6C","\x62\x6F\x64\x79","\x66\x69\x6E\x64\x41\x6C\x6C","\x63\x72\x65\x61\x74\x65","\x6C\x6F\x67","\x61\x64\x64\x55\x73\x65\x72","\x66\x69\x6E\x64\x4F\x6E\x65","\x75\x70\x64\x61\x74\x65","\x6D\x65\x72\x67\x65","\x73\x61\x76\x65","\x64\x65\x73\x74\x72\x6F\x79","\x62\x75\x6C\x6B\x44\x65\x73\x74\x72\x6F\x79","\x63\x68\x61\x6E\x67\x65\x50\x61\x73\x73\x77\x6F\x72\x64","\x75\x73\x65\x72","\x6F\x6C\x64\x50\x61\x73\x73\x77\x6F\x72\x64","\x6E\x65\x77\x50\x61\x73\x73\x77\x6F\x72\x64","\x61\x75\x74\x68\x65\x6E\x74\x69\x63\x61\x74\x65","\x70\x61\x73\x73\x77\x6F\x72\x64","\x72\x65\x73\x65\x74\x50\x61\x73\x73\x77\x6F\x72\x64","\x61\x67\x65\x6E\x74\x56\x61\x6C\x69\x64\x61\x74\x69\x6F\x6E","\x66\x69\x65\x6C\x64","\x76\x61\x6C\x75\x65"];_0xc97f[0];var _=require(_0xc97f[1]);var util=require(_0xc97f[2]);var Agent=require(_0xc97f[4])[_0xc97f[3]];var Team=require(_0xc97f[4])[_0xc97f[5]];exports[_0xc97f[6]]=function(_0x2f0cx5,_0x2f0cx6,_0x2f0cx7){var _0x2f0cx8=[_0xc97f[7],_0xc97f[8],_0xc97f[9]];var _0x2f0cx9=_0x2f0cx5[_0xc97f[11]][_0xc97f[10]]?parseInt(_0x2f0cx5[_0xc97f[11]][_0xc97f[10]],10):100;var _0x2f0cxa=_0x2f0cx5[_0xc97f[11]][_0xc97f[12]]?parseInt(_0x2f0cx5[_0xc97f[11]][_0xc97f[12]],10):0;var _0x2f0cxb={where:{role:_0xc97f[13]},limit:_0x2f0cx9,offset:_0x2f0cxa*_0x2f0cx9};_[_0xc97f[27]](_0x2f0cx5[_0xc97f[11]],function(_0x2f0cxc,_0x2f0cxd){switch(_0x2f0cxd){case _0xc97f[10]:;case _0xc97f[12]:break ;;case _0xc97f[16]:_0x2f0cxb[_0xc97f[14]]=util[_0xc97f[19]](_0xc97f[15],_0x2f0cx5[_0xc97f[11]][_0xc97f[16]],_0x2f0cx5[_0xc97f[11]][_0xc97f[17]]||_0xc97f[18])||null;break ;;case _0xc97f[17]:break ;;case _0xc97f[25]:_0x2f0cxb[_0xc97f[21]][_0xc97f[20]]=[];_0x2f0cx8[_0xc97f[24]](function(_0x2f0cxe){var _0x2f0cxf={};_0x2f0cxf[_0x2f0cxe]={$like:_0xc97f[22]+_0x2f0cxc+_0xc97f[22]};_0x2f0cxb[_0xc97f[21]][_0xc97f[20]][_0xc97f[23]](_0x2f0cxf);});break ;;default:_0x2f0cxb[_0xc97f[21]][_0x2f0cxd]={$like:{}};_0x2f0cxb[_0xc97f[21]][_0x2f0cxd][_0xc97f[26]]=_0xc97f[22]+_0x2f0cxc+_0xc97f[22];;}});Agent[_0xc97f[42]](_0x2f0cxb)[_0xc97f[41]](function(_0x2f0cx11){var _0x2f0cx12=Math[_0xc97f[33]](_0x2f0cx11[_0xc97f[32]]/_0x2f0cx9);var _0x2f0cx13=_0x2f0cx12>(_0x2f0cxb[_0xc97f[34]]+1)?util[_0xc97f[19]](_0xc97f[35],_0x2f0cx5[_0xc97f[36]],_0x2f0cx5[_0xc97f[38]][_0xc97f[37]],_0x2f0cx5[_0xc97f[39]],_0x2f0cxa+1):null;var _0x2f0cx14=_0x2f0cxa>0?util[_0xc97f[19]](_0xc97f[35],_0x2f0cx5[_0xc97f[36]],_0x2f0cx5[_0xc97f[38]][_0xc97f[37]],_0x2f0cx5[_0xc97f[39]],_0x2f0cxa-1):null;_0x2f0cx6[_0xc97f[30]](200)[_0xc97f[29]]({count:_0x2f0cx11[_0xc97f[32]],rows:_0x2f0cx11[_0xc97f[40]],next_page:_0x2f0cx13,previous_page:_0x2f0cx14,total_pages:_0x2f0cx12});})[_0xc97f[31]](function(_0x2f0cx10){_0x2f0cx6[_0xc97f[30]](500)[_0xc97f[29]]({error:_0xc97f[28]})});};exports[_0xc97f[43]]=function(_0x2f0cx5,_0x2f0cx6){Agent[_0xc97f[47]](_0x2f0cx5[_0xc97f[46]][_0xc97f[45]])[_0xc97f[41]](function(_0x2f0cx15){if(!_0x2f0cx15){return _0x2f0cx6[_0xc97f[44]](404)};return _0x2f0cx6[_0xc97f[29]](_0x2f0cx15);})[_0xc97f[31]](function(_0x2f0cx10){return handleError(_0x2f0cx6,_0x2f0cx10)})};exports[_0xc97f[48]]=function(_0x2f0cx5,_0x2f0cx6){Agent[_0xc97f[51]]({where:{internal:_0x2f0cx5[_0xc97f[50]][_0xc97f[49]]}})[_0xc97f[41]](function(_0x2f0cx16){if(!_0x2f0cx16){return _0x2f0cx6[_0xc97f[44]](404)};return _0x2f0cx6[_0xc97f[29]](_0x2f0cx16);})[_0xc97f[31]](function(_0x2f0cx10){return handleError(_0x2f0cx6,_0x2f0cx10)})};exports[_0xc97f[52]]=function(_0x2f0cx5,_0x2f0cx6){Agent[_0xc97f[52]](_0x2f0cx5[_0xc97f[50]])[_0xc97f[41]](function(_0x2f0cx15){Team[_0xc97f[55]]({where:{defaultEntry:true}})[_0xc97f[41]](function(_0x2f0cx17){_0x2f0cx17[_0xc97f[54]](_0x2f0cx15[_0xc97f[45]])[_0xc97f[41]](function(){return _0x2f0cx6[_0xc97f[30]](201)[_0xc97f[29]](_0x2f0cx15)})[_0xc97f[31]](function(_0x2f0cx10){console[_0xc97f[53]](_0x2f0cx10);return handleError(_0x2f0cx6,_0x2f0cx10);})})[_0xc97f[31]](function(_0x2f0cx10){console[_0xc97f[53]](_0x2f0cx10);return handleError(_0x2f0cx6,_0x2f0cx10);})})[_0xc97f[31]](function(_0x2f0cx10){console[_0xc97f[53]](_0x2f0cx10);return handleError(_0x2f0cx6,_0x2f0cx10);})};exports[_0xc97f[56]]=function(_0x2f0cx5,_0x2f0cx6){if(_0x2f0cx5[_0xc97f[50]][_0xc97f[45]]){delete _0x2f0cx5[_0xc97f[50]][_0xc97f[45]]};Agent[_0xc97f[47]](_0x2f0cx5[_0xc97f[46]][_0xc97f[45]])[_0xc97f[41]](function(_0x2f0cx15){if(!_0x2f0cx15){return _0x2f0cx6[_0xc97f[44]](404)};var _0x2f0cx18=_[_0xc97f[57]](_0x2f0cx15,_0x2f0cx5[_0xc97f[50]]);_0x2f0cx18[_0xc97f[58]]()[_0xc97f[41]](function(){return _0x2f0cx6[_0xc97f[30]](200)[_0xc97f[29]](_0x2f0cx15)})[_0xc97f[31]](function(_0x2f0cx10){return handleError(_0x2f0cx6,_0x2f0cx10)});})[_0xc97f[31]](function(_0x2f0cx10){return handleError(_0x2f0cx6,_0x2f0cx10)});};exports[_0xc97f[59]]=function(_0x2f0cx5,_0x2f0cx6){Agent[_0xc97f[47]](_0x2f0cx5[_0xc97f[46]][_0xc97f[45]])[_0xc97f[41]](function(_0x2f0cx15){if(!_0x2f0cx15){return _0x2f0cx6[_0xc97f[44]](404)};_0x2f0cx15[_0xc97f[59]]()[_0xc97f[41]](function(){return _0x2f0cx6[_0xc97f[44]](204)})[_0xc97f[31]](function(_0x2f0cx10){return handleError(_0x2f0cx6,_0x2f0cx10)});})[_0xc97f[31]](function(_0x2f0cx10){return handleError(_0x2f0cx6,_0x2f0cx10)})};exports[_0xc97f[60]]=function(_0x2f0cx5,_0x2f0cx6){Agent[_0xc97f[59]]({where:{id:_0x2f0cx5[_0xc97f[11]][_0xc97f[45]]},individualHooks:true})[_0xc97f[41]](function(){return _0x2f0cx6[_0xc97f[44]](204)})[_0xc97f[31]](function(_0x2f0cx10){return handleError(_0x2f0cx6,_0x2f0cx10)})};exports[_0xc97f[61]]=function(_0x2f0cx5,_0x2f0cx6,_0x2f0cx7){console[_0xc97f[53]](_0x2f0cx5[_0xc97f[50]]);var _0x2f0cx19=_0x2f0cx5[_0xc97f[62]][_0xc97f[45]];var _0x2f0cx1a=String(_0x2f0cx5[_0xc97f[50]][_0xc97f[63]]);var _0x2f0cx1b=String(_0x2f0cx5[_0xc97f[50]][_0xc97f[64]]);Agent[_0xc97f[47]](_0x2f0cx19)[_0xc97f[41]](function(_0x2f0cx15){if(_0x2f0cx15[_0xc97f[65]](_0x2f0cx1a)){_0x2f0cx15[_0xc97f[66]]=_0x2f0cx1b;_0x2f0cx15[_0xc97f[58]]()[_0xc97f[41]](function(){_0x2f0cx6[_0xc97f[30]](200)[_0xc97f[29]](_0x2f0cx15)})[_0xc97f[31]](function(_0x2f0cx10){return _0x2f0cx7(_0x2f0cx10)});}else {_0x2f0cx6[_0xc97f[44]](403)}});};exports[_0xc97f[67]]=function(_0x2f0cx5,_0x2f0cx6,_0x2f0cx7){var _0x2f0cx1b=String(_0x2f0cx5[_0xc97f[50]][_0xc97f[64]]);Agent[_0xc97f[47]](_0x2f0cx5[_0xc97f[46]][_0xc97f[45]])[_0xc97f[41]](function(_0x2f0cx1c){_0x2f0cx1c[_0xc97f[66]]=_0x2f0cx1b;_0x2f0cx1c[_0xc97f[58]]()[_0xc97f[41]](function(){_0x2f0cx6[_0xc97f[30]](200)[_0xc97f[29]](_0x2f0cx1c)})[_0xc97f[31]](function(_0x2f0cx10){return handleError(_0x2f0cx6,_0x2f0cx10)});});};exports[_0xc97f[68]]=function(_0x2f0cx5,_0x2f0cx6){var _0x2f0cx1d={};_0x2f0cx1d[_0x2f0cx5[_0xc97f[46]][_0xc97f[69]]]=_0x2f0cx5[_0xc97f[50]][_0xc97f[70]];Agent[_0xc97f[42]]({where:_0x2f0cx1d})[_0xc97f[41]](function(_0x2f0cx11){if(_0x2f0cx11[_0xc97f[32]]){return _0x2f0cx6[_0xc97f[30]](200)[_0xc97f[29]]({isValid:false,value:_0x2f0cx5[_0xc97f[50]][_0xc97f[70]]})};return _0x2f0cx6[_0xc97f[30]](200)[_0xc97f[29]]({isValid:true,value:_0x2f0cx5[_0xc97f[50]][_0xc97f[70]]});})[_0xc97f[31]](function(_0x2f0cx10){return handleError(_0x2f0cx6,_0x2f0cx10)});};function handleError(_0x2f0cx6,_0x2f0cx10){return _0x2f0cx6[_0xc97f[30]](500)[_0xc97f[29]](_0x2f0cx10)}
\ No newline at end of file
+var _0x4f11=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x73\x65\x71\x75\x65\x6C\x69\x7A\x65","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x55\x73\x65\x72","\x56\x6F\x69\x63\x65\x51\x75\x65\x75\x65","\x43\x68\x61\x74\x51\x75\x65\x75\x65","\x4D\x61\x69\x6C\x51\x75\x65\x75\x65","\x46\x61\x78\x51\x75\x65\x75\x65","\x53\x6D\x73\x51\x75\x65\x75\x65","\x54\x65\x61\x6D","\x4D\x61\x69\x6C\x52\x6F\x6F\x6D","\x4C\x69\x73\x74","\x69\x6E\x64\x65\x78","\x65\x72\x72\x6F\x72","\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\x41\x67\x65\x6E\x74\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x69\x64","\x75\x73\x65\x72","\x66\x69\x6E\x64\x42\x79\x49\x64","\x67\x65\x74\x51\x75\x65\x72\x79","\x66\x69\x6E\x64\x41\x6E\x64\x43\x6F\x75\x6E\x74\x41\x6C\x6C","\x61\x67\x65\x6E\x74","\x73\x63\x6F\x70\x65","\x72\x6F\x6C\x65","\x72\x65\x61\x6C\x74\x69\x6D\x65\x49\x6E\x64\x65\x78","\x6C\x6F\x67","\x63\x68\x65\x63\x6B\x50\x61\x75\x73\x65\x53\x74\x61\x74\x75\x73","\x63\x68\x65\x63\x6B\x51\x75\x65\x75\x65\x53\x74\x61\x74\x75\x73","\x63\x68\x65\x63\x6B\x4F\x6E\x6C\x69\x6E\x65\x53\x74\x61\x74\x75\x73","\x63\x68\x65\x63\x6B\x53\x69\x70\x53\x74\x61\x74\x75\x73","\x71\x75\x65\x75\x65\x73","\x72\x65\x61\x6C\x74\x69\x6D\x65\x56\x6F\x69\x63\x65\x49\x6E\x64\x65\x78","\x72\x6F\x77\x73","\x6E\x61\x6D\x65","\x6D\x61\x70","\x75\x6E\x69\x6F\x6E","\x66\x6F\x72\x45\x61\x63\x68","\x6D\x65\x72\x67\x65","\x67\x65\x74\x56\x6F\x69\x63\x65\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x72\x65\x61\x6C\x74\x69\x6D\x65\x43\x68\x61\x74\x49\x6E\x64\x65\x78","\x67\x65\x74\x43\x68\x61\x74\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x72\x65\x61\x6C\x74\x69\x6D\x65\x4D\x61\x69\x6C\x49\x6E\x64\x65\x78","\x67\x65\x74\x4D\x61\x69\x6C\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x72\x65\x61\x6C\x74\x69\x6D\x65\x46\x61\x78\x49\x6E\x64\x65\x78","\x67\x65\x74\x46\x61\x78\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x72\x65\x61\x6C\x74\x69\x6D\x65\x53\x6D\x73\x49\x6E\x64\x65\x78","\x67\x65\x74\x53\x6D\x73\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x73\x68\x6F\x77","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x70\x61\x72\x61\x6D\x73","\x73\x68\x6F\x77\x56\x6F\x69\x63\x65\x51\x75\x65\x75\x65\x73","\x6C\x65\x6E\x67\x74\x68","\x67\x65\x74\x56\x6F\x69\x63\x65\x51\x75\x65\x75\x65\x73","\x73\x68\x6F\x77\x43\x68\x61\x74\x51\x75\x65\x75\x65\x73","\x67\x65\x74\x43\x68\x61\x74\x51\x75\x65\x75\x65\x73","\x73\x68\x6F\x77\x4D\x61\x69\x6C\x51\x75\x65\x75\x65\x73","\x67\x65\x74\x4D\x61\x69\x6C\x51\x75\x65\x75\x65\x73","\x73\x68\x6F\x77\x46\x61\x78\x51\x75\x65\x75\x65\x73","\x67\x65\x74\x46\x61\x78\x51\x75\x65\x75\x65\x73","\x73\x68\x6F\x77\x53\x6D\x73\x51\x75\x65\x75\x65\x73","\x67\x65\x74\x53\x6D\x73\x51\x75\x65\x75\x65\x73","\x63\x72\x65\x61\x74\x65","\x62\x6F\x64\x79","\x68\x61\x6E\x64\x6C\x65\x55\x6E\x69\x71\x75\x65\x43\x6F\x6E\x73\x74\x72\x61\x69\x6E\x74\x45\x72\x72\x6F\x72","\x65\x72\x72\x6F\x72\x4D\x61\x6E\x61\x67\x65\x72","\x61\x64\x64\x55\x73\x65\x72","\x66\x69\x6E\x64\x4F\x6E\x65","\x74\x72\x61\x6E\x73\x61\x63\x74\x69\x6F\x6E","\x62\x75\x6C\x6B\x43\x72\x65\x61\x74\x65","\x61\x64\x64\x55\x73\x65\x72\x73","\x75\x70\x64\x61\x74\x65","\x73\x61\x76\x65","\x64\x65\x73\x74\x72\x6F\x79","\x68\x61\x6E\x64\x6C\x65\x46\x6F\x72\x65\x69\x67\x6E\x4B\x65\x79\x43\x6F\x6E\x73\x74\x72\x61\x69\x6E\x74\x45\x72\x72\x6F\x72","\x62\x75\x6C\x6B\x44\x65\x73\x74\x72\x6F\x79","\x69\x64\x73","\x63\x68\x61\x6E\x67\x65\x50\x61\x73\x73\x77\x6F\x72\x64","\x6F\x6C\x64\x50\x61\x73\x73\x77\x6F\x72\x64","\x6E\x65\x77\x50\x61\x73\x73\x77\x6F\x72\x64","\x61\x75\x74\x68\x65\x6E\x74\x69\x63\x61\x74\x65","\x70\x61\x73\x73\x77\x6F\x72\x64","\x72\x65\x73\x65\x74\x50\x61\x73\x73\x77\x6F\x72\x64"];_0x4f11[0];var _=require(_0x4f11[1]);var sequelize=require(_0x4f11[3])[_0x4f11[2]];var Util=require(_0x4f11[4]);var Agent=require(_0x4f11[3])[_0x4f11[5]];var VoiceQueue=require(_0x4f11[3])[_0x4f11[6]];var ChatQueue=require(_0x4f11[3])[_0x4f11[7]];var MailQueue=require(_0x4f11[3])[_0x4f11[8]];var FaxQueue=require(_0x4f11[3])[_0x4f11[9]];var SmsQueue=require(_0x4f11[3])[_0x4f11[10]];var User=require(_0x4f11[3])[_0x4f11[5]];var Team=require(_0x4f11[3])[_0x4f11[11]];var MailRoom=require(_0x4f11[3])[_0x4f11[12]];var List=require(_0x4f11[3])[_0x4f11[13]];exports[_0x4f11[14]]= function(_0xa7dexe,_0xa7dexf,_0xa7dex10){switch(_0xa7dexe[_0x4f11[23]][_0x4f11[29]]){case _0x4f11[23]:return User[_0x4f11[24]](_0xa7dexe[_0x4f11[23]][_0x4f11[22]],{attributes:[_0x4f11[22]]})[_0x4f11[19]](Util[_0x4f11[21]](_0xa7dexe[_0x4f11[20]]))[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[15]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)});default:return Agent[_0x4f11[28]](_0x4f11[27])[_0x4f11[26]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]]))[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})}};exports[_0x4f11[30]]= function(_0xa7dexe,_0xa7dexf,_0xa7dex10){switch(_0xa7dexe[_0x4f11[23]][_0x4f11[29]]){case _0x4f11[23]:return User[_0x4f11[24]](_0xa7dexe[_0x4f11[23]][_0x4f11[22]],{attributes:[_0x4f11[22]]})[_0x4f11[19]](Util[_0x4f11[21]](_0xa7dexe[_0x4f11[20]]))[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)});default:return Agent[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]},_0x4f11[36])[_0x4f11[26]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]]))[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)})}};exports[_0x4f11[37]]= function(_0xa7dexe,_0xa7dexf,_0xa7dex10){switch(_0xa7dexe[_0x4f11[23]][_0x4f11[29]]){case _0x4f11[23]:var _0xa7dex13=[];return User[_0x4f11[24]](_0xa7dexe[_0x4f11[23]][_0x4f11[22]],{attributes:[_0x4f11[22]]})[_0x4f11[19]](Util[_0x4f11[44]]({},{attributes:[_0x4f11[39]],include:[{raw:true,model:User,attributes:[_0x4f11[22]]}]}))[_0x4f11[19]](function(_0xa7dex14){var _0xa7dex15=_[_0x4f11[40]](_0xa7dex14[_0x4f11[38]],_0x4f11[39]);_0xa7dex14[_0x4f11[38]][_0x4f11[42]](function(_0xa7dex16){_0xa7dex13= _[_0x4f11[41]](_0xa7dex13,_[_0x4f11[40]](_0xa7dex16.Users,_0x4f11[22]))});return User[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]})[_0x4f11[26]](_[_0x4f11[43]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]],{id:{$in:_0xa7dex13}}),{include:[{model:VoiceQueue,where:{name:{$in:_0xa7dex15}},required:false}]}))})[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)});default:return Agent[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]},_0x4f11[36])[_0x4f11[26]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]]))[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)})}};exports[_0x4f11[45]]= function(_0xa7dexe,_0xa7dexf,_0xa7dex10){switch(_0xa7dexe[_0x4f11[23]][_0x4f11[29]]){case _0x4f11[23]:var _0xa7dex13=[];return User[_0x4f11[24]](_0xa7dexe[_0x4f11[23]][_0x4f11[22]],{attributes:[_0x4f11[22]]})[_0x4f11[19]](Util[_0x4f11[46]]({},{attributes:[_0x4f11[22]],include:[{raw:true,model:User,attributes:[_0x4f11[22]]}]}))[_0x4f11[19]](function(_0xa7dex14){var _0xa7dex17=_[_0x4f11[40]](_0xa7dex14[_0x4f11[38]],_0x4f11[22]);_0xa7dex14[_0x4f11[38]][_0x4f11[42]](function(_0xa7dex16){_0xa7dex13= _[_0x4f11[41]](_0xa7dex13,_[_0x4f11[40]](_0xa7dex16.Users,_0x4f11[22]))});return User[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]})[_0x4f11[26]](_[_0x4f11[43]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]],{id:{$in:_0xa7dex13}}),{include:[{model:ChatQueue,where:{id:{$in:_0xa7dex17}},required:false}]}))})[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)});default:return Agent[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]},_0x4f11[36])[_0x4f11[26]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]]))[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)})}};exports[_0x4f11[47]]= function(_0xa7dexe,_0xa7dexf,_0xa7dex10){switch(_0xa7dexe[_0x4f11[23]][_0x4f11[29]]){case _0x4f11[23]:var _0xa7dex13=[];return User[_0x4f11[24]](_0xa7dexe[_0x4f11[23]][_0x4f11[22]],{attributes:[_0x4f11[22]]})[_0x4f11[19]](Util[_0x4f11[48]]({},{attributes:[_0x4f11[22]],include:[{raw:true,model:User,attributes:[_0x4f11[22]]}]}))[_0x4f11[19]](function(_0xa7dex14){var _0xa7dex18=_[_0x4f11[40]](_0xa7dex14[_0x4f11[38]],_0x4f11[22]);_0xa7dex14[_0x4f11[38]][_0x4f11[42]](function(_0xa7dex16){_0xa7dex13= _[_0x4f11[41]](_0xa7dex13,_[_0x4f11[40]](_0xa7dex16.Users,_0x4f11[22]))});return User[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]})[_0x4f11[26]](_[_0x4f11[43]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]],{id:{$in:_0xa7dex13}}),{include:[{model:MailQueue,where:{id:{$in:_0xa7dex18}},required:false}]}))})[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)});default:return Agent[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]},_0x4f11[36])[_0x4f11[26]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]]))[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)})}};exports[_0x4f11[49]]= function(_0xa7dexe,_0xa7dexf,_0xa7dex10){switch(_0xa7dexe[_0x4f11[23]][_0x4f11[29]]){case _0x4f11[23]:var _0xa7dex13=[];return User[_0x4f11[24]](_0xa7dexe[_0x4f11[23]][_0x4f11[22]],{attributes:[_0x4f11[22]]})[_0x4f11[19]](Util[_0x4f11[50]]({},{attributes:[_0x4f11[22]],include:[{raw:true,model:User,attributes:[_0x4f11[22]]}]}))[_0x4f11[19]](function(_0xa7dex14){var _0xa7dex19=_[_0x4f11[40]](_0xa7dex14[_0x4f11[38]],_0x4f11[22]);_0xa7dex14[_0x4f11[38]][_0x4f11[42]](function(_0xa7dex16){_0xa7dex13= _[_0x4f11[41]](_0xa7dex13,_[_0x4f11[40]](_0xa7dex16.Users,_0x4f11[22]))});return User[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]})[_0x4f11[26]](_[_0x4f11[43]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]],{id:{$in:_0xa7dex13}}),{include:[{model:FaxQueue,where:{id:{$in:_0xa7dex19}},required:false}]}))})[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)});default:return Agent[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]},_0x4f11[36])[_0x4f11[26]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]]))[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)})}};exports[_0x4f11[51]]= function(_0xa7dexe,_0xa7dexf,_0xa7dex10){switch(_0xa7dexe[_0x4f11[23]][_0x4f11[29]]){case _0x4f11[23]:var _0xa7dex13=[];return User[_0x4f11[24]](_0xa7dexe[_0x4f11[23]][_0x4f11[22]],{attributes:[_0x4f11[22]]})[_0x4f11[19]](Util[_0x4f11[52]]({},{attributes:[_0x4f11[22]],include:[{raw:true,model:User,attributes:[_0x4f11[22]]}]}))[_0x4f11[19]](function(_0xa7dex14){var _0xa7dex1a=_[_0x4f11[40]](_0xa7dex14[_0x4f11[38]],_0x4f11[22]);_0xa7dex14[_0x4f11[38]][_0x4f11[42]](function(_0xa7dex16){_0xa7dex13= _[_0x4f11[41]](_0xa7dex13,_[_0x4f11[40]](_0xa7dex16.Users,_0x4f11[22]))});return User[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]})[_0x4f11[26]](_[_0x4f11[43]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]],{id:{$in:_0xa7dex13}}),{include:[{model:SmsQueue,where:{id:{$in:_0xa7dex1a}},required:false}]}))})[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)});default:return Agent[_0x4f11[28]](_0x4f11[27],{method:[_0x4f11[32],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[33],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[34],_0xa7dexe[_0x4f11[20]]]},{method:[_0x4f11[35],_0xa7dexe[_0x4f11[20]]]},_0x4f11[36])[_0x4f11[26]](Util[_0x4f11[25]](_0xa7dexe[_0x4f11[20]]))[_0x4f11[19]](function(_0xa7dex12){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex12)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)})}};exports[_0x4f11[53]]= function(_0xa7dexe,_0xa7dexf){return Agent[_0x4f11[28]](_0x4f11[27])[_0x4f11[24]](_0xa7dexe[_0x4f11[55]][_0x4f11[22]])[_0x4f11[19]](function(_0xa7dex1b){if(!_0xa7dex1b){return _0xa7dexf[_0x4f11[54]](404)};return _0xa7dexf[_0x4f11[17]](_0xa7dex1b)})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[56]]= function(_0xa7dexe,_0xa7dexf){return Agent[_0x4f11[28]](_0x4f11[27])[_0x4f11[24]](_0xa7dexe[_0x4f11[55]][_0x4f11[22]])[_0x4f11[19]](function(_0xa7dex1b){if(!_0xa7dex1b){return _0xa7dexf[_0x4f11[54]](404)};return _0xa7dex1b[_0x4f11[58]]({attributes:[_0x4f11[39]]})})[_0x4f11[19]](function(_0xa7dex15){return _0xa7dexf[_0x4f11[17]]({count:_0xa7dex15[_0x4f11[57]],rows:_0xa7dex15})})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[59]]= function(_0xa7dexe,_0xa7dexf){return Agent[_0x4f11[28]](_0x4f11[27])[_0x4f11[24]](_0xa7dexe[_0x4f11[55]][_0x4f11[22]])[_0x4f11[19]](function(_0xa7dex1b){if(!_0xa7dex1b){return _0xa7dexf[_0x4f11[54]](404)};return _0xa7dex1b[_0x4f11[60]]({attributes:[_0x4f11[22]]})})[_0x4f11[19]](function(_0xa7dex17){return _0xa7dexf[_0x4f11[17]]({count:_0xa7dex17[_0x4f11[57]],rows:_0xa7dex17})})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[61]]= function(_0xa7dexe,_0xa7dexf){return Agent[_0x4f11[28]](_0x4f11[27])[_0x4f11[24]](_0xa7dexe[_0x4f11[55]][_0x4f11[22]])[_0x4f11[19]](function(_0xa7dex1b){if(!_0xa7dex1b){return _0xa7dexf[_0x4f11[54]](404)};return _0xa7dex1b[_0x4f11[62]]({attributes:[_0x4f11[22]]})})[_0x4f11[19]](function(_0xa7dex18){return _0xa7dexf[_0x4f11[17]]({count:_0xa7dex18[_0x4f11[57]],rows:_0xa7dex18})})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[63]]= function(_0xa7dexe,_0xa7dexf){return Agent[_0x4f11[28]](_0x4f11[27])[_0x4f11[24]](_0xa7dexe[_0x4f11[55]][_0x4f11[22]])[_0x4f11[19]](function(_0xa7dex1b){if(!_0xa7dex1b){return _0xa7dexf[_0x4f11[54]](404)};return _0xa7dex1b[_0x4f11[64]]({attributes:[_0x4f11[22]]})})[_0x4f11[19]](function(_0xa7dex19){return _0xa7dexf[_0x4f11[17]]({count:_0xa7dex19[_0x4f11[57]],rows:_0xa7dex19})})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[65]]= function(_0xa7dexe,_0xa7dexf){return Agent[_0x4f11[28]](_0x4f11[27])[_0x4f11[24]](_0xa7dexe[_0x4f11[55]][_0x4f11[22]])[_0x4f11[19]](function(_0xa7dex1b){if(!_0xa7dex1b){return _0xa7dexf[_0x4f11[54]](404)};return _0xa7dex1b[_0x4f11[66]]({attributes:[_0x4f11[22]]})})[_0x4f11[19]](function(_0xa7dex1a){return _0xa7dexf[_0x4f11[17]]({count:_0xa7dex1a[_0x4f11[57]],rows:_0xa7dex1a})})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[67]]= function(_0xa7dexe,_0xa7dexf){var _0xa7dex1c;_0xa7dexe[_0x4f11[68]][_0x4f11[29]]= _0x4f11[27];return sequelize[_0x4f11[73]](function(_0xa7dex1d){return Agent[_0x4f11[28]](_0x4f11[27])[_0x4f11[67]](_0xa7dexe[_0x4f11[68]],{transaction:_0xa7dex1d})[_0x4f11[19]](function(_0xa7dex1b){_0xa7dex1c= _0xa7dex1b;return Team[_0x4f11[72]]({where:{defaultEntry:true}})})[_0x4f11[19]](function(_0xa7dex1f){return _0xa7dex1f[_0x4f11[71]](_0xa7dex1c[_0x4f11[22]],{transaction:_0xa7dex1d})})[_0x4f11[19]](function(){return List[_0x4f11[72]]({where:{defaultEntry:true}})})[_0x4f11[19]](function(_0xa7dex1e){return _0xa7dex1e[_0x4f11[71]](_0xa7dex1c[_0x4f11[22]],{transaction:_0xa7dex1d})})})[_0x4f11[19]](function(){return _0xa7dexf[_0x4f11[18]](201)[_0x4f11[17]](_0xa7dex1c)})[_0x4f11[16]](sequelize.UniqueConstraintError,function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return Util[_0x4f11[70]][_0x4f11[69]](_0xa7dexf,_0xa7dex11)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[74]]= function(_0xa7dexe,_0xa7dexf){var _0xa7dex20;if(_0xa7dexe[_0x4f11[68]]&& _0xa7dexe[_0x4f11[68]][_0x4f11[57]]){_0xa7dexe[_0x4f11[68]][_0x4f11[42]](function(_0xa7dex1b){_0xa7dex1b[_0x4f11[29]]= _0x4f11[27]})};return sequelize[_0x4f11[73]](function(_0xa7dex1d){return Agent[_0x4f11[74]](_0xa7dexe[_0x4f11[68]],{transaction:_0xa7dex1d,individualHooks:true})[_0x4f11[19]](function(_0xa7dex21){_0xa7dex20= _0xa7dex21;return Team[_0x4f11[72]]({where:{defaultEntry:true}})})[_0x4f11[19]](function(_0xa7dex1f){return _0xa7dex1f[_0x4f11[75]](_[_0x4f11[40]](_0xa7dex20,_0x4f11[22]),{transaction:_0xa7dex1d})})})[_0x4f11[19]](function(){return _0xa7dexf[_0x4f11[54]](201)})[_0x4f11[16]](sequelize.UniqueConstraintError,function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return Util[_0x4f11[70]][_0x4f11[69]](_0xa7dexf,_0xa7dex11)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[76]]= function(_0xa7dexe,_0xa7dexf){if(_0xa7dexe[_0x4f11[68]][_0x4f11[22]]){delete _0xa7dexe[_0x4f11[68]][_0x4f11[22]];delete _0xa7dexe[_0x4f11[68]][_0x4f11[29]]};return sequelize[_0x4f11[73]](function(_0xa7dex1d){return Agent[_0x4f11[24]](_0xa7dexe[_0x4f11[55]][_0x4f11[22]])[_0x4f11[19]](function(_0xa7dex1b){if(!_0xa7dex1b){return _0xa7dexf[_0x4f11[54]](404)};var _0xa7dex22=_[_0x4f11[43]](_0xa7dex1b,_0xa7dexe[_0x4f11[68]]);return _0xa7dex22[_0x4f11[77]]({transaction:_0xa7dex1d})})[_0x4f11[19]](function(_0xa7dex1b){return _0xa7dexf[_0x4f11[18]](200)[_0x4f11[17]](_0xa7dex1b)})})[_0x4f11[16]](sequelize.UniqueConstraintError,function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return Util[_0x4f11[70]][_0x4f11[69]](_0xa7dexf,_0xa7dex11)})[_0x4f11[16]](function(_0xa7dex11){console[_0x4f11[31]](_0xa7dex11);return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[78]]= function(_0xa7dexe,_0xa7dexf){var _0xa7dex1c;return Agent[_0x4f11[24]](_0xa7dexe[_0x4f11[55]][_0x4f11[22]])[_0x4f11[19]](function(_0xa7dex1b){_0xa7dex1c= _0xa7dex1b;if(!_0xa7dex1b){return _0xa7dexf[_0x4f11[54]](404)};return _0xa7dex1b[_0x4f11[78]]()})[_0x4f11[19]](function(){return _0xa7dexf[_0x4f11[54]](204)})[_0x4f11[16]](sequelize.ForeignKeyConstraintError,function(_0xa7dex11){return Util[_0x4f11[70]][_0x4f11[79]](_0xa7dexf,_0x4f11[27],_0xa7dex1c[_0x4f11[39]],_0xa7dex11)})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[80]]= function(_0xa7dexe,_0xa7dexf){return Agent[_0x4f11[78]]({where:{id:_0xa7dexe[_0x4f11[20]][_0x4f11[81]]},individualHooks:true})[_0x4f11[19]](function(){return _0xa7dexf[_0x4f11[54]](204)})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})};exports[_0x4f11[82]]= function(_0xa7dexe,_0xa7dexf,_0xa7dex10){var _0xa7dex23=_0xa7dexe[_0x4f11[23]][_0x4f11[22]];var _0xa7dex24=String(_0xa7dexe[_0x4f11[68]][_0x4f11[83]]);var _0xa7dex25=String(_0xa7dexe[_0x4f11[68]][_0x4f11[84]]);return Agent[_0x4f11[24]](_0xa7dex23)[_0x4f11[19]](function(_0xa7dex26){if(_0xa7dex26[_0x4f11[85]](_0xa7dex24)){_0xa7dex26[_0x4f11[86]]= _0xa7dex25;_0xa7dex26[_0x4f11[77]]()[_0x4f11[19]](function(){return _0xa7dexf[_0x4f11[54]](200)})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})}else {return _0xa7dexf[_0x4f11[54]](403)}})};exports[_0x4f11[87]]= function(_0xa7dexe,_0xa7dexf,_0xa7dex10){var _0xa7dex23=_0xa7dexe[_0x4f11[55]][_0x4f11[22]];var _0xa7dex25=String(_0xa7dexe[_0x4f11[68]][_0x4f11[84]]);return Agent[_0x4f11[24]](_0xa7dex23)[_0x4f11[19]](function(_0xa7dex26){_0xa7dex26[_0x4f11[86]]= _0xa7dex25;return _0xa7dex26[_0x4f11[77]]()})[_0x4f11[19]](function(){return _0xa7dexf[_0x4f11[54]](200)})[_0x4f11[16]](function(_0xa7dex11){return handleError(_0xa7dexf,_0xa7dex11)})};function handleError(_0xa7dexf,_0xa7dex11){return _0xa7dexf[_0x4f11[18]](500)[_0x4f11[17]](_0xa7dex11)}
\ No newline at end of file