Built motion from commit 85328c08.|2.5.50
[motion2.git] / server / api / analyticCustomReport / analyticCustomReport.rpc.js
index 7eea0c1..3363988 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xd41f=['jayson/promise','http','request','then','info','AnalyticCustomReport,\x20%s,\x20%s','stringify','code','error','message','request\x20sent','result','catch','util','moment','randomstring','ioredis','../../mysqldb','../../config/utils'];(function(_0x17d9e3,_0x1f969c){var _0x14192d=function(_0x159745){while(--_0x159745){_0x17d9e3['push'](_0x17d9e3['shift']());}};_0x14192d(++_0x1f969c);}(_0xd41f,0xf1));var _0xfd41=function(_0x321bb2,_0x202794){_0x321bb2=_0x321bb2-0x0;var _0x9c12ed=_0xd41f[_0x321bb2];return _0x9c12ed;};'use strict';var _=require('lodash');var util=require(_0xfd41('0x0'));var moment=require(_0xfd41('0x1'));var BPromise=require('bluebird');var rs=require(_0xfd41('0x2'));var fs=require('fs');var Redis=require(_0xfd41('0x3'));var db=require(_0xfd41('0x4'))['db'];var utils=require(_0xfd41('0x5'));var logger=require('../../config/logger')('rpc');var config=require('../../config/environment');var jayson=require(_0xfd41('0x6'));var client=jayson['client'][_0xfd41('0x7')]({'port':0x232a});function respondWithRpcPromise(_0x5a1f71,_0x3c4ba2,_0x289c13){return new BPromise(function(_0x5e9bf2,_0x898a79){return client[_0xfd41('0x8')](_0x5a1f71,_0x289c13)[_0xfd41('0x9')](function(_0x4fdd6f){logger[_0xfd41('0xa')](_0xfd41('0xb'),_0x3c4ba2,'request\x20sent');logger['debug']('AnalyticCustomReport,\x20%s,\x20%s,\x20%s',_0x3c4ba2,'request\x20sent',JSON[_0xfd41('0xc')](_0x4fdd6f));if(_0x4fdd6f['error']){if(_0x4fdd6f['error'][_0xfd41('0xd')]===0x1f4){logger[_0xfd41('0xe')]('AnalyticCustomReport,\x20%s,\x20%s',_0x3c4ba2,_0x4fdd6f[_0xfd41('0xe')]['message']);return _0x898a79(_0x4fdd6f['error'][_0xfd41('0xf')]);}logger[_0xfd41('0xe')]('AnalyticCustomReport,\x20%s,\x20%s',_0x3c4ba2,_0x4fdd6f[_0xfd41('0xe')][_0xfd41('0xf')]);return _0x5e9bf2(_0x4fdd6f[_0xfd41('0xe')][_0xfd41('0xf')]);}else{logger[_0xfd41('0xa')](_0xfd41('0xb'),_0x3c4ba2,_0xfd41('0x10'));_0x5e9bf2(_0x4fdd6f[_0xfd41('0x11')][_0xfd41('0xf')]);}})[_0xfd41('0x12')](function(_0x5b9868){logger[_0xfd41('0xe')](_0xfd41('0xb'),_0x3c4ba2,_0x5b9868);_0x898a79(_0x5b9868);});});}
\ No newline at end of file
+var _0x89f9=['jayson/promise','client','http','request','then','info','AnalyticCustomReport,\x20%s,\x20%s','request\x20sent','debug','AnalyticCustomReport,\x20%s,\x20%s,\x20%s','stringify','error','code','message','result','lodash','util','moment','bluebird','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','../../config/environment'];(function(_0x2ca9d4,_0x51d5c6){var _0x258956=function(_0x47a0e5){while(--_0x47a0e5){_0x2ca9d4['push'](_0x2ca9d4['shift']());}};_0x258956(++_0x51d5c6);}(_0x89f9,0x19f));var _0x989f=function(_0x37f9ae,_0x577eaa){_0x37f9ae=_0x37f9ae-0x0;var _0x53fbb4=_0x89f9[_0x37f9ae];return _0x53fbb4;};'use strict';var _=require(_0x989f('0x0'));var util=require(_0x989f('0x1'));var moment=require(_0x989f('0x2'));var BPromise=require(_0x989f('0x3'));var rs=require(_0x989f('0x4'));var fs=require('fs');var Redis=require(_0x989f('0x5'));var db=require(_0x989f('0x6'))['db'];var utils=require(_0x989f('0x7'));var logger=require(_0x989f('0x8'))('rpc');var config=require(_0x989f('0x9'));var jayson=require(_0x989f('0xa'));var client=jayson[_0x989f('0xb')][_0x989f('0xc')]({'port':0x232a});function respondWithRpcPromise(_0x307247,_0x47d120,_0x2838cc){return new BPromise(function(_0x1e71b6,_0xb66a36){return client[_0x989f('0xd')](_0x307247,_0x2838cc)[_0x989f('0xe')](function(_0x30bf90){logger[_0x989f('0xf')](_0x989f('0x10'),_0x47d120,_0x989f('0x11'));logger[_0x989f('0x12')](_0x989f('0x13'),_0x47d120,_0x989f('0x11'),JSON[_0x989f('0x14')](_0x30bf90));if(_0x30bf90[_0x989f('0x15')]){if(_0x30bf90['error'][_0x989f('0x16')]===0x1f4){logger['error']('AnalyticCustomReport,\x20%s,\x20%s',_0x47d120,_0x30bf90['error'][_0x989f('0x17')]);return _0xb66a36(_0x30bf90['error'][_0x989f('0x17')]);}logger[_0x989f('0x15')](_0x989f('0x10'),_0x47d120,_0x30bf90[_0x989f('0x15')][_0x989f('0x17')]);return _0x1e71b6(_0x30bf90['error']['message']);}else{logger[_0x989f('0xf')](_0x989f('0x10'),_0x47d120,_0x989f('0x11'));_0x1e71b6(_0x30bf90[_0x989f('0x18')][_0x989f('0x17')]);}})['catch'](function(_0x291e61){logger['error'](_0x989f('0x10'),_0x47d120,_0x291e61);_0xb66a36(_0x291e61);});});}
\ No newline at end of file