Built motion from commit 092f8824.|2.5.49
[motion2.git] / server / api / analyticDefaultReport / analyticDefaultReport.rpc.js
index af351c3..dbd1850 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xa3b7=['info','AnalyticDefaultReport,\x20%s,\x20%s','request\x20sent','debug','stringify','error','code','message','result','catch','lodash','moment','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','rpc','../../config/environment','client','http','then'];(function(_0x2c0ded,_0x3de22c){var _0x4473e5=function(_0x3705bc){while(--_0x3705bc){_0x2c0ded['push'](_0x2c0ded['shift']());}};_0x4473e5(++_0x3de22c);}(_0xa3b7,0xe6));var _0x7a3b=function(_0x1f62c3,_0x1ff95b){_0x1f62c3=_0x1f62c3-0x0;var _0x385c1c=_0xa3b7[_0x1f62c3];return _0x385c1c;};'use strict';var _=require(_0x7a3b('0x0'));var util=require('util');var moment=require(_0x7a3b('0x1'));var BPromise=require('bluebird');var rs=require(_0x7a3b('0x2'));var fs=require('fs');var Redis=require(_0x7a3b('0x3'));var db=require(_0x7a3b('0x4'))['db'];var utils=require(_0x7a3b('0x5'));var logger=require(_0x7a3b('0x6'))(_0x7a3b('0x7'));var config=require(_0x7a3b('0x8'));var jayson=require('jayson/promise');var client=jayson[_0x7a3b('0x9')][_0x7a3b('0xa')]({'port':0x232a});function respondWithRpcPromise(_0x31274f,_0x43c083,_0x63f93d){return new BPromise(function(_0x560f45,_0x1d6e53){return client['request'](_0x31274f,_0x63f93d)[_0x7a3b('0xb')](function(_0x60adf9){logger[_0x7a3b('0xc')](_0x7a3b('0xd'),_0x43c083,_0x7a3b('0xe'));logger[_0x7a3b('0xf')]('AnalyticDefaultReport,\x20%s,\x20%s,\x20%s',_0x43c083,_0x7a3b('0xe'),JSON[_0x7a3b('0x10')](_0x60adf9));if(_0x60adf9[_0x7a3b('0x11')]){if(_0x60adf9['error'][_0x7a3b('0x12')]===0x1f4){logger[_0x7a3b('0x11')]('AnalyticDefaultReport,\x20%s,\x20%s',_0x43c083,_0x60adf9[_0x7a3b('0x11')][_0x7a3b('0x13')]);return _0x1d6e53(_0x60adf9[_0x7a3b('0x11')]['message']);}logger[_0x7a3b('0x11')](_0x7a3b('0xd'),_0x43c083,_0x60adf9[_0x7a3b('0x11')]['message']);return _0x560f45(_0x60adf9[_0x7a3b('0x11')][_0x7a3b('0x13')]);}else{logger['info'](_0x7a3b('0xd'),_0x43c083,_0x7a3b('0xe'));_0x560f45(_0x60adf9[_0x7a3b('0x14')]['message']);}})[_0x7a3b('0x15')](function(_0x414a5b){logger['error'](_0x7a3b('0xd'),_0x43c083,_0x414a5b);_0x1d6e53(_0x414a5b);});});}
\ No newline at end of file
+var _0x9f79=['AnalyticDefaultReport,\x20%s,\x20%s','debug','AnalyticDefaultReport,\x20%s,\x20%s,\x20%s','request\x20sent','stringify','error','message','result','catch','bluebird','randomstring','ioredis','../../config/utils','../../config/logger','rpc','../../config/environment','jayson/promise','client','http','request','then','info'];(function(_0x46a9a4,_0x537b75){var _0x49765c=function(_0x3c0a6e){while(--_0x3c0a6e){_0x46a9a4['push'](_0x46a9a4['shift']());}};_0x49765c(++_0x537b75);}(_0x9f79,0x169));var _0x99f7=function(_0x1f53f0,_0x11ef35){_0x1f53f0=_0x1f53f0-0x0;var _0xe4da66=_0x9f79[_0x1f53f0];return _0xe4da66;};'use strict';var _=require('lodash');var util=require('util');var moment=require('moment');var BPromise=require(_0x99f7('0x0'));var rs=require(_0x99f7('0x1'));var fs=require('fs');var Redis=require(_0x99f7('0x2'));var db=require('../../mysqldb')['db'];var utils=require(_0x99f7('0x3'));var logger=require(_0x99f7('0x4'))(_0x99f7('0x5'));var config=require(_0x99f7('0x6'));var jayson=require(_0x99f7('0x7'));var client=jayson[_0x99f7('0x8')][_0x99f7('0x9')]({'port':0x232a});function respondWithRpcPromise(_0x36fa11,_0x2f0bd0,_0x130673){return new BPromise(function(_0x347b64,_0x56f36d){return client[_0x99f7('0xa')](_0x36fa11,_0x130673)[_0x99f7('0xb')](function(_0x4404ad){logger[_0x99f7('0xc')](_0x99f7('0xd'),_0x2f0bd0,'request\x20sent');logger[_0x99f7('0xe')](_0x99f7('0xf'),_0x2f0bd0,_0x99f7('0x10'),JSON[_0x99f7('0x11')](_0x4404ad));if(_0x4404ad[_0x99f7('0x12')]){if(_0x4404ad[_0x99f7('0x12')]['code']===0x1f4){logger[_0x99f7('0x12')](_0x99f7('0xd'),_0x2f0bd0,_0x4404ad[_0x99f7('0x12')][_0x99f7('0x13')]);return _0x56f36d(_0x4404ad[_0x99f7('0x12')][_0x99f7('0x13')]);}logger['error']('AnalyticDefaultReport,\x20%s,\x20%s',_0x2f0bd0,_0x4404ad[_0x99f7('0x12')][_0x99f7('0x13')]);return _0x347b64(_0x4404ad[_0x99f7('0x12')][_0x99f7('0x13')]);}else{logger[_0x99f7('0xc')](_0x99f7('0xd'),_0x2f0bd0,_0x99f7('0x10'));_0x347b64(_0x4404ad[_0x99f7('0x14')][_0x99f7('0x13')]);}})[_0x99f7('0x15')](function(_0x33e53d){logger[_0x99f7('0x12')](_0x99f7('0xd'),_0x2f0bd0,_0x33e53d);_0x56f36d(_0x33e53d);});});}
\ No newline at end of file