X-Git-Url: http://repos.xcallymotion.com/?a=blobdiff_plain;f=server%2Fapi%2FanalyticCustomReport%2FanalyticCustomReport.rpc.js;h=9421a4f717ac00bd04ec8f2d57bad950a4c92e7d;hb=44bd2814959684a7f7b774f2c71a3b12f9ba5952;hp=97a3f9245bed6e7dca1da7712910d94636388141;hpb=868a31873a4f5d6a45b7a9cfef882f2e311d37fa;p=motion2.git diff --git a/server/api/analyticCustomReport/analyticCustomReport.rpc.js b/server/api/analyticCustomReport/analyticCustomReport.rpc.js index 97a3f92..9421a4f 100644 --- a/server/api/analyticCustomReport/analyticCustomReport.rpc.js +++ b/server/api/analyticCustomReport/analyticCustomReport.rpc.js @@ -15,4 +15,4 @@ // * treaties. The SOFTWARE PRODUCT is licensed, not sold. * // * * // ************************************************************************* -var _0x30e9=['catch','lodash','moment','bluebird','ioredis','../../mysqldb','../../config/utils','rpc','../../config/environment','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'];(function(_0x5862e2,_0x1f7ad0){var _0x1640ec=function(_0x2fe79a){while(--_0x2fe79a){_0x5862e2['push'](_0x5862e2['shift']());}};_0x1640ec(++_0x1f7ad0);}(_0x30e9,0x12c));var _0x930e=function(_0x174ef5,_0x256e8e){_0x174ef5=_0x174ef5-0x0;var _0x1cc379=_0x30e9[_0x174ef5];return _0x1cc379;};'use strict';var _=require(_0x930e('0x0'));var util=require('util');var moment=require(_0x930e('0x1'));var BPromise=require(_0x930e('0x2'));var rs=require('randomstring');var fs=require('fs');var Redis=require(_0x930e('0x3'));var db=require(_0x930e('0x4'))['db'];var utils=require(_0x930e('0x5'));var logger=require('../../config/logger')(_0x930e('0x6'));var config=require(_0x930e('0x7'));var jayson=require(_0x930e('0x8'));var client=jayson[_0x930e('0x9')][_0x930e('0xa')]({'port':0x232a});function respondWithRpcPromise(_0x2b8e95,_0x192aba,_0x16c43b){return new BPromise(function(_0x4f25c4,_0x24bbc3){return client[_0x930e('0xb')](_0x2b8e95,_0x16c43b)[_0x930e('0xc')](function(_0x21c815){logger[_0x930e('0xd')](_0x930e('0xe'),_0x192aba,_0x930e('0xf'));logger[_0x930e('0x10')](_0x930e('0x11'),_0x192aba,'request\x20sent',JSON[_0x930e('0x12')](_0x21c815));if(_0x21c815[_0x930e('0x13')]){if(_0x21c815[_0x930e('0x13')][_0x930e('0x14')]===0x1f4){logger['error'](_0x930e('0xe'),_0x192aba,_0x21c815[_0x930e('0x13')][_0x930e('0x15')]);return _0x24bbc3(_0x21c815[_0x930e('0x13')][_0x930e('0x15')]);}logger[_0x930e('0x13')]('AnalyticCustomReport,\x20%s,\x20%s',_0x192aba,_0x21c815[_0x930e('0x13')]['message']);return _0x4f25c4(_0x21c815[_0x930e('0x13')][_0x930e('0x15')]);}else{logger[_0x930e('0xd')](_0x930e('0xe'),_0x192aba,'request\x20sent');_0x4f25c4(_0x21c815['result']['message']);}})[_0x930e('0x16')](function(_0x18fbc9){logger[_0x930e('0x13')](_0x930e('0xe'),_0x192aba,_0x18fbc9);_0x24bbc3(_0x18fbc9);});});} \ No newline at end of file +var _0xfbc1=['bluebird','randomstring','ioredis','../../config/utils','../../config/logger','rpc','../../config/environment','jayson/promise','client','then','AnalyticCustomReport,\x20%s,\x20%s','request\x20sent','stringify','error','code','message','info','result','catch','lodash','util','moment'];(function(_0x599d6b,_0x462aed){var _0x4bd9dd=function(_0x29e48d){while(--_0x29e48d){_0x599d6b['push'](_0x599d6b['shift']());}};_0x4bd9dd(++_0x462aed);}(_0xfbc1,0x11b));var _0x1fbc=function(_0xac151d,_0x4ea1d2){_0xac151d=_0xac151d-0x0;var _0x111dba=_0xfbc1[_0xac151d];return _0x111dba;};'use strict';var _=require(_0x1fbc('0x0'));var util=require(_0x1fbc('0x1'));var moment=require(_0x1fbc('0x2'));var BPromise=require(_0x1fbc('0x3'));var rs=require(_0x1fbc('0x4'));var fs=require('fs');var Redis=require(_0x1fbc('0x5'));var db=require('../../mysqldb')['db'];var utils=require(_0x1fbc('0x6'));var logger=require(_0x1fbc('0x7'))(_0x1fbc('0x8'));var config=require(_0x1fbc('0x9'));var jayson=require(_0x1fbc('0xa'));var client=jayson[_0x1fbc('0xb')]['http']({'port':0x232a});function respondWithRpcPromise(_0xf97519,_0x4f9c35,_0x505904){return new BPromise(function(_0x2b5be1,_0x2dfc70){return client['request'](_0xf97519,_0x505904)[_0x1fbc('0xc')](function(_0x4f0173){logger['info'](_0x1fbc('0xd'),_0x4f9c35,_0x1fbc('0xe'));logger['debug']('AnalyticCustomReport,\x20%s,\x20%s,\x20%s',_0x4f9c35,_0x1fbc('0xe'),JSON[_0x1fbc('0xf')](_0x4f0173));if(_0x4f0173[_0x1fbc('0x10')]){if(_0x4f0173['error'][_0x1fbc('0x11')]===0x1f4){logger[_0x1fbc('0x10')](_0x1fbc('0xd'),_0x4f9c35,_0x4f0173[_0x1fbc('0x10')][_0x1fbc('0x12')]);return _0x2dfc70(_0x4f0173[_0x1fbc('0x10')][_0x1fbc('0x12')]);}logger['error']('AnalyticCustomReport,\x20%s,\x20%s',_0x4f9c35,_0x4f0173['error']['message']);return _0x2b5be1(_0x4f0173[_0x1fbc('0x10')]['message']);}else{logger[_0x1fbc('0x13')](_0x1fbc('0xd'),_0x4f9c35,_0x1fbc('0xe'));_0x2b5be1(_0x4f0173[_0x1fbc('0x14')][_0x1fbc('0x12')]);}})[_0x1fbc('0x15')](function(_0x5517de){logger['error'](_0x1fbc('0xd'),_0x4f9c35,_0x5517de);_0x2dfc70(_0x5517de);});});} \ No newline at end of file