Built motion from commit 14588770.|2.5.38
[motion2.git] / server / api / intFreshsalesConfiguration / intFreshsalesConfiguration.rpc.js
index 7961602..a0826fb 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xf323=['client','http','request','then','info','FreshsalesConfiguration,\x20%s,\x20%s','request\x20sent','FreshsalesConfiguration,\x20%s,\x20%s,\x20%s','stringify','error','code','message','result','moment','bluebird','ioredis','../../mysqldb','../../config/utils','../../config/logger','rpc','jayson/promise'];(function(_0x40dd8b,_0x5663aa){var _0x13ac0b=function(_0x59c65c){while(--_0x59c65c){_0x40dd8b['push'](_0x40dd8b['shift']());}};_0x13ac0b(++_0x5663aa);}(_0xf323,0x1c6));var _0x3f32=function(_0x46f465,_0x41516b){_0x46f465=_0x46f465-0x0;var _0x2a7538=_0xf323[_0x46f465];return _0x2a7538;};'use strict';var _=require('lodash');var util=require('util');var moment=require(_0x3f32('0x0'));var BPromise=require(_0x3f32('0x1'));var rs=require('randomstring');var fs=require('fs');var Redis=require(_0x3f32('0x2'));var db=require(_0x3f32('0x3'))['db'];var utils=require(_0x3f32('0x4'));var logger=require(_0x3f32('0x5'))(_0x3f32('0x6'));var config=require('../../config/environment');var jayson=require(_0x3f32('0x7'));var client=jayson[_0x3f32('0x8')][_0x3f32('0x9')]({'port':0x232a});function respondWithRpcPromise(_0x1134e9,_0x5c9dc2,_0x567ab1){return new BPromise(function(_0x34b93e,_0x109af2){return client[_0x3f32('0xa')](_0x1134e9,_0x567ab1)[_0x3f32('0xb')](function(_0x22a9d3){logger[_0x3f32('0xc')](_0x3f32('0xd'),_0x5c9dc2,_0x3f32('0xe'));logger['debug'](_0x3f32('0xf'),_0x5c9dc2,_0x3f32('0xe'),JSON[_0x3f32('0x10')](_0x22a9d3));if(_0x22a9d3['error']){if(_0x22a9d3[_0x3f32('0x11')][_0x3f32('0x12')]===0x1f4){logger[_0x3f32('0x11')](_0x3f32('0xd'),_0x5c9dc2,_0x22a9d3['error']['message']);return _0x109af2(_0x22a9d3[_0x3f32('0x11')][_0x3f32('0x13')]);}logger['error'](_0x3f32('0xd'),_0x5c9dc2,_0x22a9d3[_0x3f32('0x11')][_0x3f32('0x13')]);return _0x34b93e(_0x22a9d3['error']['message']);}else{logger[_0x3f32('0xc')](_0x3f32('0xd'),_0x5c9dc2,_0x3f32('0xe'));_0x34b93e(_0x22a9d3[_0x3f32('0x14')]['message']);}})['catch'](function(_0x352010){logger[_0x3f32('0x11')](_0x3f32('0xd'),_0x5c9dc2,_0x352010);_0x109af2(_0x352010);});});}
\ No newline at end of file
+var _0x96f7=['result','lodash','util','moment','bluebird','randomstring','ioredis','../../mysqldb','../../config/utils','rpc','../../config/environment','jayson/promise','client','http','then','FreshsalesConfiguration,\x20%s,\x20%s','request\x20sent','FreshsalesConfiguration,\x20%s,\x20%s,\x20%s','stringify','error','code','message'];(function(_0x45357a,_0x4097c5){var _0x566c41=function(_0x6d79b9){while(--_0x6d79b9){_0x45357a['push'](_0x45357a['shift']());}};_0x566c41(++_0x4097c5);}(_0x96f7,0x1cf));var _0x796f=function(_0x150a49,_0x47b070){_0x150a49=_0x150a49-0x0;var _0xe8c345=_0x96f7[_0x150a49];return _0xe8c345;};'use strict';var _=require(_0x796f('0x0'));var util=require(_0x796f('0x1'));var moment=require(_0x796f('0x2'));var BPromise=require(_0x796f('0x3'));var rs=require(_0x796f('0x4'));var fs=require('fs');var Redis=require(_0x796f('0x5'));var db=require(_0x796f('0x6'))['db'];var utils=require(_0x796f('0x7'));var logger=require('../../config/logger')(_0x796f('0x8'));var config=require(_0x796f('0x9'));var jayson=require(_0x796f('0xa'));var client=jayson[_0x796f('0xb')][_0x796f('0xc')]({'port':0x232a});function respondWithRpcPromise(_0xc9710f,_0x480ac9,_0x335767){return new BPromise(function(_0x34b4b7,_0x2948f4){return client['request'](_0xc9710f,_0x335767)[_0x796f('0xd')](function(_0x37e834){logger['info'](_0x796f('0xe'),_0x480ac9,_0x796f('0xf'));logger['debug'](_0x796f('0x10'),_0x480ac9,_0x796f('0xf'),JSON[_0x796f('0x11')](_0x37e834));if(_0x37e834[_0x796f('0x12')]){if(_0x37e834['error'][_0x796f('0x13')]===0x1f4){logger[_0x796f('0x12')]('FreshsalesConfiguration,\x20%s,\x20%s',_0x480ac9,_0x37e834[_0x796f('0x12')][_0x796f('0x14')]);return _0x2948f4(_0x37e834[_0x796f('0x12')][_0x796f('0x14')]);}logger[_0x796f('0x12')](_0x796f('0xe'),_0x480ac9,_0x37e834[_0x796f('0x12')][_0x796f('0x14')]);return _0x34b4b7(_0x37e834[_0x796f('0x12')][_0x796f('0x14')]);}else{logger['info']('FreshsalesConfiguration,\x20%s,\x20%s',_0x480ac9,'request\x20sent');_0x34b4b7(_0x37e834[_0x796f('0x15')][_0x796f('0x14')]);}})['catch'](function(_0x4adf63){logger[_0x796f('0x12')](_0x796f('0xe'),_0x480ac9,_0x4adf63);_0x2948f4(_0x4adf63);});});}
\ No newline at end of file