Built motion from commit (unavailable).|2.5.28
[motion2.git] / server / api / mailServerIn / mailServerIn.rpc.js
index f89dc77..356d2fd 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x3c3d=['options','raw','where','attributes','limit','include','model','map','debug','stringify','lodash','util','moment','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','../../config/environment','jayson/promise','client','http','then','MailServerIn,\x20%s,\x20%s','request\x20sent','error','code','message','info','result','catch','GetMailServerIn','findAll'];(function(_0x23c69c,_0x21a72a){var _0x2271b0=function(_0x3e517f){while(--_0x3e517f){_0x23c69c['push'](_0x23c69c['shift']());}};_0x2271b0(++_0x21a72a);}(_0x3c3d,0x133));var _0xd3c3=function(_0x3d3afe,_0x26df42){_0x3d3afe=_0x3d3afe-0x0;var _0x213370=_0x3c3d[_0x3d3afe];return _0x213370;};'use strict';var _=require(_0xd3c3('0x0'));var util=require(_0xd3c3('0x1'));var moment=require(_0xd3c3('0x2'));var BPromise=require('bluebird');var rs=require(_0xd3c3('0x3'));var fs=require('fs');var Redis=require(_0xd3c3('0x4'));var db=require(_0xd3c3('0x5'))['db'];var utils=require(_0xd3c3('0x6'));var logger=require(_0xd3c3('0x7'))('rpc');var config=require(_0xd3c3('0x8'));var jayson=require(_0xd3c3('0x9'));var client=jayson[_0xd3c3('0xa')][_0xd3c3('0xb')]({'port':0x232a});function respondWithRpcPromise(_0x8e0f9d,_0xb18649,_0x500696){return new BPromise(function(_0xc3825d,_0x3903e4){return client['request'](_0x8e0f9d,_0x500696)[_0xd3c3('0xc')](function(_0x2d4850){logger['info'](_0xd3c3('0xd'),_0xb18649,_0xd3c3('0xe'));logger['debug']('MailServerIn,\x20%s,\x20%s,\x20%s',_0xb18649,'request\x20sent',JSON['stringify'](_0x2d4850));if(_0x2d4850['error']){if(_0x2d4850[_0xd3c3('0xf')][_0xd3c3('0x10')]===0x1f4){logger['error'](_0xd3c3('0xd'),_0xb18649,_0x2d4850[_0xd3c3('0xf')][_0xd3c3('0x11')]);return _0x3903e4(_0x2d4850[_0xd3c3('0xf')][_0xd3c3('0x11')]);}logger['error'](_0xd3c3('0xd'),_0xb18649,_0x2d4850[_0xd3c3('0xf')]['message']);return _0xc3825d(_0x2d4850[_0xd3c3('0xf')][_0xd3c3('0x11')]);}else{logger[_0xd3c3('0x12')](_0xd3c3('0xd'),_0xb18649,_0xd3c3('0xe'));_0xc3825d(_0x2d4850[_0xd3c3('0x13')]['message']);}})[_0xd3c3('0x14')](function(_0x4aeb3f){logger['error'](_0xd3c3('0xd'),_0xb18649,_0x4aeb3f);_0x3903e4(_0x4aeb3f);});});}exports[_0xd3c3('0x15')]=function(_0x50afb7){var _0x4ae3bd=this;return new Promise(function(_0x55e454,_0x407d98){return db['MailServerIn'][_0xd3c3('0x16')]({'raw':_0x50afb7[_0xd3c3('0x17')]?_0x50afb7[_0xd3c3('0x17')][_0xd3c3('0x18')]===undefined?!![]:![]:!![],'where':_0x50afb7['options']?_0x50afb7[_0xd3c3('0x17')][_0xd3c3('0x19')]||null:null,'attributes':_0x50afb7[_0xd3c3('0x17')]?_0x50afb7['options'][_0xd3c3('0x1a')]||null:null,'limit':_0x50afb7['options']?_0x50afb7[_0xd3c3('0x17')][_0xd3c3('0x1b')]||null:null,'include':_0x50afb7['options']?_0x50afb7[_0xd3c3('0x17')]['include']?_['map'](_0x50afb7[_0xd3c3('0x17')][_0xd3c3('0x1c')],function(_0x14aa81){return{'model':db[_0x14aa81[_0xd3c3('0x1d')]],'as':_0x14aa81['as'],'attributes':_0x14aa81[_0xd3c3('0x1a')],'include':_0x14aa81['include']?_[_0xd3c3('0x1e')](_0x14aa81[_0xd3c3('0x1c')],function(_0x42dc64){return{'model':db[_0x42dc64[_0xd3c3('0x1d')]],'as':_0x42dc64['as'],'attributes':_0x42dc64[_0xd3c3('0x1a')],'include':_0x42dc64['include']?_[_0xd3c3('0x1e')](_0x42dc64[_0xd3c3('0x1c')],function(_0x138492){return{'model':db[_0x138492[_0xd3c3('0x1d')]],'as':_0x138492['as'],'attributes':_0x138492[_0xd3c3('0x1a')]};}):[]};}):[]};}):[]:[]})[_0xd3c3('0xc')](function(_0x1d961c){logger[_0xd3c3('0x12')]('GetMailServerIn',_0x50afb7);logger[_0xd3c3('0x1f')](_0xd3c3('0x15'),_0x50afb7,JSON[_0xd3c3('0x20')](_0x1d961c));_0x55e454(_0x1d961c);})[_0xd3c3('0x14')](function(_0x3e17bf){logger[_0xd3c3('0xf')]('GetMailServerIn',_0x3e17bf[_0xd3c3('0x11')],_0x50afb7);_0x407d98(_0x4ae3bd[_0xd3c3('0xf')](0x1f4,_0x3e17bf[_0xd3c3('0x11')]));});});};
\ No newline at end of file
+var _0x31e2=['../../config/environment','jayson/promise','http','request','info','MailServerIn,\x20%s,\x20%s','request\x20sent','MailServerIn,\x20%s,\x20%s,\x20%s','stringify','error','code','message','result','GetMailServerIn','MailServerIn','findAll','options','raw','where','limit','include','map','attributes','model','then','debug','catch','moment','bluebird','randomstring','../../mysqldb','../../config/logger','rpc'];(function(_0x43b584,_0x20a6bd){var _0x48f27b=function(_0x1eeb77){while(--_0x1eeb77){_0x43b584['push'](_0x43b584['shift']());}};_0x48f27b(++_0x20a6bd);}(_0x31e2,0x7e));var _0x231e=function(_0x585d09,_0x1274bc){_0x585d09=_0x585d09-0x0;var _0x7d9a14=_0x31e2[_0x585d09];return _0x7d9a14;};'use strict';var _=require('lodash');var util=require('util');var moment=require(_0x231e('0x0'));var BPromise=require(_0x231e('0x1'));var rs=require(_0x231e('0x2'));var fs=require('fs');var Redis=require('ioredis');var db=require(_0x231e('0x3'))['db'];var utils=require('../../config/utils');var logger=require(_0x231e('0x4'))(_0x231e('0x5'));var config=require(_0x231e('0x6'));var jayson=require(_0x231e('0x7'));var client=jayson['client'][_0x231e('0x8')]({'port':0x232a});function respondWithRpcPromise(_0x3488f3,_0x241b7c,_0x2a1818){return new BPromise(function(_0x1e0346,_0x10987a){return client[_0x231e('0x9')](_0x3488f3,_0x2a1818)['then'](function(_0xb04176){logger[_0x231e('0xa')](_0x231e('0xb'),_0x241b7c,_0x231e('0xc'));logger['debug'](_0x231e('0xd'),_0x241b7c,_0x231e('0xc'),JSON[_0x231e('0xe')](_0xb04176));if(_0xb04176[_0x231e('0xf')]){if(_0xb04176['error'][_0x231e('0x10')]===0x1f4){logger['error'](_0x231e('0xb'),_0x241b7c,_0xb04176[_0x231e('0xf')][_0x231e('0x11')]);return _0x10987a(_0xb04176[_0x231e('0xf')][_0x231e('0x11')]);}logger['error'](_0x231e('0xb'),_0x241b7c,_0xb04176[_0x231e('0xf')]['message']);return _0x1e0346(_0xb04176['error']['message']);}else{logger[_0x231e('0xa')](_0x231e('0xb'),_0x241b7c,_0x231e('0xc'));_0x1e0346(_0xb04176[_0x231e('0x12')][_0x231e('0x11')]);}})['catch'](function(_0x35a557){logger['error'](_0x231e('0xb'),_0x241b7c,_0x35a557);_0x10987a(_0x35a557);});});}exports[_0x231e('0x13')]=function(_0xc63c83){var _0x25b8f0=this;return new Promise(function(_0xdff6b,_0x30af39){return db[_0x231e('0x14')][_0x231e('0x15')]({'raw':_0xc63c83[_0x231e('0x16')]?_0xc63c83['options'][_0x231e('0x17')]===undefined?!![]:![]:!![],'where':_0xc63c83[_0x231e('0x16')]?_0xc63c83[_0x231e('0x16')][_0x231e('0x18')]||null:null,'attributes':_0xc63c83['options']?_0xc63c83[_0x231e('0x16')]['attributes']||null:null,'limit':_0xc63c83[_0x231e('0x16')]?_0xc63c83[_0x231e('0x16')][_0x231e('0x19')]||null:null,'include':_0xc63c83[_0x231e('0x16')]?_0xc63c83['options'][_0x231e('0x1a')]?_[_0x231e('0x1b')](_0xc63c83[_0x231e('0x16')][_0x231e('0x1a')],function(_0xe4e2d){return{'model':db[_0xe4e2d['model']],'as':_0xe4e2d['as'],'attributes':_0xe4e2d[_0x231e('0x1c')],'include':_0xe4e2d['include']?_[_0x231e('0x1b')](_0xe4e2d[_0x231e('0x1a')],function(_0x11323c){return{'model':db[_0x11323c[_0x231e('0x1d')]],'as':_0x11323c['as'],'attributes':_0x11323c[_0x231e('0x1c')],'include':_0x11323c[_0x231e('0x1a')]?_[_0x231e('0x1b')](_0x11323c[_0x231e('0x1a')],function(_0x56126b){return{'model':db[_0x56126b['model']],'as':_0x56126b['as'],'attributes':_0x56126b['attributes']};}):[]};}):[]};}):[]:[]})[_0x231e('0x1e')](function(_0x2ef298){logger[_0x231e('0xa')]('GetMailServerIn',_0xc63c83);logger[_0x231e('0x1f')](_0x231e('0x13'),_0xc63c83,JSON['stringify'](_0x2ef298));_0xdff6b(_0x2ef298);})[_0x231e('0x20')](function(_0x100e64){logger[_0x231e('0xf')](_0x231e('0x13'),_0x100e64[_0x231e('0x11')],_0xc63c83);_0x30af39(_0x25b8f0[_0x231e('0xf')](0x1f4,_0x100e64[_0x231e('0x11')]));});});};
\ No newline at end of file