Built motion from commit 497d3d92.|2.5.43
[motion2.git] / server / api / cmCompany / cmCompany.rpc.js
index 83f5249..55fa2d9 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x889d=['request\x20sent','debug','stringify','error','code','message','result','catch','lodash','util','bluebird','randomstring','../../mysqldb','../../config/utils','../../config/logger','rpc','../../config/environment','jayson/promise','client','request','then','info','CmCompany,\x20%s,\x20%s'];(function(_0x56e422,_0x443ad9){var _0x5954a8=function(_0x3f50bb){while(--_0x3f50bb){_0x56e422['push'](_0x56e422['shift']());}};_0x5954a8(++_0x443ad9);}(_0x889d,0x105));var _0xd889=function(_0x5d20ca,_0x1613ce){_0x5d20ca=_0x5d20ca-0x0;var _0x9d185c=_0x889d[_0x5d20ca];return _0x9d185c;};'use strict';var _=require(_0xd889('0x0'));var util=require(_0xd889('0x1'));var moment=require('moment');var BPromise=require(_0xd889('0x2'));var rs=require(_0xd889('0x3'));var fs=require('fs');var Redis=require('ioredis');var db=require(_0xd889('0x4'))['db'];var utils=require(_0xd889('0x5'));var logger=require(_0xd889('0x6'))(_0xd889('0x7'));var config=require(_0xd889('0x8'));var jayson=require(_0xd889('0x9'));var client=jayson[_0xd889('0xa')]['http']({'port':0x232a});function respondWithRpcPromise(_0x2e107f,_0x7736ba,_0x5d3946){return new BPromise(function(_0x5b4856,_0xf21f11){return client[_0xd889('0xb')](_0x2e107f,_0x5d3946)[_0xd889('0xc')](function(_0x36063b){logger[_0xd889('0xd')](_0xd889('0xe'),_0x7736ba,_0xd889('0xf'));logger[_0xd889('0x10')]('CmCompany,\x20%s,\x20%s,\x20%s',_0x7736ba,_0xd889('0xf'),JSON[_0xd889('0x11')](_0x36063b));if(_0x36063b[_0xd889('0x12')]){if(_0x36063b['error'][_0xd889('0x13')]===0x1f4){logger[_0xd889('0x12')](_0xd889('0xe'),_0x7736ba,_0x36063b[_0xd889('0x12')][_0xd889('0x14')]);return _0xf21f11(_0x36063b[_0xd889('0x12')][_0xd889('0x14')]);}logger['error']('CmCompany,\x20%s,\x20%s',_0x7736ba,_0x36063b[_0xd889('0x12')][_0xd889('0x14')]);return _0x5b4856(_0x36063b[_0xd889('0x12')]['message']);}else{logger[_0xd889('0xd')](_0xd889('0xe'),_0x7736ba,_0xd889('0xf'));_0x5b4856(_0x36063b[_0xd889('0x15')][_0xd889('0x14')]);}})[_0xd889('0x16')](function(_0x29bf47){logger[_0xd889('0x12')](_0xd889('0xe'),_0x7736ba,_0x29bf47);_0xf21f11(_0x29bf47);});});}
\ No newline at end of file
+var _0x45d8=['request\x20sent','debug','stringify','error','code','CmCompany,\x20%s,\x20%s','message','result','catch','lodash','moment','bluebird','randomstring','ioredis','../../mysqldb','../../config/logger','jayson/promise','http','request','then','info'];(function(_0x502c7d,_0x2f1285){var _0x30b7ed=function(_0x2d92f3){while(--_0x2d92f3){_0x502c7d['push'](_0x502c7d['shift']());}};_0x30b7ed(++_0x2f1285);}(_0x45d8,0x11a));var _0x845d=function(_0x366776,_0x48f0bf){_0x366776=_0x366776-0x0;var _0x34e2ad=_0x45d8[_0x366776];return _0x34e2ad;};'use strict';var _=require(_0x845d('0x0'));var util=require('util');var moment=require(_0x845d('0x1'));var BPromise=require(_0x845d('0x2'));var rs=require(_0x845d('0x3'));var fs=require('fs');var Redis=require(_0x845d('0x4'));var db=require(_0x845d('0x5'))['db'];var utils=require('../../config/utils');var logger=require(_0x845d('0x6'))('rpc');var config=require('../../config/environment');var jayson=require(_0x845d('0x7'));var client=jayson['client'][_0x845d('0x8')]({'port':0x232a});function respondWithRpcPromise(_0x1bd978,_0x35452a,_0x45df9f){return new BPromise(function(_0x5f0644,_0x5f13ec){return client[_0x845d('0x9')](_0x1bd978,_0x45df9f)[_0x845d('0xa')](function(_0x4ef69f){logger[_0x845d('0xb')]('CmCompany,\x20%s,\x20%s',_0x35452a,_0x845d('0xc'));logger[_0x845d('0xd')]('CmCompany,\x20%s,\x20%s,\x20%s',_0x35452a,_0x845d('0xc'),JSON[_0x845d('0xe')](_0x4ef69f));if(_0x4ef69f[_0x845d('0xf')]){if(_0x4ef69f['error'][_0x845d('0x10')]===0x1f4){logger[_0x845d('0xf')](_0x845d('0x11'),_0x35452a,_0x4ef69f[_0x845d('0xf')][_0x845d('0x12')]);return _0x5f13ec(_0x4ef69f['error']['message']);}logger[_0x845d('0xf')](_0x845d('0x11'),_0x35452a,_0x4ef69f[_0x845d('0xf')][_0x845d('0x12')]);return _0x5f0644(_0x4ef69f['error']['message']);}else{logger[_0x845d('0xb')](_0x845d('0x11'),_0x35452a,_0x845d('0xc'));_0x5f0644(_0x4ef69f[_0x845d('0x13')][_0x845d('0x12')]);}})[_0x845d('0x14')](function(_0x557b3f){logger['error'](_0x845d('0x11'),_0x35452a,_0x557b3f);_0x5f13ec(_0x557b3f);});});}
\ No newline at end of file