Built motion from commit 1020cd7.|0.0.107
[motion.git] / server / api / report_sms_room / report_sms_room.controller.js
index 0100a38..6f386e8 100644 (file)
@@ -1 +1 @@
-var _0x2e54=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x52\x65\x70\x6F\x72\x74\x53\x6D\x73\x52\x6F\x6F\x6D","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x53\x6D\x73\x52\x6F\x6F\x6D","\x52\x65\x70\x6F\x72\x74\x53\x6D\x73\x52\x6F\x6F\x6D\x48\x69\x73\x74\x6F\x72\x79","\x68\x69\x73\x74\x6F\x72\x79","\x55\x73\x65\x72","\x53\x6D\x73\x51\x75\x65\x75\x65","\x73\x65\x6E\x64","\x73\x74\x61\x74\x75\x73","\x6A\x73\x6F\x6E","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x65\x6E\x64","\x74\x68\x65\x6E","\x75\x70\x64\x61\x74\x65\x41\x74\x74\x72\x69\x62\x75\x74\x65\x73","\x64\x65\x73\x74\x72\x6F\x79","\x69\x64","\x6D\x61\x70","\x75\x6E\x69\x6F\x6E","\x66\x6F\x72\x45\x61\x63\x68","\x72\x6F\x77\x73","\x67\x65\x74\x53\x6D\x73\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x66\x69\x6E\x64\x42\x79\x49\x64","\x75\x73\x65\x72","\x72\x6F\x6C\x65","\x6F\x70\x65\x6E","\x63\x61\x74\x63\x68","\x4F\x50\x45\x4E","\x6D\x65\x72\x67\x65","\x63\x6F\x75\x6E\x74","\x61\x6C\x6C","\x63\x6C\x6F\x73\x65\x64","\x43\x4C\x4F\x53\x45\x44","\x6E\x65\x77","\x4E\x45\x57","\x75\x6E\x6D\x61\x6E\x61\x67\x65\x64","\x55\x4E\x4D\x41\x4E\x41\x47\x45\x44","\x69\x6E\x64\x65\x78","\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","\x64\x65\x73\x63\x72\x69\x62\x65"];_0x2e54[0];var _=require(_0x2e54[1]);var Util=require(_0x2e54[2]);var ReportSmsRoom=require(_0x2e54[4])[_0x2e54[3]];var SmsRoom=require(_0x2e54[4])[_0x2e54[5]];var ReportSmsRoomHistory=require(_0x2e54[4])[_0x2e54[7]][_0x2e54[6]];var User=require(_0x2e54[4])[_0x2e54[8]];var SmsQueue=require(_0x2e54[4])[_0x2e54[9]];function handleError(_0x42a7x9,_0x42a7xa){_0x42a7xa=_0x42a7xa||500;return function(_0x42a7xb){_0x42a7x9[_0x2e54[11]](_0x42a7xa)[_0x2e54[10]](_0x42a7xb)}}function responseWithResult(_0x42a7x9,_0x42a7xa){_0x42a7xa=_0x42a7xa||200;return function(_0x42a7xd){if(_0x42a7xd){_0x42a7x9[_0x2e54[11]](_0x42a7xa)[_0x2e54[12]](_0x42a7xd)}}}function responseWithoutResult(_0x42a7x9,_0x42a7xa){_0x42a7xa=_0x42a7xa||204;return function(){_0x42a7x9[_0x2e54[13]](_0x42a7xa)}}function handleEntityNotFound(_0x42a7x9){return function(_0x42a7xd){if(!_0x42a7xd){_0x42a7x9[_0x2e54[11]](404)[_0x2e54[14]]();return null};return _0x42a7xd}}function saveUpdates(_0x42a7x11){return function(_0x42a7xd){return _0x42a7xd[_0x2e54[16]](_0x42a7x11)[_0x2e54[15]](function(_0x42a7x12){return _0x42a7x12})}}function removeEntity(_0x42a7x9){return function(_0x42a7xd){if(_0x42a7xd){return _0x42a7xd[_0x2e54[17]]()[_0x2e54[15]](function(){_0x42a7x9[_0x2e54[11]](204)[_0x2e54[14]]()})}}}function getSmsQueues(_0x42a7x15){return function(){switch(_0x42a7x15[_0x2e54[26]]){case _0x2e54[25]:return User[_0x2e54[24]](_0x42a7x15[_0x2e54[18]],{attributes:[_0x2e54[18]]})[_0x2e54[15]](Util[_0x2e54[23]]({},{attributes:[_0x2e54[18]],include:[{raw:true,model:User,attributes:[_0x2e54[18]]}]}))[_0x2e54[15]](function(_0x42a7x16){var _0x42a7x17=[];_0x42a7x16[_0x2e54[22]][_0x2e54[21]](function(_0x42a7x18){_0x42a7x17=_[_0x2e54[20]](_0x42a7x17,_[_0x2e54[19]](_0x42a7x18.Users,_0x2e54[18]))});return {where:{$or:{queue:_[_0x2e54[19]](_0x42a7x16[_0x2e54[22]],_0x2e54[18]),memberid:_0x42a7x17}}}});default:return {}}}}exports[_0x2e54[27]]=function(_0x42a7x19,_0x42a7x9){return Promise[_0x2e54[32]]([])[_0x2e54[15]](getSmsQueues(_0x42a7x19[_0x2e54[25]]))[_0x2e54[15]](function(_0x42a7x1b){return SmsRoom[_0x2e54[31]](_[_0x2e54[30]]({where:{status:_0x2e54[29]}},_0x42a7x1b))})[_0x2e54[15]](function(_0x42a7x1a){return _0x42a7x9[_0x2e54[11]](200)[_0x2e54[10]]({value:_0x42a7x1a})})[_0x2e54[28]](handleError(_0x42a7x9))};exports[_0x2e54[33]]=function(_0x42a7x19,_0x42a7x9){return Promise[_0x2e54[32]]([])[_0x2e54[15]](getSmsQueues(_0x42a7x19[_0x2e54[25]]))[_0x2e54[15]](function(_0x42a7x1b){return SmsRoom[_0x2e54[31]](_[_0x2e54[30]]({where:{status:_0x2e54[34]}},_0x42a7x1b))})[_0x2e54[15]](function(_0x42a7x1a){return _0x42a7x9[_0x2e54[11]](200)[_0x2e54[10]]({value:_0x42a7x1a})})[_0x2e54[28]](handleError(_0x42a7x9))};exports[_0x2e54[35]]=function(_0x42a7x19,_0x42a7x9){return Promise[_0x2e54[32]]([])[_0x2e54[15]](getSmsQueues(_0x42a7x19[_0x2e54[25]]))[_0x2e54[15]](function(_0x42a7x1b){return SmsRoom[_0x2e54[31]](_[_0x2e54[30]]({where:{status:_0x2e54[36]}},_0x42a7x1b))})[_0x2e54[15]](function(_0x42a7x1a){return _0x42a7x9[_0x2e54[11]](200)[_0x2e54[10]]({value:_0x42a7x1a})})[_0x2e54[28]](handleError(_0x42a7x9))};exports[_0x2e54[37]]=function(_0x42a7x19,_0x42a7x9){return Promise[_0x2e54[32]]([])[_0x2e54[15]](getSmsQueues(_0x42a7x19[_0x2e54[25]]))[_0x2e54[15]](function(_0x42a7x1b){return SmsRoom[_0x2e54[31]](_[_0x2e54[30]]({where:{status:_0x2e54[38]}},_0x42a7x1b))})[_0x2e54[15]](function(_0x42a7x1a){return _0x42a7x9[_0x2e54[11]](200)[_0x2e54[10]]({value:_0x42a7x1a})})[_0x2e54[28]](handleError(_0x42a7x9))};exports[_0x2e54[39]]=function(_0x42a7x19,_0x42a7x9,_0x42a7x1c){return ReportSmsRoom[_0x2e54[42]](Util[_0x2e54[41]](_0x42a7x19[_0x2e54[40]]))[_0x2e54[15]](function(_0x42a7x1d){return _0x42a7x9[_0x2e54[11]](200)[_0x2e54[10]](_0x42a7x1d)})[_0x2e54[28]](handleError(_0x42a7x9))};exports[_0x2e54[43]]=function(_0x42a7x19,_0x42a7x9){return ReportSmsRoomHistory[_0x2e54[43]]()[_0x2e54[15]](responseWithResult(_0x42a7x9))[_0x2e54[28]](handleError(_0x42a7x9))}
\ No newline at end of file
+var _0x2fcc=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x6C\x6F\x64\x61\x73\x68","\x2E\x2E\x2F\x2E\x2E\x2F\x63\x6F\x6E\x66\x69\x67\x2F\x75\x74\x69\x6C","\x52\x65\x70\x6F\x72\x74\x53\x6D\x73\x52\x6F\x6F\x6D","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x53\x6D\x73\x52\x6F\x6F\x6D","\x52\x65\x70\x6F\x72\x74\x53\x6D\x73\x52\x6F\x6F\x6D\x48\x69\x73\x74\x6F\x72\x79","\x68\x69\x73\x74\x6F\x72\x79","\x55\x73\x65\x72","\x53\x6D\x73\x51\x75\x65\x75\x65","\x73\x65\x6E\x64","\x73\x74\x61\x74\x75\x73","\x6A\x73\x6F\x6E","\x73\x65\x6E\x64\x53\x74\x61\x74\x75\x73","\x65\x6E\x64","\x74\x68\x65\x6E","\x75\x70\x64\x61\x74\x65\x41\x74\x74\x72\x69\x62\x75\x74\x65\x73","\x64\x65\x73\x74\x72\x6F\x79","\x69\x64","\x6D\x61\x70","\x75\x6E\x69\x6F\x6E","\x66\x6F\x72\x45\x61\x63\x68","\x72\x6F\x77\x73","\x67\x65\x74\x53\x6D\x73\x51\x75\x65\x75\x65\x73\x49\x64\x42\x79\x55\x73\x65\x72","\x66\x69\x6E\x64\x42\x79\x49\x64","\x75\x73\x65\x72","\x72\x6F\x6C\x65","\x6F\x70\x65\x6E","\x63\x61\x74\x63\x68","\x4F\x50\x45\x4E","\x6D\x65\x72\x67\x65","\x63\x6F\x75\x6E\x74","\x61\x6C\x6C","\x63\x6C\x6F\x73\x65\x64","\x43\x4C\x4F\x53\x45\x44","\x6E\x65\x77","\x4E\x45\x57","\x75\x6E\x6D\x61\x6E\x61\x67\x65\x64","\x55\x4E\x4D\x41\x4E\x41\x47\x45\x44","\x69\x6E\x64\x65\x78","\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","\x64\x65\x73\x63\x72\x69\x62\x65"];_0x2fcc[0];var _=require(_0x2fcc[1]);var Util=require(_0x2fcc[2]);var ReportSmsRoom=require(_0x2fcc[4])[_0x2fcc[3]];var SmsRoom=require(_0x2fcc[4])[_0x2fcc[5]];var ReportSmsRoomHistory=require(_0x2fcc[4])[_0x2fcc[7]][_0x2fcc[6]];var User=require(_0x2fcc[4])[_0x2fcc[8]];var SmsQueue=require(_0x2fcc[4])[_0x2fcc[9]];function handleError(_0x2db1x9,_0x2db1xa){_0x2db1xa=_0x2db1xa||500;return function(_0x2db1xb){_0x2db1x9[_0x2fcc[11]](_0x2db1xa)[_0x2fcc[10]](_0x2db1xb)}}function responseWithResult(_0x2db1x9,_0x2db1xa){_0x2db1xa=_0x2db1xa||200;return function(_0x2db1xd){if(_0x2db1xd){_0x2db1x9[_0x2fcc[11]](_0x2db1xa)[_0x2fcc[12]](_0x2db1xd)}}}function responseWithoutResult(_0x2db1x9,_0x2db1xa){_0x2db1xa=_0x2db1xa||204;return function(){_0x2db1x9[_0x2fcc[13]](_0x2db1xa)}}function handleEntityNotFound(_0x2db1x9){return function(_0x2db1xd){if(!_0x2db1xd){_0x2db1x9[_0x2fcc[11]](404)[_0x2fcc[14]]();return null};return _0x2db1xd}}function saveUpdates(_0x2db1x11){return function(_0x2db1xd){return _0x2db1xd[_0x2fcc[16]](_0x2db1x11)[_0x2fcc[15]](function(_0x2db1x12){return _0x2db1x12})}}function removeEntity(_0x2db1x9){return function(_0x2db1xd){if(_0x2db1xd){return _0x2db1xd[_0x2fcc[17]]()[_0x2fcc[15]](function(){_0x2db1x9[_0x2fcc[11]](204)[_0x2fcc[14]]()})}}}function getSmsQueues(_0x2db1x15){return function(){switch(_0x2db1x15[_0x2fcc[26]]){case _0x2fcc[25]:return User[_0x2fcc[24]](_0x2db1x15[_0x2fcc[18]],{attributes:[_0x2fcc[18]]})[_0x2fcc[15]](Util[_0x2fcc[23]]({},{attributes:[_0x2fcc[18]],include:[{raw:true,model:User,attributes:[_0x2fcc[18]]}]}))[_0x2fcc[15]](function(_0x2db1x16){var _0x2db1x17=[];_0x2db1x16[_0x2fcc[22]][_0x2fcc[21]](function(_0x2db1x18){_0x2db1x17=_[_0x2fcc[20]](_0x2db1x17,_[_0x2fcc[19]](_0x2db1x18.Users,_0x2fcc[18]))});return {where:{$or:{queue:_[_0x2fcc[19]](_0x2db1x16[_0x2fcc[22]],_0x2fcc[18]),memberid:_0x2db1x17}}}});default:return {}}}}exports[_0x2fcc[27]]=function(_0x2db1x19,_0x2db1x9){return Promise[_0x2fcc[32]]([])[_0x2fcc[15]](getSmsQueues(_0x2db1x19[_0x2fcc[25]]))[_0x2fcc[15]](function(_0x2db1x1b){return SmsRoom[_0x2fcc[31]](_[_0x2fcc[30]]({where:{status:_0x2fcc[29]}},_0x2db1x1b))})[_0x2fcc[15]](function(_0x2db1x1a){return _0x2db1x9[_0x2fcc[11]](200)[_0x2fcc[10]]({value:_0x2db1x1a})})[_0x2fcc[28]](handleError(_0x2db1x9))};exports[_0x2fcc[33]]=function(_0x2db1x19,_0x2db1x9){return Promise[_0x2fcc[32]]([])[_0x2fcc[15]](getSmsQueues(_0x2db1x19[_0x2fcc[25]]))[_0x2fcc[15]](function(_0x2db1x1b){return SmsRoom[_0x2fcc[31]](_[_0x2fcc[30]]({where:{status:_0x2fcc[34]}},_0x2db1x1b))})[_0x2fcc[15]](function(_0x2db1x1a){return _0x2db1x9[_0x2fcc[11]](200)[_0x2fcc[10]]({value:_0x2db1x1a})})[_0x2fcc[28]](handleError(_0x2db1x9))};exports[_0x2fcc[35]]=function(_0x2db1x19,_0x2db1x9){return Promise[_0x2fcc[32]]([])[_0x2fcc[15]](getSmsQueues(_0x2db1x19[_0x2fcc[25]]))[_0x2fcc[15]](function(_0x2db1x1b){return SmsRoom[_0x2fcc[31]](_[_0x2fcc[30]]({where:{status:_0x2fcc[36]}},_0x2db1x1b))})[_0x2fcc[15]](function(_0x2db1x1a){return _0x2db1x9[_0x2fcc[11]](200)[_0x2fcc[10]]({value:_0x2db1x1a})})[_0x2fcc[28]](handleError(_0x2db1x9))};exports[_0x2fcc[37]]=function(_0x2db1x19,_0x2db1x9){return Promise[_0x2fcc[32]]([])[_0x2fcc[15]](getSmsQueues(_0x2db1x19[_0x2fcc[25]]))[_0x2fcc[15]](function(_0x2db1x1b){return SmsRoom[_0x2fcc[31]](_[_0x2fcc[30]]({where:{status:_0x2fcc[38]}},_0x2db1x1b))})[_0x2fcc[15]](function(_0x2db1x1a){return _0x2db1x9[_0x2fcc[11]](200)[_0x2fcc[10]]({value:_0x2db1x1a})})[_0x2fcc[28]](handleError(_0x2db1x9))};exports[_0x2fcc[39]]=function(_0x2db1x19,_0x2db1x9,_0x2db1x1c){return ReportSmsRoom[_0x2fcc[42]](Util[_0x2fcc[41]](_0x2db1x19[_0x2fcc[40]]))[_0x2fcc[15]](function(_0x2db1x1d){return _0x2db1x9[_0x2fcc[11]](200)[_0x2fcc[10]](_0x2db1x1d)})[_0x2fcc[28]](handleError(_0x2db1x9))};exports[_0x2fcc[43]]=function(_0x2db1x19,_0x2db1x9){return ReportSmsRoomHistory[_0x2fcc[43]]()[_0x2fcc[15]](responseWithResult(_0x2db1x9))[_0x2fcc[28]](handleError(_0x2db1x9))}
\ No newline at end of file