Built motion from commit 85328c08.|2.5.50
[motion2.git] / server / api / userFaxQueue / userFaxQueue.rpc.js
index 69ed137..8685396 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x441b=['info','UserFaxQueue,\x20%s,\x20%s','request\x20sent','stringify','error','code','message','catch','util','moment','bluebird','randomstring','../../config/utils','../../config/logger','rpc','../../config/environment','http','request','then'];(function(_0x335a68,_0x536293){var _0x5d26d8=function(_0x1533e3){while(--_0x1533e3){_0x335a68['push'](_0x335a68['shift']());}};_0x5d26d8(++_0x536293);}(_0x441b,0x197));var _0xb441=function(_0x3cb8e3,_0x58376d){_0x3cb8e3=_0x3cb8e3-0x0;var _0x1cb9d2=_0x441b[_0x3cb8e3];return _0x1cb9d2;};'use strict';var _=require('lodash');var util=require(_0xb441('0x0'));var moment=require(_0xb441('0x1'));var BPromise=require(_0xb441('0x2'));var rs=require(_0xb441('0x3'));var fs=require('fs');var Redis=require('ioredis');var db=require('../../mysqldb')['db'];var utils=require(_0xb441('0x4'));var logger=require(_0xb441('0x5'))(_0xb441('0x6'));var config=require(_0xb441('0x7'));var jayson=require('jayson/promise');var client=jayson['client'][_0xb441('0x8')]({'port':0x232a});function respondWithRpcPromise(_0x5eb572,_0x3fbafe,_0x47ca98){return new BPromise(function(_0x1f8f9d,_0x18b49c){return client[_0xb441('0x9')](_0x5eb572,_0x47ca98)[_0xb441('0xa')](function(_0x162265){logger[_0xb441('0xb')](_0xb441('0xc'),_0x3fbafe,_0xb441('0xd'));logger['debug']('UserFaxQueue,\x20%s,\x20%s,\x20%s',_0x3fbafe,_0xb441('0xd'),JSON[_0xb441('0xe')](_0x162265));if(_0x162265['error']){if(_0x162265[_0xb441('0xf')][_0xb441('0x10')]===0x1f4){logger[_0xb441('0xf')](_0xb441('0xc'),_0x3fbafe,_0x162265[_0xb441('0xf')][_0xb441('0x11')]);return _0x18b49c(_0x162265[_0xb441('0xf')]['message']);}logger[_0xb441('0xf')](_0xb441('0xc'),_0x3fbafe,_0x162265[_0xb441('0xf')][_0xb441('0x11')]);return _0x1f8f9d(_0x162265['error']['message']);}else{logger[_0xb441('0xb')](_0xb441('0xc'),_0x3fbafe,_0xb441('0xd'));_0x1f8f9d(_0x162265['result'][_0xb441('0x11')]);}})[_0xb441('0x12')](function(_0x41873e){logger[_0xb441('0xf')](_0xb441('0xc'),_0x3fbafe,_0x41873e);_0x18b49c(_0x41873e);});});}
\ No newline at end of file
+var _0xdaf7=['message','lodash','util','moment','bluebird','randomstring','ioredis','../../config/utils','../../config/logger','rpc','../../config/environment','jayson/promise','client','http','request','then','UserFaxQueue,\x20%s,\x20%s','request\x20sent','debug','UserFaxQueue,\x20%s,\x20%s,\x20%s','stringify','error','code'];(function(_0x3e85a4,_0x18c3a9){var _0x21e7d1=function(_0x48457d){while(--_0x48457d){_0x3e85a4['push'](_0x3e85a4['shift']());}};_0x21e7d1(++_0x18c3a9);}(_0xdaf7,0xe7));var _0x7daf=function(_0x5adef4,_0x1a67cf){_0x5adef4=_0x5adef4-0x0;var _0x2be5bc=_0xdaf7[_0x5adef4];return _0x2be5bc;};'use strict';var _=require(_0x7daf('0x0'));var util=require(_0x7daf('0x1'));var moment=require(_0x7daf('0x2'));var BPromise=require(_0x7daf('0x3'));var rs=require(_0x7daf('0x4'));var fs=require('fs');var Redis=require(_0x7daf('0x5'));var db=require('../../mysqldb')['db'];var utils=require(_0x7daf('0x6'));var logger=require(_0x7daf('0x7'))(_0x7daf('0x8'));var config=require(_0x7daf('0x9'));var jayson=require(_0x7daf('0xa'));var client=jayson[_0x7daf('0xb')][_0x7daf('0xc')]({'port':0x232a});function respondWithRpcPromise(_0x34986d,_0x2a729f,_0x72effd){return new BPromise(function(_0x453eca,_0x48eb2c){return client[_0x7daf('0xd')](_0x34986d,_0x72effd)[_0x7daf('0xe')](function(_0x832b3e){logger['info'](_0x7daf('0xf'),_0x2a729f,_0x7daf('0x10'));logger[_0x7daf('0x11')](_0x7daf('0x12'),_0x2a729f,_0x7daf('0x10'),JSON[_0x7daf('0x13')](_0x832b3e));if(_0x832b3e[_0x7daf('0x14')]){if(_0x832b3e['error'][_0x7daf('0x15')]===0x1f4){logger['error'](_0x7daf('0xf'),_0x2a729f,_0x832b3e[_0x7daf('0x14')][_0x7daf('0x16')]);return _0x48eb2c(_0x832b3e[_0x7daf('0x14')][_0x7daf('0x16')]);}logger[_0x7daf('0x14')](_0x7daf('0xf'),_0x2a729f,_0x832b3e[_0x7daf('0x14')][_0x7daf('0x16')]);return _0x453eca(_0x832b3e[_0x7daf('0x14')][_0x7daf('0x16')]);}else{logger['info'](_0x7daf('0xf'),_0x2a729f,_0x7daf('0x10'));_0x453eca(_0x832b3e['result'][_0x7daf('0x16')]);}})['catch'](function(_0x24de85){logger[_0x7daf('0x14')](_0x7daf('0xf'),_0x2a729f,_0x24de85);_0x48eb2c(_0x24de85);});});}
\ No newline at end of file