Built motion from commit c36c9c6.|1.0.17
[motion.git] / server / api / agent / agent.controller.js
index be5b02b..095b1b2 100644 (file)
@@ -1 +1 @@
-var _0x9c5c=["\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","\x75\x74\x69\x6C","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65","\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","\x4D\x61\x69\x6C\x52\x6F\x6F\x6D","\x53\x65\x74\x74\x69\x6E\x67","\x55\x73\x65\x72","\x54\x65\x61\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","\x61\x64\x64\x51\x75\x65\x75\x65\x73","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x62\x6F\x64\x79","\x53\x49\x50\x2F\x25\x73","\x6E\x61\x6D\x65","\x66\x6F\x72\x6D\x61\x74","\x61\x64\x64\x56\x6F\x69\x63\x65\x51\x75\x65\x75\x65\x73","\x76\x6F\x69\x63\x65","\x61\x64\x64\x43\x68\x61\x74\x51\x75\x65\x75\x65\x73","\x63\x68\x61\x74","\x61\x64\x64\x4D\x61\x69\x6C\x51\x75\x65\x75\x65\x73","\x6D\x61\x69\x6C","\x61\x64\x64\x46\x61\x78\x51\x75\x65\x75\x65\x73","\x66\x61\x78","\x61\x64\x64\x53\x6D\x73\x51\x75\x65\x75\x65\x73","\x73\x6D\x73","\x61\x64\x64\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65\x73","\x6F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C","\x63\x68\x61\x6E\x6E\x65\x6C","\x70\x61\x72\x61\x6D\x73","\x72\x65\x6D\x6F\x76\x65\x51\x75\x65\x75\x65\x73","\x69\x64\x73","\x72\x65\x6D\x6F\x76\x65\x56\x6F\x69\x63\x65\x51\x75\x65\x75\x65\x73","\x72\x65\x6D\x6F\x76\x65\x43\x68\x61\x74\x51\x75\x65\x75\x65\x73","\x72\x65\x6D\x6F\x76\x65\x4D\x61\x69\x6C\x51\x75\x65\x75\x65\x73","\x72\x65\x6D\x6F\x76\x65\x53\x6D\x73\x51\x75\x65\x75\x65\x73","\x72\x65\x6D\x6F\x76\x65\x46\x61\x78\x51\x75\x65\x75\x65\x73","\x72\x65\x6D\x6F\x76\x65\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65\x73","\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","\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","\x72\x65\x61\x6C\x74\x69\x6D\x65\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x49\x6E\x64\x65\x78","\x67\x65\x74\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x73\x68\x6F\x77","\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","\x73\x68\x6F\x77\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65\x73","\x67\x65\x74\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65\x73","\x63\x72\x65\x61\x74\x65","\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","\x63\x68\x61\x6E\x6E\x65\x6C\x73","\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","\x70\x61\x73\x73\x77\x6F\x72\x64","\x61\x64\x64\x55\x73\x65\x72\x73","\x73\x65\x63\x75\x72\x65\x50\x61\x73\x73\x77\x6F\x72\x64","\x74\x65\x73\x74","\x49\x6E\x76\x61\x6C\x69\x64\x20\x70\x61\x73\x73\x77\x6F\x72\x64\x20\x70\x61\x74\x74\x65\x72\x6E","\x73\x74\x61\x72\x74\x49\x6E\x64\x65\x78","\x68\x61\x73\x4F\x77\x6E\x50\x72\x6F\x70\x65\x72\x74\x79","\x69\x73\x4E\x75\x6D\x62\x65\x72","\x6D\x69\x6E\x49\x6E\x74\x65\x72\x6E\x61\x6C","\x61\x6D\x6F\x75\x6E\x74","\x63\x6C\x6F\x6E\x65","\x69\x6E\x74\x65\x72\x6E\x61\x6C","\x66\x75\x6C\x6C\x6E\x61\x6D\x65","\x65\x6D\x61\x69\x6C","\x40","\x73\x70\x6C\x69\x74","\x70\x75\x73\x68","\x4E\x6F\x20\x61\x67\x65\x6E\x74\x73\x20\x61\x6D\x6F\x75\x6E\x74\x20\x73\x70\x65\x63\x69\x66\x69\x65\x64\x21","\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","\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","\x72\x65\x73\x65\x74\x50\x61\x73\x73\x77\x6F\x72\x64"];_0x9c5c[0];var _=require(_0x9c5c[1]);var sequelize=require(_0x9c5c[3])[_0x9c5c[2]];var util=require(_0x9c5c[4]);var Util=require(_0x9c5c[5]);var OpenchannelQueue=require(_0x9c5c[3])[_0x9c5c[6]];var VoiceQueue=require(_0x9c5c[3])[_0x9c5c[7]];var ChatQueue=require(_0x9c5c[3])[_0x9c5c[8]];var MailQueue=require(_0x9c5c[3])[_0x9c5c[9]];var FaxQueue=require(_0x9c5c[3])[_0x9c5c[10]];var SmsQueue=require(_0x9c5c[3])[_0x9c5c[11]];var MailRoom=require(_0x9c5c[3])[_0x9c5c[12]];var Setting=require(_0x9c5c[3])[_0x9c5c[13]];var Agent=require(_0x9c5c[3])[_0x9c5c[14]];var User=require(_0x9c5c[3])[_0x9c5c[14]];var Team=require(_0x9c5c[3])[_0x9c5c[15]];var List=require(_0x9c5c[3])[_0x9c5c[16]];exports[_0x9c5c[17]]= function(_0x747fx11,_0x747fx12,_0x747fx13){switch(_0x747fx11[_0x9c5c[26]][_0x9c5c[32]]){case _0x9c5c[26]:return User[_0x9c5c[27]](_0x747fx11[_0x9c5c[26]][_0x9c5c[25]],{attributes:[_0x9c5c[25]]})[_0x9c5c[22]](Util[_0x9c5c[24]](_0x747fx11[_0x9c5c[23]]))[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[18]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)});default:return Agent[_0x9c5c[31]](_0x9c5c[30])[_0x9c5c[29]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]]))[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})}};exports[_0x9c5c[33]]= function(_0x747fx11,_0x747fx12,_0x747fx13){return Agent[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]],{attributes:[_0x9c5c[25],_0x9c5c[37]]})[_0x9c5c[22]](function(_0x747fx17){if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](401)};switch(_0x747fx11[_0x9c5c[52]][_0x9c5c[51]]){case _0x9c5c[40]:return _0x747fx17[_0x9c5c[39]](_0x747fx11[_0x9c5c[35]],{interface:util[_0x9c5c[38]](_0x9c5c[36],_0x747fx17[_0x9c5c[37]]),stateinterface:util[_0x9c5c[38]](_0x9c5c[36],_0x747fx17[_0x9c5c[37]]),membername:_0x747fx17[_0x9c5c[37]],UserId:_0x747fx17[_0x9c5c[25]]});case _0x9c5c[42]:return _0x747fx17[_0x9c5c[41]](_0x747fx11[_0x9c5c[35]]);case _0x9c5c[44]:return _0x747fx17[_0x9c5c[43]](_0x747fx11[_0x9c5c[35]]);case _0x9c5c[46]:return _0x747fx17[_0x9c5c[45]](_0x747fx11[_0x9c5c[35]]);case _0x9c5c[48]:return _0x747fx17[_0x9c5c[47]](_0x747fx11[_0x9c5c[35]]);case _0x9c5c[50]:return _0x747fx17[_0x9c5c[49]](_0x747fx11[_0x9c5c[35]]);default:return null}})[_0x9c5c[22]](function(_0x747fx16){return _0x747fx12[_0x9c5c[34]](_0x747fx16?200:401)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[18]](_0x747fx14)})};exports[_0x9c5c[53]]= function(_0x747fx11,_0x747fx12,_0x747fx13){return Agent[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]],{attributes:[_0x9c5c[25]]})[_0x9c5c[22]](function(_0x747fx17){if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](401)};switch(_0x747fx11[_0x9c5c[52]][_0x9c5c[51]]){case _0x9c5c[40]:return _0x747fx17[_0x9c5c[55]](_0x747fx11[_0x9c5c[23]][_0x9c5c[54]]);case _0x9c5c[42]:return _0x747fx17[_0x9c5c[56]](_0x747fx11[_0x9c5c[23]][_0x9c5c[54]]);case _0x9c5c[44]:return _0x747fx17[_0x9c5c[57]](_0x747fx11[_0x9c5c[23]][_0x9c5c[54]]);case _0x9c5c[48]:return _0x747fx17[_0x9c5c[58]](_0x747fx11[_0x9c5c[23]][_0x9c5c[54]]);case _0x9c5c[46]:return _0x747fx17[_0x9c5c[59]](_0x747fx11[_0x9c5c[23]][_0x9c5c[54]]);case _0x9c5c[50]:return _0x747fx17[_0x9c5c[60]](_0x747fx11[_0x9c5c[23]][_0x9c5c[54]]);default:return null}})[_0x9c5c[22]](function(_0x747fx16){return _0x747fx12[_0x9c5c[34]](_0x747fx16?200:401)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[18]](_0x747fx14)})};exports[_0x9c5c[61]]= function(_0x747fx11,_0x747fx12,_0x747fx13){switch(_0x747fx11[_0x9c5c[26]][_0x9c5c[32]]){case _0x9c5c[26]:return User[_0x9c5c[27]](_0x747fx11[_0x9c5c[26]][_0x9c5c[25]],{attributes:[_0x9c5c[25]]})[_0x9c5c[22]](Util[_0x9c5c[24]](_0x747fx11[_0x9c5c[23]]))[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)});default:return Agent[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]},_0x9c5c[67])[_0x9c5c[29]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]]))[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)})}};exports[_0x9c5c[68]]= function(_0x747fx11,_0x747fx12,_0x747fx13){switch(_0x747fx11[_0x9c5c[26]][_0x9c5c[32]]){case _0x9c5c[26]:var _0x747fx18=[];return User[_0x9c5c[27]](_0x747fx11[_0x9c5c[26]][_0x9c5c[25]],{attributes:[_0x9c5c[25]]})[_0x9c5c[22]](Util[_0x9c5c[74]]({},{attributes:[_0x9c5c[37]],include:[{raw:true,model:User,attributes:[_0x9c5c[25]]}]}))[_0x9c5c[22]](function(_0x747fx16){var _0x747fx19=_[_0x9c5c[70]](_0x747fx16[_0x9c5c[69]],_0x9c5c[37]);_0x747fx16[_0x9c5c[69]][_0x9c5c[72]](function(_0x747fx1a){_0x747fx18= _[_0x9c5c[71]](_0x747fx18,_[_0x9c5c[70]](_0x747fx1a.Users,_0x9c5c[25]))});return User[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]})[_0x9c5c[29]](_[_0x9c5c[73]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]],{id:{$in:_0x747fx18}}),{include:[{model:VoiceQueue,where:{name:{$in:_0x747fx19}},required:false}]}))})[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)});default:return Agent[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]},_0x9c5c[67])[_0x9c5c[29]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]]))[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)})}};exports[_0x9c5c[75]]= function(_0x747fx11,_0x747fx12,_0x747fx13){switch(_0x747fx11[_0x9c5c[26]][_0x9c5c[32]]){case _0x9c5c[26]:var _0x747fx18=[];return User[_0x9c5c[27]](_0x747fx11[_0x9c5c[26]][_0x9c5c[25]],{attributes:[_0x9c5c[25]]})[_0x9c5c[22]](Util[_0x9c5c[76]]({},{attributes:[_0x9c5c[25]],include:[{raw:true,model:User,attributes:[_0x9c5c[25]]}]}))[_0x9c5c[22]](function(_0x747fx16){var _0x747fx1b=_[_0x9c5c[70]](_0x747fx16[_0x9c5c[69]],_0x9c5c[25]);_0x747fx16[_0x9c5c[69]][_0x9c5c[72]](function(_0x747fx1a){_0x747fx18= _[_0x9c5c[71]](_0x747fx18,_[_0x9c5c[70]](_0x747fx1a.Users,_0x9c5c[25]))});return User[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]})[_0x9c5c[29]](_[_0x9c5c[73]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]],{id:{$in:_0x747fx18}}),{include:[{model:ChatQueue,where:{id:{$in:_0x747fx1b}},required:false}]}))})[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)});default:return Agent[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]},_0x9c5c[67])[_0x9c5c[29]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]]))[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)})}};exports[_0x9c5c[77]]= function(_0x747fx11,_0x747fx12,_0x747fx13){switch(_0x747fx11[_0x9c5c[26]][_0x9c5c[32]]){case _0x9c5c[26]:var _0x747fx18=[];return User[_0x9c5c[27]](_0x747fx11[_0x9c5c[26]][_0x9c5c[25]],{attributes:[_0x9c5c[25]]})[_0x9c5c[22]](Util[_0x9c5c[78]]({},{attributes:[_0x9c5c[25]],include:[{raw:true,model:User,attributes:[_0x9c5c[25]]}]}))[_0x9c5c[22]](function(_0x747fx16){var _0x747fx1c=_[_0x9c5c[70]](_0x747fx16[_0x9c5c[69]],_0x9c5c[25]);_0x747fx16[_0x9c5c[69]][_0x9c5c[72]](function(_0x747fx1a){_0x747fx18= _[_0x9c5c[71]](_0x747fx18,_[_0x9c5c[70]](_0x747fx1a.Users,_0x9c5c[25]))});return User[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]})[_0x9c5c[29]](_[_0x9c5c[73]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]],{id:{$in:_0x747fx18}}),{include:[{model:MailQueue,where:{id:{$in:_0x747fx1c}},required:false}]}))})[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)});default:return Agent[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]},_0x9c5c[67])[_0x9c5c[29]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]]))[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)})}};exports[_0x9c5c[79]]= function(_0x747fx11,_0x747fx12,_0x747fx13){switch(_0x747fx11[_0x9c5c[26]][_0x9c5c[32]]){case _0x9c5c[26]:var _0x747fx18=[];return User[_0x9c5c[27]](_0x747fx11[_0x9c5c[26]][_0x9c5c[25]],{attributes:[_0x9c5c[25]]})[_0x9c5c[22]](Util[_0x9c5c[80]]({},{attributes:[_0x9c5c[25]],include:[{raw:true,model:User,attributes:[_0x9c5c[25]]}]}))[_0x9c5c[22]](function(_0x747fx16){var _0x747fx1d=_[_0x9c5c[70]](_0x747fx16[_0x9c5c[69]],_0x9c5c[25]);_0x747fx16[_0x9c5c[69]][_0x9c5c[72]](function(_0x747fx1a){_0x747fx18= _[_0x9c5c[71]](_0x747fx18,_[_0x9c5c[70]](_0x747fx1a.Users,_0x9c5c[25]))});return User[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]})[_0x9c5c[29]](_[_0x9c5c[73]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]],{id:{$in:_0x747fx18}}),{include:[{model:FaxQueue,where:{id:{$in:_0x747fx1d}},required:false}]}))})[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)});default:return Agent[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]},_0x9c5c[67])[_0x9c5c[29]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]]))[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)})}};exports[_0x9c5c[81]]= function(_0x747fx11,_0x747fx12,_0x747fx13){switch(_0x747fx11[_0x9c5c[26]][_0x9c5c[32]]){case _0x9c5c[26]:var _0x747fx18=[];return User[_0x9c5c[27]](_0x747fx11[_0x9c5c[26]][_0x9c5c[25]],{attributes:[_0x9c5c[25]]})[_0x9c5c[22]](Util[_0x9c5c[82]]({},{attributes:[_0x9c5c[25]],include:[{raw:true,model:User,attributes:[_0x9c5c[25]]}]}))[_0x9c5c[22]](function(_0x747fx16){var _0x747fx1e=_[_0x9c5c[70]](_0x747fx16[_0x9c5c[69]],_0x9c5c[25]);_0x747fx16[_0x9c5c[69]][_0x9c5c[72]](function(_0x747fx1a){_0x747fx18= _[_0x9c5c[71]](_0x747fx18,_[_0x9c5c[70]](_0x747fx1a.Users,_0x9c5c[25]))});return User[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]})[_0x9c5c[29]](_[_0x9c5c[73]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]],{id:{$in:_0x747fx18}}),{include:[{model:SmsQueue,where:{id:{$in:_0x747fx1e}},required:false}]}))})[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)});default:return Agent[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]},_0x9c5c[67])[_0x9c5c[29]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]]))[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)})}};exports[_0x9c5c[83]]= function(_0x747fx11,_0x747fx12,_0x747fx13){switch(_0x747fx11[_0x9c5c[26]][_0x9c5c[32]]){case _0x9c5c[26]:var _0x747fx18=[];return User[_0x9c5c[27]](_0x747fx11[_0x9c5c[26]][_0x9c5c[25]],{attributes:[_0x9c5c[25]]})[_0x9c5c[22]](Util[_0x9c5c[84]]({},{attributes:[_0x9c5c[25]],include:[{raw:true,model:User,attributes:[_0x9c5c[25]]}]}))[_0x9c5c[22]](function(_0x747fx16){var _0x747fx1f=_[_0x9c5c[70]](_0x747fx16[_0x9c5c[69]],_0x9c5c[25]);_0x747fx16[_0x9c5c[69]][_0x9c5c[72]](function(_0x747fx1a){_0x747fx18= _[_0x9c5c[71]](_0x747fx18,_[_0x9c5c[70]](_0x747fx1a.Users,_0x9c5c[25]))});return User[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]})[_0x9c5c[29]](_[_0x9c5c[73]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]],{id:{$in:_0x747fx18}}),{include:[{model:OpenchannelQueue,where:{id:{$in:_0x747fx1f}},required:false}]}))})[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)});default:return Agent[_0x9c5c[31]](_0x9c5c[30],{method:[_0x9c5c[63],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[64],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[65],_0x747fx11[_0x9c5c[23]]]},{method:[_0x9c5c[66],_0x747fx11[_0x9c5c[23]]]},_0x9c5c[67])[_0x9c5c[29]](Util[_0x9c5c[28]](_0x747fx11[_0x9c5c[23]]))[_0x9c5c[22]](function(_0x747fx15){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx15)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)})}};exports[_0x9c5c[85]]= function(_0x747fx11,_0x747fx12){return Agent[_0x9c5c[31]](_0x9c5c[30])[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]])[_0x9c5c[22]](function(_0x747fx17){if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](404)};return _0x747fx12[_0x9c5c[20]](_0x747fx17)})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[86]]= function(_0x747fx11,_0x747fx12){return Agent[_0x9c5c[31]](_0x9c5c[30])[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]])[_0x9c5c[22]](function(_0x747fx17){if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](404)};return _0x747fx17[_0x9c5c[88]]({attributes:[_0x9c5c[37]]})})[_0x9c5c[22]](function(_0x747fx19){return _0x747fx12[_0x9c5c[20]]({count:_0x747fx19[_0x9c5c[87]],rows:_0x747fx19})})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[89]]= function(_0x747fx11,_0x747fx12){return Agent[_0x9c5c[31]](_0x9c5c[30])[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]])[_0x9c5c[22]](function(_0x747fx17){if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](404)};return _0x747fx17[_0x9c5c[90]]({attributes:[_0x9c5c[25]]})})[_0x9c5c[22]](function(_0x747fx1b){return _0x747fx12[_0x9c5c[20]]({count:_0x747fx1b[_0x9c5c[87]],rows:_0x747fx1b})})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[91]]= function(_0x747fx11,_0x747fx12){return Agent[_0x9c5c[31]](_0x9c5c[30])[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]])[_0x9c5c[22]](function(_0x747fx17){if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](404)};return _0x747fx17[_0x9c5c[92]]({attributes:[_0x9c5c[25]]})})[_0x9c5c[22]](function(_0x747fx1c){return _0x747fx12[_0x9c5c[20]]({count:_0x747fx1c[_0x9c5c[87]],rows:_0x747fx1c})})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[93]]= function(_0x747fx11,_0x747fx12){return Agent[_0x9c5c[31]](_0x9c5c[30])[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]])[_0x9c5c[22]](function(_0x747fx17){if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](404)};return _0x747fx17[_0x9c5c[94]]({attributes:[_0x9c5c[25]]})})[_0x9c5c[22]](function(_0x747fx1d){return _0x747fx12[_0x9c5c[20]]({count:_0x747fx1d[_0x9c5c[87]],rows:_0x747fx1d})})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[95]]= function(_0x747fx11,_0x747fx12){return Agent[_0x9c5c[31]](_0x9c5c[30])[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]])[_0x9c5c[22]](function(_0x747fx17){if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](404)};return _0x747fx17[_0x9c5c[96]]({attributes:[_0x9c5c[25]]})})[_0x9c5c[22]](function(_0x747fx1e){return _0x747fx12[_0x9c5c[20]]({count:_0x747fx1e[_0x9c5c[87]],rows:_0x747fx1e})})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[97]]= function(_0x747fx11,_0x747fx12){return Agent[_0x9c5c[31]](_0x9c5c[30])[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]])[_0x9c5c[22]](function(_0x747fx17){if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](404)};return _0x747fx17[_0x9c5c[98]]({attributes:[_0x9c5c[25]]})})[_0x9c5c[22]](function(_0x747fx20){return _0x747fx12[_0x9c5c[20]]({count:_0x747fx20[_0x9c5c[87]],rows:_0x747fx20})})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[99]]= function(_0x747fx11,_0x747fx12){var _0x747fx21;_0x747fx11[_0x9c5c[35]][_0x9c5c[32]]= _0x9c5c[30];return sequelize[_0x9c5c[105]](function(_0x747fx22){return Agent[_0x9c5c[31]](_0x9c5c[30])[_0x9c5c[99]](_0x747fx11[_0x9c5c[35]],{transaction:_0x747fx22})[_0x9c5c[22]](function(_0x747fx17){_0x747fx21= _0x747fx17;return Team[_0x9c5c[104]]({where:{defaultEntry:true}})})[_0x9c5c[22]](function(_0x747fx24){return _0x747fx24[_0x9c5c[103]](_0x747fx21[_0x9c5c[25]],{transaction:_0x747fx22})})[_0x9c5c[22]](function(){return List[_0x9c5c[104]]({where:{defaultEntry:true}})})[_0x9c5c[22]](function(_0x747fx23){return _0x747fx23[_0x9c5c[103]](_0x747fx21[_0x9c5c[25]],{transaction:_0x747fx22})})[_0x9c5c[22]](function(){if(_0x747fx11[_0x9c5c[35]][_0x9c5c[102]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[40]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[40]][_0x9c5c[67]]){return _0x747fx21[_0x9c5c[39]](_0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[40]][_0x9c5c[67]],{interface:util[_0x9c5c[38]](_0x9c5c[36],_0x747fx21[_0x9c5c[37]]),stateinterface:util[_0x9c5c[38]](_0x9c5c[36],_0x747fx21[_0x9c5c[37]]),membername:_0x747fx21[_0x9c5c[37]],UserId:_0x747fx21[_0x9c5c[25]],transaction:_0x747fx22})}})[_0x9c5c[22]](function(){if(_0x747fx11[_0x9c5c[35]][_0x9c5c[102]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[42]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[42]][_0x9c5c[67]]){return _0x747fx21[_0x9c5c[41]](_0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[42]][_0x9c5c[67]],{transaction:_0x747fx22})}})[_0x9c5c[22]](function(){if(_0x747fx11[_0x9c5c[35]][_0x9c5c[102]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[44]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[44]][_0x9c5c[67]]){return _0x747fx21[_0x9c5c[43]](_0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[44]][_0x9c5c[67]],{transaction:_0x747fx22})}})[_0x9c5c[22]](function(){if(_0x747fx11[_0x9c5c[35]][_0x9c5c[102]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[48]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[48]][_0x9c5c[67]]){return _0x747fx21[_0x9c5c[47]](_0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[48]][_0x9c5c[67]],{transaction:_0x747fx22})}})[_0x9c5c[22]](function(){if(_0x747fx11[_0x9c5c[35]][_0x9c5c[102]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[46]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[46]][_0x9c5c[67]]){return _0x747fx21[_0x9c5c[45]](_0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[46]][_0x9c5c[67]],{transaction:_0x747fx22})}})[_0x9c5c[22]](function(){if(_0x747fx11[_0x9c5c[35]][_0x9c5c[102]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[50]]&& _0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[50]][_0x9c5c[67]]){return _0x747fx21[_0x9c5c[49]](_0x747fx11[_0x9c5c[35]][_0x9c5c[102]][_0x9c5c[50]][_0x9c5c[67]],{transaction:_0x747fx22})}})})[_0x9c5c[22]](function(){return _0x747fx12[_0x9c5c[21]](201)[_0x9c5c[20]](_0x747fx21)})[_0x9c5c[19]](sequelize.UniqueConstraintError,function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return Util[_0x9c5c[101]][_0x9c5c[100]](_0x747fx12,_0x747fx14)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[106]]= function(_0x747fx11,_0x747fx12){var _0x747fx25;var _0x747fx26;var _0x747fx27=[];var _0x747fx28=String(_0x747fx11[_0x9c5c[35]][_0x9c5c[107]]);return sequelize[_0x9c5c[105]](function(_0x747fx22){return Setting[_0x9c5c[27]](1)[_0x9c5c[22]](function(_0x747fx29){_0x747fx26= _0x747fx29;var _0x747fx2a=_0x747fx26[_0x9c5c[109]]?/^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[~!@#$%^&\-_=+\[\{\]\}.])[0-9a-zA-Z~!@#$%^&\-_=+\[\{\]\}.]{8,}$/:/^[a-zA-Z0-9]{6,}$/;if(!_0x747fx2a[_0x9c5c[110]](_0x747fx28)){throw  new Error(_0x9c5c[111])};var _0x747fx2b=0;if(_0x747fx11[_0x9c5c[35]][_0x9c5c[113]](_0x9c5c[112])&& _[_0x9c5c[114]](_0x747fx11[_0x9c5c[35]][_0x9c5c[112]])&& _0x747fx11[_0x9c5c[35]][_0x9c5c[112]]>= 0){_0x747fx2b= _0x747fx11[_0x9c5c[35]][_0x9c5c[112]];delete _0x747fx11[_0x9c5c[35]][_0x9c5c[112]]};var _0x747fx2c=_0x747fx11[_0x9c5c[35]][_0x9c5c[115]];delete _0x747fx11[_0x9c5c[35]][_0x9c5c[115]];if(_0x747fx11[_0x9c5c[35]][_0x9c5c[116]]){_0x747fx11[_0x9c5c[35]][_0x9c5c[32]]= _0x9c5c[30];for(var _0x747fx2d=_0x747fx2b;_0x747fx2d< _0x747fx11[_0x9c5c[35]][_0x9c5c[116]]+ _0x747fx2b;_0x747fx2d++,_0x747fx2c++){var _0x747fx2e=_[_0x9c5c[117]](_0x747fx11[_0x9c5c[35]]);_0x747fx2e[_0x9c5c[118]]= _0x747fx2c;_0x747fx2e[_0x9c5c[37]]= _0x747fx2e[_0x9c5c[37]]+ _0x747fx2d;_0x747fx2e[_0x9c5c[119]]= _0x747fx2e[_0x9c5c[119]]+ _0x747fx2d;_0x747fx2e[_0x9c5c[120]]= _0x747fx2e[_0x9c5c[120]][_0x9c5c[122]](_0x9c5c[121])[0]+ _0x747fx2d+ _0x9c5c[121]+ _0x747fx2e[_0x9c5c[120]][_0x9c5c[122]](_0x9c5c[121])[1];_0x747fx27[_0x9c5c[123]](_0x747fx2e)}}else {throw  new Error(_0x9c5c[124])};return Agent[_0x9c5c[106]](_0x747fx27,{transaction:_0x747fx22,individualHooks:true})})[_0x9c5c[22]](function(_0x747fx18){_0x747fx25= _0x747fx18;return Team[_0x9c5c[104]]({where:{defaultEntry:true}})})[_0x9c5c[22]](function(_0x747fx24){return _0x747fx24[_0x9c5c[108]](_[_0x9c5c[70]](_0x747fx25,_0x9c5c[25]),{transaction:_0x747fx22})})})[_0x9c5c[22]](function(){return _0x747fx12[_0x9c5c[34]](201)})[_0x9c5c[19]](sequelize.UniqueConstraintError,function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return Util[_0x9c5c[101]][_0x9c5c[100]](_0x747fx12,_0x747fx14)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[125]]= function(_0x747fx11,_0x747fx12){if(_0x747fx11[_0x9c5c[35]][_0x9c5c[25]]){delete _0x747fx11[_0x9c5c[35]][_0x9c5c[25]]};delete _0x747fx11[_0x9c5c[35]][_0x9c5c[32]];delete _0x747fx11[_0x9c5c[35]][_0x9c5c[37]];delete _0x747fx11[_0x9c5c[35]][_0x9c5c[107]];return sequelize[_0x9c5c[105]](function(_0x747fx22){return Agent[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]])[_0x9c5c[22]](function(_0x747fx17){if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](404)};var _0x747fx2f=_[_0x9c5c[73]](_0x747fx17,_0x747fx11[_0x9c5c[35]]);return _0x747fx2f[_0x9c5c[126]]({transaction:_0x747fx22})})[_0x9c5c[22]](function(_0x747fx17){return _0x747fx12[_0x9c5c[21]](200)[_0x9c5c[20]](_0x747fx17)})})[_0x9c5c[19]](sequelize.UniqueConstraintError,function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return Util[_0x9c5c[101]][_0x9c5c[100]](_0x747fx12,_0x747fx14)})[_0x9c5c[19]](function(_0x747fx14){console[_0x9c5c[62]](_0x747fx14);return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[127]]= function(_0x747fx11,_0x747fx12){var _0x747fx21;return Agent[_0x9c5c[27]](_0x747fx11[_0x9c5c[52]][_0x9c5c[25]])[_0x9c5c[22]](function(_0x747fx17){_0x747fx21= _0x747fx17;if(!_0x747fx17){return _0x747fx12[_0x9c5c[34]](404)};return _0x747fx17[_0x9c5c[127]]()})[_0x9c5c[22]](function(){return _0x747fx12[_0x9c5c[34]](204)})[_0x9c5c[19]](sequelize.ForeignKeyConstraintError,function(_0x747fx14){return Util[_0x9c5c[101]][_0x9c5c[128]](_0x747fx12,_0x9c5c[30],_0x747fx21[_0x9c5c[37]],_0x747fx14)})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[129]]= function(_0x747fx11,_0x747fx12){return Agent[_0x9c5c[127]]({where:{id:_0x747fx11[_0x9c5c[23]][_0x9c5c[54]]},individualHooks:true})[_0x9c5c[22]](function(){return _0x747fx12[_0x9c5c[34]](204)})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[130]]= function(_0x747fx11,_0x747fx12,_0x747fx13){var _0x747fx26;var _0x747fx30=_0x747fx11[_0x9c5c[26]][_0x9c5c[25]];var _0x747fx31=String(_0x747fx11[_0x9c5c[35]][_0x9c5c[131]]);var _0x747fx32=String(_0x747fx11[_0x9c5c[35]][_0x9c5c[132]]);return Setting[_0x9c5c[27]](1)[_0x9c5c[22]](function(_0x747fx29){_0x747fx26= _0x747fx29;return Agent[_0x9c5c[27]](_0x747fx30)})[_0x9c5c[22]](function(_0x747fx33){var _0x747fx2a=_0x747fx26[_0x9c5c[109]]?/^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[~!@#$%^&\-_=+\[\{\]\}.])[0-9a-zA-Z~!@#$%^&\-_=+\[\{\]\}.]{8,}$/:/^[a-zA-Z0-9]{6,}$/;if(!_0x747fx2a[_0x9c5c[110]](_0x747fx32)){throw  new Error(_0x9c5c[111])};if(_0x747fx33[_0x9c5c[133]](_0x747fx31)){_0x747fx33[_0x9c5c[107]]= _0x747fx32;return _0x747fx33[_0x9c5c[126]]()}else {return _0x747fx12[_0x9c5c[34]](403)}})[_0x9c5c[22]](function(){return _0x747fx12[_0x9c5c[34]](200)})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};exports[_0x9c5c[134]]= function(_0x747fx11,_0x747fx12,_0x747fx13){var _0x747fx26;var _0x747fx30=_0x747fx11[_0x9c5c[52]][_0x9c5c[25]];var _0x747fx32=String(_0x747fx11[_0x9c5c[35]][_0x9c5c[132]]);return Setting[_0x9c5c[27]](1)[_0x9c5c[22]](function(_0x747fx29){_0x747fx26= _0x747fx29;return Agent[_0x9c5c[27]](_0x747fx30)})[_0x9c5c[22]](function(_0x747fx33){var _0x747fx2a=_0x747fx26[_0x9c5c[109]]?/^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[~!@#$%^&\-_=+\[\{\]\}.])[0-9a-zA-Z~!@#$%^&\-_=+\[\{\]\}.]{8,}$/:/^[a-zA-Z0-9]{6,}$/;if(!_0x747fx2a[_0x9c5c[110]](_0x747fx32)){throw  new Error(_0x9c5c[111])};_0x747fx33[_0x9c5c[107]]= _0x747fx32;return _0x747fx33[_0x9c5c[126]]()})[_0x9c5c[22]](function(){return _0x747fx12[_0x9c5c[34]](200)})[_0x9c5c[19]](function(_0x747fx14){return handleError(_0x747fx12,_0x747fx14)})};function handleError(_0x747fx12,_0x747fx14){return _0x747fx12[_0x9c5c[21]](500)[_0x9c5c[20]](_0x747fx14)}
\ No newline at end of file
+var _0x546d=["\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","\x62\x6C\x75\x65\x62\x69\x72\x64","\x75\x74\x69\x6C","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x74\x6F\x6F\x6C\x73\x2F\x75\x73\x65\x72","\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65","\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","\x4D\x61\x69\x6C\x52\x6F\x6F\x6D","\x53\x65\x74\x74\x69\x6E\x67","\x55\x73\x65\x72","\x54\x65\x61\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","\x61\x64\x64\x51\x75\x65\x75\x65\x73","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x76\x61\x6C\x75\x65\x73","\x62\x6F\x64\x79","\x53\x49\x50\x2F\x25\x73","\x6E\x61\x6D\x65","\x66\x6F\x72\x6D\x61\x74","\x70\x65\x6E\x61\x6C\x74\x79","\x61\x64\x64\x56\x6F\x69\x63\x65\x51\x75\x65\x75\x65\x73","\x76\x6F\x69\x63\x65","\x61\x64\x64\x43\x68\x61\x74\x51\x75\x65\x75\x65","\x70\x75\x73\x68","\x66\x6F\x72\x45\x61\x63\x68","\x61\x6C\x6C","\x66\x69\x6E\x64\x41\x6C\x6C","\x63\x68\x61\x74","\x61\x64\x64\x4D\x61\x69\x6C\x51\x75\x65\x75\x65","\x6D\x61\x69\x6C","\x61\x64\x64\x46\x61\x78\x51\x75\x65\x75\x65","\x66\x61\x78","\x61\x64\x64\x53\x6D\x73\x51\x75\x65\x75\x65","\x73\x6D\x73","\x61\x64\x64\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65","\x6F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C","\x63\x68\x61\x6E\x6E\x65\x6C","\x70\x61\x72\x61\x6D\x73","\x72\x65\x6D\x6F\x76\x65\x51\x75\x65\x75\x65\x73","\x69\x64\x73","\x72\x65\x6D\x6F\x76\x65\x56\x6F\x69\x63\x65\x51\x75\x65\x75\x65\x73","\x72\x65\x6D\x6F\x76\x65\x43\x68\x61\x74\x51\x75\x65\x75\x65\x73","\x72\x65\x6D\x6F\x76\x65\x4D\x61\x69\x6C\x51\x75\x65\x75\x65\x73","\x72\x65\x6D\x6F\x76\x65\x53\x6D\x73\x51\x75\x65\x75\x65\x73","\x72\x65\x6D\x6F\x76\x65\x46\x61\x78\x51\x75\x65\x75\x65\x73","\x72\x65\x6D\x6F\x76\x65\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65\x73","\x72\x65\x61\x6C\x74\x69\x6D\x65\x49\x6E\x64\x65\x78","\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","\x72\x65\x61\x6C\x74\x69\x6D\x65\x56\x6F\x69\x63\x65\x49\x6E\x64\x65\x78","\x72\x6F\x77\x73","\x6D\x61\x70","\x75\x6E\x69\x6F\x6E","\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","\x71\x75\x65\x75\x65\x73","\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","\x72\x65\x61\x6C\x74\x69\x6D\x65\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x49\x6E\x64\x65\x78","\x67\x65\x74\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x73\x68\x6F\x77","\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","\x73\x68\x6F\x77\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65\x73","\x67\x65\x74\x4F\x70\x65\x6E\x63\x68\x61\x6E\x6E\x65\x6C\x51\x75\x65\x75\x65\x73","\x63\x72\x65\x61\x74\x65","\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","\x61\x66\x74\x65\x72\x43\x72\x65\x61\x74\x65","\x70\x61\x73\x73\x77\x6F\x72\x64","\x73\x65\x63\x75\x72\x65\x50\x61\x73\x73\x77\x6F\x72\x64","\x74\x65\x73\x74","\x57\x72\x6F\x6E\x67\x20\x70\x61\x73\x73\x77\x6F\x72\x64\x20\x66\x6F\x72\x6D\x61\x74\x21","\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","\x49\x6E\x76\x61\x6C\x69\x64\x20\x70\x61\x73\x73\x77\x6F\x72\x64\x20\x70\x61\x74\x74\x65\x72\x6E","\x73\x74\x61\x72\x74\x49\x6E\x64\x65\x78","\x68\x61\x73\x4F\x77\x6E\x50\x72\x6F\x70\x65\x72\x74\x79","\x69\x73\x4E\x75\x6D\x62\x65\x72","\x6D\x69\x6E\x49\x6E\x74\x65\x72\x6E\x61\x6C","\x61\x6D\x6F\x75\x6E\x74","\x63\x6C\x6F\x6E\x65","\x69\x6E\x74\x65\x72\x6E\x61\x6C","\x66\x75\x6C\x6C\x6E\x61\x6D\x65","\x65\x6D\x61\x69\x6C","\x40","\x73\x70\x6C\x69\x74","\x4E\x6F\x20\x61\x67\x65\x6E\x74\x73\x20\x61\x6D\x6F\x75\x6E\x74\x20\x73\x70\x65\x63\x69\x66\x69\x65\x64\x21","\x75\x70\x64\x61\x74\x65","\x61\x66\x74\x65\x72\x55\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"];_0x546d[0];var _=require(_0x546d[1]);var sequelize=require(_0x546d[3])[_0x546d[2]];var BPromise=require(_0x546d[4]);var util=require(_0x546d[5]);var Util=require(_0x546d[6]);var userTools=require(_0x546d[7]);var OpenchannelQueue=require(_0x546d[3])[_0x546d[8]];var VoiceQueue=require(_0x546d[3])[_0x546d[9]];var ChatQueue=require(_0x546d[3])[_0x546d[10]];var MailQueue=require(_0x546d[3])[_0x546d[11]];var FaxQueue=require(_0x546d[3])[_0x546d[12]];var SmsQueue=require(_0x546d[3])[_0x546d[13]];var MailRoom=require(_0x546d[3])[_0x546d[14]];var Setting=require(_0x546d[3])[_0x546d[15]];var Agent=require(_0x546d[3])[_0x546d[16]];var User=require(_0x546d[3])[_0x546d[16]];var Team=require(_0x546d[3])[_0x546d[17]];var List=require(_0x546d[3])[_0x546d[18]];exports[_0x546d[19]]= function(_0x1049x13,_0x1049x14,_0x1049x15){switch(_0x1049x13[_0x546d[28]][_0x546d[34]]){case _0x546d[28]:return User[_0x546d[29]](_0x1049x13[_0x546d[28]][_0x546d[27]],{attributes:[_0x546d[27]]})[_0x546d[24]](Util[_0x546d[26]](_0x1049x13[_0x546d[25]]))[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)});default:return Agent[_0x546d[33]](_0x546d[32])[_0x546d[31]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]]))[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){return handleError(_0x1049x14,_0x1049x16)})}};exports[_0x546d[35]]= function(_0x1049x13,_0x1049x14,_0x1049x15){return Agent[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]],{attributes:[_0x546d[27],_0x546d[40]]})[_0x546d[24]](function(_0x1049x19){if(!_0x1049x19){return _0x1049x14[_0x546d[36]](401)};switch(_0x1049x13[_0x546d[60]][_0x546d[59]]){case _0x546d[44]:return _0x1049x19[_0x546d[43]](_0x1049x13[_0x546d[38]][_0x546d[37]],{interface:util[_0x546d[41]](_0x546d[39],_0x1049x19[_0x546d[40]]),stateinterface:util[_0x546d[41]](_0x546d[39],_0x1049x19[_0x546d[40]]),membername:_0x1049x19[_0x546d[40]],UserId:_0x1049x19[_0x546d[27]],penalty:_0x1049x13[_0x546d[38]][_0x546d[42]]});case _0x546d[50]:return ChatQueue[_0x546d[49]]({where:{id:_0x1049x13[_0x546d[38]][_0x546d[37]]},attributes:[_0x546d[27],_0x546d[40]],raw:true})[_0x546d[24]](function(_0x1049x18){if(_0x1049x18){var _0x1049x1a=[];_[_0x546d[47]](_0x1049x18,function(_0x1049x1b){_0x1049x1a[_0x546d[46]](_0x1049x19[_0x546d[45]](_0x1049x1b[_0x546d[27]],{queue:_0x1049x1b[_0x546d[40]],penalty:_0x1049x13[_0x546d[38]][_0x546d[42]]}))});return BPromise[_0x546d[48]](_0x1049x1a)}});case _0x546d[52]:return MailQueue[_0x546d[49]]({where:{id:_0x1049x13[_0x546d[38]][_0x546d[37]]},attributes:[_0x546d[27],_0x546d[40]],raw:true})[_0x546d[24]](function(_0x1049x18){if(_0x1049x18){var _0x1049x1a=[];_[_0x546d[47]](_0x1049x18,function(_0x1049x1b){_0x1049x1a[_0x546d[46]](_0x1049x19[_0x546d[51]](_0x1049x1b[_0x546d[27]],{queue:_0x1049x1b[_0x546d[40]],penalty:_0x1049x13[_0x546d[38]][_0x546d[42]]}))});return BPromise[_0x546d[48]](_0x1049x1a)}});case _0x546d[54]:return FaxQueue[_0x546d[49]]({where:{id:_0x1049x13[_0x546d[38]][_0x546d[37]]},attributes:[_0x546d[27],_0x546d[40]],raw:true})[_0x546d[24]](function(_0x1049x18){if(_0x1049x18){var _0x1049x1a=[];_[_0x546d[47]](_0x1049x18,function(_0x1049x1b){_0x1049x1a[_0x546d[46]](_0x1049x19[_0x546d[53]](_0x1049x1b[_0x546d[27]],{queue:_0x1049x1b[_0x546d[40]],penalty:_0x1049x13[_0x546d[38]][_0x546d[42]]}))});return BPromise[_0x546d[48]](_0x1049x1a)}});case _0x546d[56]:return SmsQueue[_0x546d[49]]({where:{id:_0x1049x13[_0x546d[38]][_0x546d[37]]},attributes:[_0x546d[27],_0x546d[40]],raw:true})[_0x546d[24]](function(_0x1049x18){if(_0x1049x18){var _0x1049x1a=[];_[_0x546d[47]](_0x1049x18,function(_0x1049x1b){_0x1049x1a[_0x546d[46]](_0x1049x19[_0x546d[55]](_0x1049x1b[_0x546d[27]],{queue:_0x1049x1b[_0x546d[40]],penalty:_0x1049x13[_0x546d[38]][_0x546d[42]]}))});return BPromise[_0x546d[48]](_0x1049x1a)}});case _0x546d[58]:return OpenchannelQueue[_0x546d[49]]({where:{id:_0x1049x13[_0x546d[38]][_0x546d[37]]},attributes:[_0x546d[27],_0x546d[40]],raw:true})[_0x546d[24]](function(_0x1049x18){if(_0x1049x18){var _0x1049x1a=[];_[_0x546d[47]](_0x1049x18,function(_0x1049x1b){_0x1049x1a[_0x546d[46]](_0x1049x19[_0x546d[57]](_0x1049x1b[_0x546d[27]],{queue:_0x1049x1b[_0x546d[40]],penalty:_0x1049x13[_0x546d[38]][_0x546d[42]]}))});return BPromise[_0x546d[48]](_0x1049x1a)}});default:return null}})[_0x546d[24]](function(_0x1049x18){return _0x1049x14[_0x546d[36]](_0x1049x18?200:401)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16)})};exports[_0x546d[61]]= function(_0x1049x13,_0x1049x14,_0x1049x15){return Agent[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]],{attributes:[_0x546d[27]]})[_0x546d[24]](function(_0x1049x19){if(!_0x1049x19){return _0x1049x14[_0x546d[36]](401)};switch(_0x1049x13[_0x546d[60]][_0x546d[59]]){case _0x546d[44]:return _0x1049x19[_0x546d[63]](_0x1049x13[_0x546d[25]][_0x546d[62]]);case _0x546d[50]:return _0x1049x19[_0x546d[64]](_0x1049x13[_0x546d[25]][_0x546d[62]]);case _0x546d[52]:return _0x1049x19[_0x546d[65]](_0x1049x13[_0x546d[25]][_0x546d[62]]);case _0x546d[56]:return _0x1049x19[_0x546d[66]](_0x1049x13[_0x546d[25]][_0x546d[62]]);case _0x546d[54]:return _0x1049x19[_0x546d[67]](_0x1049x13[_0x546d[25]][_0x546d[62]]);case _0x546d[58]:return _0x1049x19[_0x546d[68]](_0x1049x13[_0x546d[25]][_0x546d[62]]);default:return null}})[_0x546d[24]](function(_0x1049x18){return _0x1049x14[_0x546d[36]](_0x1049x18?200:401)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16)})};exports[_0x546d[69]]= function(_0x1049x13,_0x1049x14,_0x1049x15){switch(_0x1049x13[_0x546d[28]][_0x546d[34]]){case _0x546d[28]:return User[_0x546d[29]](_0x1049x13[_0x546d[28]][_0x546d[27]],{attributes:[_0x546d[27]]})[_0x546d[24]](Util[_0x546d[26]](_0x1049x13[_0x546d[25]]))[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)});default:return Agent[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]})[_0x546d[31]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]]))[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)})}};exports[_0x546d[74]]= function(_0x1049x13,_0x1049x14,_0x1049x15){switch(_0x1049x13[_0x546d[28]][_0x546d[34]]){case _0x546d[28]:var _0x1049x1c=[];return User[_0x546d[29]](_0x1049x13[_0x546d[28]][_0x546d[27]],{attributes:[_0x546d[27]]})[_0x546d[24]](Util[_0x546d[79]]({},{attributes:[_0x546d[40]],include:[{raw:true,model:User,attributes:[_0x546d[27]]}]}))[_0x546d[24]](function(_0x1049x18){var _0x1049x1d=_[_0x546d[76]](_0x1049x18[_0x546d[75]],_0x546d[40]);_0x1049x18[_0x546d[75]][_0x546d[47]](function(_0x1049x1b){_0x1049x1c= _[_0x546d[77]](_0x1049x1c,_[_0x546d[76]](_0x1049x1b.Users,_0x546d[27]))});return User[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]})[_0x546d[31]](_[_0x546d[78]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]],{id:{$in:_0x1049x1c}}),{include:[{model:VoiceQueue,where:{name:{$in:_0x1049x1d}},required:false}]}))})[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)});default:return Agent[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]})[_0x546d[31]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]]))[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)})}};exports[_0x546d[80]]= function(_0x1049x13,_0x1049x14,_0x1049x15){switch(_0x1049x13[_0x546d[28]][_0x546d[34]]){case _0x546d[28]:var _0x1049x1c=[];return User[_0x546d[29]](_0x1049x13[_0x546d[28]][_0x546d[27]],{attributes:[_0x546d[27]]})[_0x546d[24]](Util[_0x546d[81]]({},{attributes:[_0x546d[27]],include:[{raw:true,model:User,attributes:[_0x546d[27]]}]}))[_0x546d[24]](function(_0x1049x18){var _0x1049x1e=_[_0x546d[76]](_0x1049x18[_0x546d[75]],_0x546d[27]);_0x1049x18[_0x546d[75]][_0x546d[47]](function(_0x1049x1b){_0x1049x1c= _[_0x546d[77]](_0x1049x1c,_[_0x546d[76]](_0x1049x1b.Users,_0x546d[27]))});return User[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]})[_0x546d[31]](_[_0x546d[78]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]],{id:{$in:_0x1049x1c}}),{include:[{model:ChatQueue,where:{id:{$in:_0x1049x1e}},required:false}]}))})[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)});default:return Agent[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]},_0x546d[82])[_0x546d[31]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]]))[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)})}};exports[_0x546d[83]]= function(_0x1049x13,_0x1049x14,_0x1049x15){switch(_0x1049x13[_0x546d[28]][_0x546d[34]]){case _0x546d[28]:var _0x1049x1c=[];return User[_0x546d[29]](_0x1049x13[_0x546d[28]][_0x546d[27]],{attributes:[_0x546d[27]]})[_0x546d[24]](Util[_0x546d[84]]({},{attributes:[_0x546d[27]],include:[{raw:true,model:User,attributes:[_0x546d[27]]}]}))[_0x546d[24]](function(_0x1049x18){var _0x1049x1f=_[_0x546d[76]](_0x1049x18[_0x546d[75]],_0x546d[27]);_0x1049x18[_0x546d[75]][_0x546d[47]](function(_0x1049x1b){_0x1049x1c= _[_0x546d[77]](_0x1049x1c,_[_0x546d[76]](_0x1049x1b.Users,_0x546d[27]))});return User[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]})[_0x546d[31]](_[_0x546d[78]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]],{id:{$in:_0x1049x1c}}),{include:[{model:MailQueue,where:{id:{$in:_0x1049x1f}},required:false}]}))})[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)});default:return Agent[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]},_0x546d[82])[_0x546d[31]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]]))[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)})}};exports[_0x546d[85]]= function(_0x1049x13,_0x1049x14,_0x1049x15){switch(_0x1049x13[_0x546d[28]][_0x546d[34]]){case _0x546d[28]:var _0x1049x1c=[];return User[_0x546d[29]](_0x1049x13[_0x546d[28]][_0x546d[27]],{attributes:[_0x546d[27]]})[_0x546d[24]](Util[_0x546d[86]]({},{attributes:[_0x546d[27]],include:[{raw:true,model:User,attributes:[_0x546d[27]]}]}))[_0x546d[24]](function(_0x1049x18){var _0x1049x20=_[_0x546d[76]](_0x1049x18[_0x546d[75]],_0x546d[27]);_0x1049x18[_0x546d[75]][_0x546d[47]](function(_0x1049x1b){_0x1049x1c= _[_0x546d[77]](_0x1049x1c,_[_0x546d[76]](_0x1049x1b.Users,_0x546d[27]))});return User[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]})[_0x546d[31]](_[_0x546d[78]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]],{id:{$in:_0x1049x1c}}),{include:[{model:FaxQueue,where:{id:{$in:_0x1049x20}},required:false}]}))})[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)});default:return Agent[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]},_0x546d[82])[_0x546d[31]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]]))[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)})}};exports[_0x546d[87]]= function(_0x1049x13,_0x1049x14,_0x1049x15){switch(_0x1049x13[_0x546d[28]][_0x546d[34]]){case _0x546d[28]:var _0x1049x1c=[];return User[_0x546d[29]](_0x1049x13[_0x546d[28]][_0x546d[27]],{attributes:[_0x546d[27]]})[_0x546d[24]](Util[_0x546d[88]]({},{attributes:[_0x546d[27]],include:[{raw:true,model:User,attributes:[_0x546d[27]]}]}))[_0x546d[24]](function(_0x1049x18){var _0x1049x21=_[_0x546d[76]](_0x1049x18[_0x546d[75]],_0x546d[27]);_0x1049x18[_0x546d[75]][_0x546d[47]](function(_0x1049x1b){_0x1049x1c= _[_0x546d[77]](_0x1049x1c,_[_0x546d[76]](_0x1049x1b.Users,_0x546d[27]))});return User[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]})[_0x546d[31]](_[_0x546d[78]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]],{id:{$in:_0x1049x1c}}),{include:[{model:SmsQueue,where:{id:{$in:_0x1049x21}},required:false}]}))})[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)});default:return Agent[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]},_0x546d[82])[_0x546d[31]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]]))[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)})}};exports[_0x546d[89]]= function(_0x1049x13,_0x1049x14,_0x1049x15){switch(_0x1049x13[_0x546d[28]][_0x546d[34]]){case _0x546d[28]:var _0x1049x1c=[];return User[_0x546d[29]](_0x1049x13[_0x546d[28]][_0x546d[27]],{attributes:[_0x546d[27]]})[_0x546d[24]](Util[_0x546d[90]]({},{attributes:[_0x546d[27]],include:[{raw:true,model:User,attributes:[_0x546d[27]]}]}))[_0x546d[24]](function(_0x1049x18){var _0x1049x22=_[_0x546d[76]](_0x1049x18[_0x546d[75]],_0x546d[27]);_0x1049x18[_0x546d[75]][_0x546d[47]](function(_0x1049x1b){_0x1049x1c= _[_0x546d[77]](_0x1049x1c,_[_0x546d[76]](_0x1049x1b.Users,_0x546d[27]))});return User[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]})[_0x546d[31]](_[_0x546d[78]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]],{id:{$in:_0x1049x1c}}),{include:[{model:OpenchannelQueue,where:{id:{$in:_0x1049x22}},required:false}]}))})[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)});default:return Agent[_0x546d[33]](_0x546d[32],{method:[_0x546d[70],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[71],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[72],_0x1049x13[_0x546d[25]]]},{method:[_0x546d[73],_0x1049x13[_0x546d[25]]]},_0x546d[82])[_0x546d[31]](Util[_0x546d[30]](_0x1049x13[_0x546d[25]]))[_0x546d[24]](function(_0x1049x17){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x17)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)})}};exports[_0x546d[91]]= function(_0x1049x13,_0x1049x14){return Agent[_0x546d[33]](_0x546d[32])[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]])[_0x546d[24]](function(_0x1049x19){if(!_0x1049x19){return _0x1049x14[_0x546d[36]](404)};return _0x1049x14[_0x546d[22]](_0x1049x19)})[_0x546d[21]](function(_0x1049x16){return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[92]]= function(_0x1049x13,_0x1049x14){return Agent[_0x546d[33]](_0x546d[32])[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]])[_0x546d[24]](function(_0x1049x19){if(!_0x1049x19){return _0x1049x14[_0x546d[36]](404)};return _0x1049x19[_0x546d[94]]({attributes:[_0x546d[40]]})})[_0x546d[24]](function(_0x1049x1d){return _0x1049x14[_0x546d[22]]({count:_0x1049x1d[_0x546d[93]],rows:_0x1049x1d})})[_0x546d[21]](function(_0x1049x16){return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[95]]= function(_0x1049x13,_0x1049x14){return Agent[_0x546d[33]](_0x546d[32])[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]])[_0x546d[24]](function(_0x1049x19){if(!_0x1049x19){return _0x1049x14[_0x546d[36]](404)};return _0x1049x19[_0x546d[96]]({attributes:[_0x546d[27]]})})[_0x546d[24]](function(_0x1049x1e){return _0x1049x14[_0x546d[22]]({count:_0x1049x1e[_0x546d[93]],rows:_0x1049x1e})})[_0x546d[21]](function(_0x1049x16){return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[97]]= function(_0x1049x13,_0x1049x14){return Agent[_0x546d[33]](_0x546d[32])[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]])[_0x546d[24]](function(_0x1049x19){if(!_0x1049x19){return _0x1049x14[_0x546d[36]](404)};return _0x1049x19[_0x546d[98]]({attributes:[_0x546d[27]]})})[_0x546d[24]](function(_0x1049x1f){return _0x1049x14[_0x546d[22]]({count:_0x1049x1f[_0x546d[93]],rows:_0x1049x1f})})[_0x546d[21]](function(_0x1049x16){return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[99]]= function(_0x1049x13,_0x1049x14){return Agent[_0x546d[33]](_0x546d[32])[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]])[_0x546d[24]](function(_0x1049x19){if(!_0x1049x19){return _0x1049x14[_0x546d[36]](404)};return _0x1049x19[_0x546d[100]]({attributes:[_0x546d[27]]})})[_0x546d[24]](function(_0x1049x20){return _0x1049x14[_0x546d[22]]({count:_0x1049x20[_0x546d[93]],rows:_0x1049x20})})[_0x546d[21]](function(_0x1049x16){return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[101]]= function(_0x1049x13,_0x1049x14){return Agent[_0x546d[33]](_0x546d[32])[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]])[_0x546d[24]](function(_0x1049x19){if(!_0x1049x19){return _0x1049x14[_0x546d[36]](404)};return _0x1049x19[_0x546d[102]]({attributes:[_0x546d[27]]})})[_0x546d[24]](function(_0x1049x21){return _0x1049x14[_0x546d[22]]({count:_0x1049x21[_0x546d[93]],rows:_0x1049x21})})[_0x546d[21]](function(_0x1049x16){return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[103]]= function(_0x1049x13,_0x1049x14){return Agent[_0x546d[33]](_0x546d[32])[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]])[_0x546d[24]](function(_0x1049x19){if(!_0x1049x19){return _0x1049x14[_0x546d[36]](404)};return _0x1049x19[_0x546d[104]]({attributes:[_0x546d[27]]})})[_0x546d[24]](function(_0x1049x23){return _0x1049x14[_0x546d[22]]({count:_0x1049x23[_0x546d[93]],rows:_0x1049x23})})[_0x546d[21]](function(_0x1049x16){return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[105]]= function(_0x1049x13,_0x1049x14){var _0x1049x24;_0x1049x13[_0x546d[38]][_0x546d[34]]= _0x546d[32];return sequelize[_0x546d[115]](function(_0x1049x25){return Setting[_0x546d[29]](1)[_0x546d[24]](function(_0x1049x27){var _0x1049x28=String(_0x1049x13[_0x546d[38]][_0x546d[111]]);var _0x1049x29=_0x1049x27[_0x546d[112]]?/^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[~!@#$%^&\-_=+\[\{\]\}.])[0-9a-zA-Z~!@#$%^&\-_=+\[\{\]\}.]{8,}$/:/^.{6,}$/;if(!_0x1049x29[_0x546d[113]](_0x1049x28)){throw  new Error(_0x546d[114])};return Agent[_0x546d[33]](_0x546d[32])[_0x546d[105]](_0x1049x13[_0x546d[38]],{transaction:_0x1049x25})})[_0x546d[24]](userTools[_0x546d[110]]({transaction:_0x1049x25}))[_0x546d[24]](function(_0x1049x19){_0x1049x24= _0x1049x19;return Team[_0x546d[109]]({where:{defaultEntry:true}})})[_0x546d[24]](function(_0x1049x26){return _0x1049x26[_0x546d[108]](_0x1049x24[_0x546d[27]],{transaction:_0x1049x25})})})[_0x546d[24]](function(){return _0x1049x14[_0x546d[23]](201)[_0x546d[22]](_0x1049x24)})[_0x546d[21]](sequelize.UniqueConstraintError,function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return Util[_0x546d[107]][_0x546d[106]](_0x1049x14,_0x1049x16)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[116]]= function(_0x1049x13,_0x1049x14){var _0x1049x2a;var _0x1049x2b;var _0x1049x2c=[];var _0x1049x28=String(_0x1049x13[_0x546d[38]][_0x546d[111]]);return sequelize[_0x546d[115]](function(_0x1049x25){return Setting[_0x546d[29]](1)[_0x546d[24]](function(_0x1049x27){_0x1049x2b= _0x1049x27;var _0x1049x29=_0x1049x2b[_0x546d[112]]?/^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[~!@#$%^&\-_=+\[\{\]\}.])[0-9a-zA-Z~!@#$%^&\-_=+\[\{\]\}.]{8,}$/:/^[a-zA-Z0-9]{6,}$/;if(!_0x1049x29[_0x546d[113]](_0x1049x28)){throw  new Error(_0x546d[118])};var _0x1049x2d=0;if(_0x1049x13[_0x546d[38]][_0x546d[120]](_0x546d[119])&& _[_0x546d[121]](_0x1049x13[_0x546d[38]][_0x546d[119]])&& _0x1049x13[_0x546d[38]][_0x546d[119]]>= 0){_0x1049x2d= _0x1049x13[_0x546d[38]][_0x546d[119]];delete _0x1049x13[_0x546d[38]][_0x546d[119]]};var _0x1049x2e=_0x1049x13[_0x546d[38]][_0x546d[122]];delete _0x1049x13[_0x546d[38]][_0x546d[122]];if(_0x1049x13[_0x546d[38]][_0x546d[123]]){_0x1049x13[_0x546d[38]][_0x546d[34]]= _0x546d[32];for(var _0x1049x2f=_0x1049x2d;_0x1049x2f< _0x1049x13[_0x546d[38]][_0x546d[123]]+ _0x1049x2d;_0x1049x2f++,_0x1049x2e++){var _0x1049x30=_[_0x546d[124]](_0x1049x13[_0x546d[38]]);_0x1049x30[_0x546d[125]]= _0x1049x2e;_0x1049x30[_0x546d[40]]= _0x1049x30[_0x546d[40]]+ _0x1049x2f;_0x1049x30[_0x546d[126]]= _0x1049x30[_0x546d[126]]+ _0x1049x2f;_0x1049x30[_0x546d[127]]= _0x1049x30[_0x546d[127]][_0x546d[129]](_0x546d[128])[0]+ _0x1049x2f+ _0x546d[128]+ _0x1049x30[_0x546d[127]][_0x546d[129]](_0x546d[128])[1];_0x1049x2c[_0x546d[46]](_0x1049x30)}}else {throw  new Error(_0x546d[130])};return Agent[_0x546d[116]](_0x1049x2c,{transaction:_0x1049x25,individualHooks:true})})[_0x546d[24]](function(_0x1049x1c){_0x1049x2a= _0x1049x1c;return Team[_0x546d[109]]({where:{defaultEntry:true}})})[_0x546d[24]](function(_0x1049x26){return _0x1049x26[_0x546d[117]](_[_0x546d[76]](_0x1049x2a,_0x546d[27]),{transaction:_0x1049x25})})})[_0x546d[24]](function(){return _0x1049x14[_0x546d[36]](201)})[_0x546d[21]](sequelize.UniqueConstraintError,function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return Util[_0x546d[107]][_0x546d[106]](_0x1049x14,_0x1049x16)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[131]]= function(_0x1049x13,_0x1049x14){if(_0x1049x13[_0x546d[38]][_0x546d[27]]){delete _0x1049x13[_0x546d[38]][_0x546d[27]]};delete _0x1049x13[_0x546d[38]][_0x546d[125]];delete _0x1049x13[_0x546d[38]][_0x546d[34]];delete _0x1049x13[_0x546d[38]][_0x546d[40]];delete _0x1049x13[_0x546d[38]][_0x546d[111]];var _0x1049x24;return sequelize[_0x546d[115]](function(_0x1049x25){return Agent[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]])[_0x546d[24]](function(_0x1049x19){if(!_0x1049x19){return _0x1049x14[_0x546d[36]](404)};var _0x1049x31=_[_0x546d[78]](_0x1049x19,_0x1049x13[_0x546d[38]]);return _0x1049x31[_0x546d[133]]({transaction:_0x1049x25})})[_0x546d[24]](function(_0x1049x19){_0x1049x24= _0x1049x19;return _0x1049x19})[_0x546d[24]](userTools[_0x546d[132]]({transaction:_0x1049x25}))[_0x546d[24]](function(){return _0x1049x14[_0x546d[23]](200)[_0x546d[22]](_0x1049x24)})})[_0x546d[21]](sequelize.UniqueConstraintError,function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return Util[_0x546d[107]][_0x546d[106]](_0x1049x14,_0x1049x16)})[_0x546d[21]](function(_0x1049x16){console[_0x546d[20]](_0x1049x16);return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[134]]= function(_0x1049x13,_0x1049x14){var _0x1049x24;return Agent[_0x546d[29]](_0x1049x13[_0x546d[60]][_0x546d[27]])[_0x546d[24]](function(_0x1049x19){_0x1049x24= _0x1049x19;if(!_0x1049x19){return _0x1049x14[_0x546d[36]](404)};return _0x1049x19[_0x546d[134]]()})[_0x546d[24]](function(){return _0x1049x14[_0x546d[36]](204)})[_0x546d[21]](sequelize.ForeignKeyConstraintError,function(_0x1049x16){return Util[_0x546d[107]][_0x546d[135]](_0x1049x14,_0x546d[32],_0x1049x24[_0x546d[40]],_0x1049x16)})[_0x546d[21]](function(_0x1049x16){return handleError(_0x1049x14,_0x1049x16)})};exports[_0x546d[136]]= function(_0x1049x13,_0x1049x14){return Agent[_0x546d[134]]({where:{id:_0x1049x13[_0x546d[25]][_0x546d[62]]},individualHooks:true})[_0x546d[24]](function(){return _0x1049x14[_0x546d[36]](204)})[_0x546d[21]](function(_0x1049x16){return handleError(_0x1049x14,_0x1049x16)})};function handleError(_0x1049x14,_0x1049x16){return _0x1049x14[_0x546d[23]](500)[_0x546d[22]](_0x1049x16)}
\ No newline at end of file