Built motion from commit (unavailable).|2.5.29
[motion2.git] / server / api / smsApplication / smsApplication.rpc.js
index 76ad19e..6fc1acf 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x95f4=['../../config/environment','jayson/promise','http','request','info','request\x20sent','SmsApplication,\x20%s,\x20%s,\x20%s','stringify','error','code','SmsApplication,\x20%s,\x20%s','message','result','lodash','util','moment','ioredis','../../mysqldb','rpc'];(function(_0x562faa,_0x23adc7){var _0xc70f59=function(_0x2d7dec){while(--_0x2d7dec){_0x562faa['push'](_0x562faa['shift']());}};_0xc70f59(++_0x23adc7);}(_0x95f4,0xf1));var _0x495f=function(_0x48726d,_0x4106fb){_0x48726d=_0x48726d-0x0;var _0x4a60f6=_0x95f4[_0x48726d];return _0x4a60f6;};'use strict';var _=require(_0x495f('0x0'));var util=require(_0x495f('0x1'));var moment=require(_0x495f('0x2'));var BPromise=require('bluebird');var rs=require('randomstring');var fs=require('fs');var Redis=require(_0x495f('0x3'));var db=require(_0x495f('0x4'))['db'];var utils=require('../../config/utils');var logger=require('../../config/logger')(_0x495f('0x5'));var config=require(_0x495f('0x6'));var jayson=require(_0x495f('0x7'));var client=jayson['client'][_0x495f('0x8')]({'port':0x232a});function respondWithRpcPromise(_0x435e2a,_0x304274,_0x4c17af){return new BPromise(function(_0x2103a4,_0x4610a7){return client[_0x495f('0x9')](_0x435e2a,_0x4c17af)['then'](function(_0x55dc23){logger[_0x495f('0xa')]('SmsApplication,\x20%s,\x20%s',_0x304274,_0x495f('0xb'));logger['debug'](_0x495f('0xc'),_0x304274,_0x495f('0xb'),JSON[_0x495f('0xd')](_0x55dc23));if(_0x55dc23[_0x495f('0xe')]){if(_0x55dc23['error'][_0x495f('0xf')]===0x1f4){logger[_0x495f('0xe')](_0x495f('0x10'),_0x304274,_0x55dc23[_0x495f('0xe')][_0x495f('0x11')]);return _0x4610a7(_0x55dc23['error'][_0x495f('0x11')]);}logger[_0x495f('0xe')](_0x495f('0x10'),_0x304274,_0x55dc23[_0x495f('0xe')][_0x495f('0x11')]);return _0x2103a4(_0x55dc23[_0x495f('0xe')][_0x495f('0x11')]);}else{logger['info'](_0x495f('0x10'),_0x304274,_0x495f('0xb'));_0x2103a4(_0x55dc23[_0x495f('0x12')][_0x495f('0x11')]);}})['catch'](function(_0x20f97c){logger[_0x495f('0xe')]('SmsApplication,\x20%s,\x20%s',_0x304274,_0x20f97c);_0x4610a7(_0x20f97c);});});}
\ No newline at end of file
+var _0xa261=['error','code','message','result','catch','lodash','moment','bluebird','randomstring','ioredis','../../mysqldb','../../config/environment','jayson/promise','client','http','request','then','info','SmsApplication,\x20%s,\x20%s','request\x20sent','debug','SmsApplication,\x20%s,\x20%s,\x20%s','stringify'];(function(_0x1d246a,_0x49be62){var _0x4f233b=function(_0x43ca54){while(--_0x43ca54){_0x1d246a['push'](_0x1d246a['shift']());}};_0x4f233b(++_0x49be62);}(_0xa261,0x1a3));var _0x1a26=function(_0x3d8077,_0x413233){_0x3d8077=_0x3d8077-0x0;var _0x11b549=_0xa261[_0x3d8077];return _0x11b549;};'use strict';var _=require(_0x1a26('0x0'));var util=require('util');var moment=require(_0x1a26('0x1'));var BPromise=require(_0x1a26('0x2'));var rs=require(_0x1a26('0x3'));var fs=require('fs');var Redis=require(_0x1a26('0x4'));var db=require(_0x1a26('0x5'))['db'];var utils=require('../../config/utils');var logger=require('../../config/logger')('rpc');var config=require(_0x1a26('0x6'));var jayson=require(_0x1a26('0x7'));var client=jayson[_0x1a26('0x8')][_0x1a26('0x9')]({'port':0x232a});function respondWithRpcPromise(_0x120837,_0x480d59,_0x2dfa27){return new BPromise(function(_0x53064d,_0x197c24){return client[_0x1a26('0xa')](_0x120837,_0x2dfa27)[_0x1a26('0xb')](function(_0x48aee0){logger[_0x1a26('0xc')](_0x1a26('0xd'),_0x480d59,_0x1a26('0xe'));logger[_0x1a26('0xf')](_0x1a26('0x10'),_0x480d59,'request\x20sent',JSON[_0x1a26('0x11')](_0x48aee0));if(_0x48aee0[_0x1a26('0x12')]){if(_0x48aee0[_0x1a26('0x12')][_0x1a26('0x13')]===0x1f4){logger[_0x1a26('0x12')](_0x1a26('0xd'),_0x480d59,_0x48aee0['error'][_0x1a26('0x14')]);return _0x197c24(_0x48aee0['error'][_0x1a26('0x14')]);}logger[_0x1a26('0x12')](_0x1a26('0xd'),_0x480d59,_0x48aee0['error'][_0x1a26('0x14')]);return _0x53064d(_0x48aee0[_0x1a26('0x12')][_0x1a26('0x14')]);}else{logger[_0x1a26('0xc')](_0x1a26('0xd'),_0x480d59,'request\x20sent');_0x53064d(_0x48aee0[_0x1a26('0x15')][_0x1a26('0x14')]);}})[_0x1a26('0x16')](function(_0x43495c){logger[_0x1a26('0x12')](_0x1a26('0xd'),_0x480d59,_0x43495c);_0x197c24(_0x43495c);});});}
\ No newline at end of file