Built motion from commit bab6f49e.|2.6.17
[motion2.git] / server / api / cmCompany / cmCompany.rpc.js
index 89b2921..1338742 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xe1b7=['result','catch','lodash','util','moment','bluebird','randomstring','ioredis','../../config/utils','../../config/logger','rpc','../../config/environment','jayson/promise','client','http','request','then','info','CmCompany,\x20%s,\x20%s','request\x20sent','debug','CmCompany,\x20%s,\x20%s,\x20%s','stringify','error','message'];(function(_0xe961d5,_0xabcb0d){var _0x3cf8c3=function(_0x273d93){while(--_0x273d93){_0xe961d5['push'](_0xe961d5['shift']());}};_0x3cf8c3(++_0xabcb0d);}(_0xe1b7,0x179));var _0x7e1b=function(_0x2219bd,_0x9cfd12){_0x2219bd=_0x2219bd-0x0;var _0xb72639=_0xe1b7[_0x2219bd];return _0xb72639;};'use strict';var _=require(_0x7e1b('0x0'));var util=require(_0x7e1b('0x1'));var moment=require(_0x7e1b('0x2'));var BPromise=require(_0x7e1b('0x3'));var rs=require(_0x7e1b('0x4'));var fs=require('fs');var Redis=require(_0x7e1b('0x5'));var db=require('../../mysqldb')['db'];var utils=require(_0x7e1b('0x6'));var logger=require(_0x7e1b('0x7'))(_0x7e1b('0x8'));var config=require(_0x7e1b('0x9'));var jayson=require(_0x7e1b('0xa'));var client=jayson[_0x7e1b('0xb')][_0x7e1b('0xc')]({'port':0x232a});function respondWithRpcPromise(_0x515fc2,_0xaf42c,_0x5c610e){return new BPromise(function(_0x2a4339,_0x14e303){return client[_0x7e1b('0xd')](_0x515fc2,_0x5c610e)[_0x7e1b('0xe')](function(_0x501a17){logger[_0x7e1b('0xf')](_0x7e1b('0x10'),_0xaf42c,_0x7e1b('0x11'));logger[_0x7e1b('0x12')](_0x7e1b('0x13'),_0xaf42c,'request\x20sent',JSON[_0x7e1b('0x14')](_0x501a17));if(_0x501a17[_0x7e1b('0x15')]){if(_0x501a17[_0x7e1b('0x15')]['code']===0x1f4){logger['error'](_0x7e1b('0x10'),_0xaf42c,_0x501a17['error'][_0x7e1b('0x16')]);return _0x14e303(_0x501a17['error']['message']);}logger[_0x7e1b('0x15')](_0x7e1b('0x10'),_0xaf42c,_0x501a17['error'][_0x7e1b('0x16')]);return _0x2a4339(_0x501a17[_0x7e1b('0x15')][_0x7e1b('0x16')]);}else{logger[_0x7e1b('0xf')](_0x7e1b('0x10'),_0xaf42c,_0x7e1b('0x11'));_0x2a4339(_0x501a17[_0x7e1b('0x17')]['message']);}})[_0x7e1b('0x18')](function(_0x4746bd){logger[_0x7e1b('0x15')](_0x7e1b('0x10'),_0xaf42c,_0x4746bd);_0x14e303(_0x4746bd);});});}
\ No newline at end of file
+var _0x5796=['ioredis','../../mysqldb','../../config/logger','rpc','../../config/environment','jayson/promise','request','then','info','CmCompany,\x20%s,\x20%s','request\x20sent','debug','stringify','error','code','message','result','catch','lodash','moment','bluebird','randomstring'];(function(_0x538c70,_0x35531f){var _0x42ae01=function(_0x5c7368){while(--_0x5c7368){_0x538c70['push'](_0x538c70['shift']());}};_0x42ae01(++_0x35531f);}(_0x5796,0x6a));var _0x6579=function(_0x1d0c88,_0x30dfbe){_0x1d0c88=_0x1d0c88-0x0;var _0x1196ae=_0x5796[_0x1d0c88];return _0x1196ae;};'use strict';var _=require(_0x6579('0x0'));var util=require('util');var moment=require(_0x6579('0x1'));var BPromise=require(_0x6579('0x2'));var rs=require(_0x6579('0x3'));var fs=require('fs');var Redis=require(_0x6579('0x4'));var db=require(_0x6579('0x5'))['db'];var utils=require('../../config/utils');var logger=require(_0x6579('0x6'))(_0x6579('0x7'));var config=require(_0x6579('0x8'));var jayson=require(_0x6579('0x9'));var client=jayson['client']['http']({'port':0x232a});function respondWithRpcPromise(_0x10eedb,_0xb30a97,_0xd522c0){return new BPromise(function(_0x19b590,_0xc792cc){return client[_0x6579('0xa')](_0x10eedb,_0xd522c0)[_0x6579('0xb')](function(_0x3de2cc){logger[_0x6579('0xc')](_0x6579('0xd'),_0xb30a97,_0x6579('0xe'));logger[_0x6579('0xf')]('CmCompany,\x20%s,\x20%s,\x20%s',_0xb30a97,_0x6579('0xe'),JSON[_0x6579('0x10')](_0x3de2cc));if(_0x3de2cc[_0x6579('0x11')]){if(_0x3de2cc[_0x6579('0x11')][_0x6579('0x12')]===0x1f4){logger['error'](_0x6579('0xd'),_0xb30a97,_0x3de2cc[_0x6579('0x11')][_0x6579('0x13')]);return _0xc792cc(_0x3de2cc[_0x6579('0x11')][_0x6579('0x13')]);}logger[_0x6579('0x11')](_0x6579('0xd'),_0xb30a97,_0x3de2cc['error'][_0x6579('0x13')]);return _0x19b590(_0x3de2cc[_0x6579('0x11')][_0x6579('0x13')]);}else{logger[_0x6579('0xc')](_0x6579('0xd'),_0xb30a97,_0x6579('0xe'));_0x19b590(_0x3de2cc[_0x6579('0x14')][_0x6579('0x13')]);}})[_0x6579('0x15')](function(_0x3e2fa8){logger[_0x6579('0x11')](_0x6579('0xd'),_0xb30a97,_0x3e2fa8);_0xc792cc(_0x3e2fa8);});});}
\ No newline at end of file