Built motion from commit ce2081a.|0.0.133
[motion.git] / server / api / report_mail / report_mail.controller.js
index 66998e6..8a7c7b0 100644 (file)
@@ -1 +1 @@
-var _0xffc9=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x6D\x6F\x6D\x65\x6E\x74","\x52\x65\x70\x6F\x72\x74\x4D\x61\x69\x6C","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x73\x65\x71\x75\x65\x6C\x69\x7A\x65","\x55\x73\x65\x72","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x69\x6E\x64\x65\x78","\x63\x61\x74\x63\x68","\x73\x65\x6E\x64","\x73\x74\x61\x74\x75\x73","\x74\x68\x65\x6E","\x71\x75\x65\x72\x79","\x67\x65\x74\x51\x75\x65\x72\x79","\x66\x69\x6E\x64\x41\x6E\x64\x43\x6F\x75\x6E\x74\x41\x6C\x6C","\x61\x63\x63\x65\x70\x74","\x2E","\x73\x70\x6C\x69\x74","\x75\x6E\x69\x71\x75\x65\x69\x64","\x70\x61\x72\x61\x6D\x73","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x6D\x65\x72\x67\x65","\x73\x61\x76\x65","\x69\x64","\x66\x69\x6E\x64\x42\x79\x49\x64","\x43\x4C\x4F\x53\x45\x44","\x67\x65\x74\x4D\x61\x69\x6C\x52\x6F\x6F\x6D\x73","\x75\x73\x65\x72","\x6D\x61\x69\x6C\x43\x61\x70\x61\x63\x69\x74\x79","\x72\x65\x6A\x65\x63\x74","\x59\x59\x59\x59\x2D\x4D\x4D\x2D\x44\x44\x20\x48\x48\x3A\x6D\x6D\x3A\x73\x73","\x66\x6F\x72\x6D\x61\x74"];_0xffc9[0];var _=require(_0xffc9[1]);var moment=require(_0xffc9[2]);var ReportMail=require(_0xffc9[4])[_0xffc9[3]];var sequelize=require(_0xffc9[4])[_0xffc9[5]];var Agent=require(_0xffc9[4])[_0xffc9[6]];var Util=require(_0xffc9[7]);exports[_0xffc9[8]]=function(_0x7980x7,_0x7980x8,_0x7980x9){return ReportMail[_0xffc9[15]](Util[_0xffc9[14]](_0x7980x7[_0xffc9[13]]))[_0xffc9[12]](function(_0x7980xb){_0x7980x8[_0xffc9[11]](200)[_0xffc9[10]](_0x7980xb)})[_0xffc9[9]](function(_0x7980xa){return handleError(_0x7980x8,_0x7980xa)})};exports[_0xffc9[16]]=function(_0x7980x7,_0x7980x8){var _0x7980xc;var _0x7980xd=_0x7980x7[_0xffc9[20]][_0xffc9[19]][_0xffc9[18]](_0xffc9[17])[1];return Agent[_0xffc9[25]](_0x7980x7[_0xffc9[28]][_0xffc9[24]],{attributes:[_0xffc9[24],_0xffc9[29]]})[_0xffc9[12]](function(_0x7980x11){_0x7980xc=_0x7980x11;return _0x7980x11[_0xffc9[27]]({where:{status:{$ne:_0xffc9[26]},id:{$ne:_0x7980xd}},attributes:[_0xffc9[24]]})})[_0xffc9[12]](function(_0x7980x10){return ReportMail[_0xffc9[25]](_0x7980x7[_0xffc9[20]][_0xffc9[24]])})[_0xffc9[12]](function(_0x7980xe){if(!_0x7980xe){return _0x7980x8[_0xffc9[21]](404)};var _0x7980xf=_[_0xffc9[22]](_0x7980xe,{connectid:_0x7980x7[_0xffc9[20]][_0xffc9[19]]});return _0x7980xf[_0xffc9[23]]()})[_0xffc9[12]](function(){return _0x7980x8[_0xffc9[21]](200)})[_0xffc9[9]](function(_0x7980xa){return handleError(_0x7980x8,_0x7980xa)})};exports[_0xffc9[30]]=function(_0x7980x7,_0x7980x8){return ReportMail[_0xffc9[25]](_0x7980x7[_0xffc9[20]][_0xffc9[24]])[_0xffc9[12]](function(_0x7980xe){if(!_0x7980xe){return _0x7980x8[_0xffc9[21]](404)};var _0x7980xf=_[_0xffc9[22]](_0x7980xe,{rejectedAt:moment()[_0xffc9[32]](_0xffc9[31])});return _0x7980xf[_0xffc9[23]]()})[_0xffc9[12]](function(){return _0x7980x8[_0xffc9[21]](200)})[_0xffc9[9]](function(_0x7980xa){return handleError(_0x7980x8,_0x7980xa)})};function handleError(_0x7980x8,_0x7980xa){return _0x7980x8[_0xffc9[11]](500)[_0xffc9[10]](_0x7980xa)}
\ No newline at end of file
+var _0x849c=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x6D\x6F\x6D\x65\x6E\x74","\x52\x65\x70\x6F\x72\x74\x4D\x61\x69\x6C","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x4D\x61\x69\x6C\x52\x6F\x6F\x6D","\x4D\x61\x69\x6C\x52\x6F\x6F\x6D\x53\x74\x61\x74\x75\x73","\x73\x65\x71\x75\x65\x6C\x69\x7A\x65","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x69\x6E\x64\x65\x78","\x72\x6F\x6C\x65","\x75\x73\x65\x72","\x61\x67\x65\x6E\x74","\x6D\x65\x6D\x62\x65\x72\x6E\x61\x6D\x65","\x6E\x61\x6D\x65","\x63\x61\x74\x63\x68","\x73\x65\x6E\x64","\x73\x74\x61\x74\x75\x73","\x74\x68\x65\x6E","\x71\x75\x65\x72\x79","\x67\x65\x74\x51\x75\x65\x72\x79","\x66\x69\x6E\x64\x41\x6E\x64\x43\x6F\x75\x6E\x74\x41\x6C\x6C","\x61\x63\x63\x65\x70\x74","\x2E","\x73\x70\x6C\x69\x74","\x75\x6E\x69\x71\x75\x65\x69\x64","\x70\x61\x72\x61\x6D\x73","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x4F\x50\x45\x4E","\x75\x70\x64\x61\x74\x65","\x6D\x65\x72\x67\x65","\x73\x61\x76\x65","\x69\x64","\x66\x69\x6E\x64\x42\x79\x49\x64","\x72\x65\x6A\x65\x63\x74","\x52\x45\x4A\x45\x43\x54","\x66\x75\x6C\x6C\x6E\x61\x6D\x65","\x72\x6F\x6F\x6D\x69\x64","\x63\x72\x65\x61\x74\x65","\x59\x59\x59\x59\x2D\x4D\x4D\x2D\x44\x44\x20\x48\x48\x3A\x6D\x6D\x3A\x73\x73","\x66\x6F\x72\x6D\x61\x74","\x6C\x6F\x67"];_0x849c[0];var _=require(_0x849c[1]);var moment=require(_0x849c[2]);var Report=require(_0x849c[4])[_0x849c[3]];var Room=require(_0x849c[4])[_0x849c[5]];var Status=require(_0x849c[4])[_0x849c[6]];var sequelize=require(_0x849c[4])[_0x849c[7]];var Util=require(_0x849c[8]);exports[_0x849c[9]]= function(_0x4cb2x8,_0x4cb2x9,_0x4cb2xa){var _0x4cb2xb={};if(_0x4cb2x8[_0x849c[11]][_0x849c[10]]=== _0x849c[12]){_0x4cb2xb[_0x849c[13]]= _0x4cb2x8[_0x849c[11]][_0x849c[14]]};return Report[_0x849c[21]](Util[_0x849c[20]](_0x4cb2x8[_0x849c[19]],_0x4cb2xb))[_0x849c[18]](function(_0x4cb2xd){_0x4cb2x9[_0x849c[17]](200)[_0x849c[16]](_0x4cb2xd)})[_0x849c[15]](function(_0x4cb2xc){return handleError(_0x4cb2x9,_0x4cb2xc)})};exports[_0x849c[22]]= function(_0x4cb2x8,_0x4cb2x9){var _0x4cb2xe=_0x4cb2x8[_0x849c[26]][_0x849c[25]][_0x849c[24]](_0x849c[23])[1];return Report[_0x849c[33]](_0x4cb2x8[_0x849c[26]][_0x849c[32]])[_0x849c[18]](function(_0x4cb2xf){if(!_0x4cb2xf){return _0x4cb2x9[_0x849c[27]](404)};var _0x4cb2x10=_[_0x849c[30]](_0x4cb2xf,{connectid:_0x4cb2x8[_0x849c[26]][_0x849c[25]]});return _0x4cb2x10[_0x849c[31]]()})[_0x849c[18]](function(){return Room[_0x849c[29]]({status:_0x849c[28],openReason:_0x849c[12]},{where:{id:_0x4cb2xe},user:_0x4cb2x8[_0x849c[11]],individualHooks:true})})[_0x849c[18]](function(){return _0x4cb2x9[_0x849c[27]](200)})[_0x849c[15]](sequelize.UniqueConstraintError,function(_0x4cb2xc){return _0x4cb2x9[_0x849c[27]](504)})[_0x849c[15]](function(_0x4cb2xc){return handleError(_0x4cb2x9,_0x4cb2xc)})};exports[_0x849c[34]]= function(_0x4cb2x8,_0x4cb2x9){var _0x4cb2x11;return Report[_0x849c[33]](_0x4cb2x8[_0x849c[26]][_0x849c[32]])[_0x849c[18]](function(_0x4cb2x12){_0x4cb2x11= _0x4cb2x12;if(!_0x4cb2x11){return _0x4cb2x9[_0x849c[27]](404)};var _0x4cb2x10=_[_0x849c[30]](_0x4cb2x12,{rejectedAt:moment()[_0x849c[40]](_0x849c[39])});return _0x4cb2x10[_0x849c[31]]()})[_0x849c[18]](function(){return Status[_0x849c[38]]({status:_0x849c[35],data1:_0x4cb2x8[_0x849c[11]][_0x849c[14]],data2:_0x4cb2x8[_0x849c[11]][_0x849c[36]],UserId:_0x4cb2x8[_0x849c[11]][_0x849c[32]],MailRoomId:_0x4cb2x11[_0x849c[37]]})})[_0x849c[18]](function(){return _0x4cb2x9[_0x849c[27]](200)})[_0x849c[15]](function(_0x4cb2xc){return handleError(_0x4cb2x9,_0x4cb2xc)})};function handleError(_0x4cb2x9,_0x4cb2xc){console[_0x849c[41]](_0x4cb2xc);return _0x4cb2x9[_0x849c[17]](500)[_0x849c[16]](_0x4cb2xc)}
\ No newline at end of file