Built motion from commit da24aabd.|2.6.20
[motion2.git] / server / api / intFreshsalesConfiguration / intFreshsalesConfiguration.rpc.js
index 049eb7d..b4d65cc 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xe3d4=['util','moment','bluebird','ioredis','../../mysqldb','../../config/logger','../../config/environment','jayson/promise','http','request','then','request\x20sent','debug','FreshsalesConfiguration,\x20%s,\x20%s,\x20%s','stringify','error','code','FreshsalesConfiguration,\x20%s,\x20%s','message','info','result','catch'];(function(_0x1577f0,_0x578858){var _0x2dcc90=function(_0xebdaad){while(--_0xebdaad){_0x1577f0['push'](_0x1577f0['shift']());}};_0x2dcc90(++_0x578858);}(_0xe3d4,0xc6));var _0x4e3d=function(_0x336e7a,_0x211e1a){_0x336e7a=_0x336e7a-0x0;var _0x3764db=_0xe3d4[_0x336e7a];return _0x3764db;};'use strict';var _=require('lodash');var util=require(_0x4e3d('0x0'));var moment=require(_0x4e3d('0x1'));var BPromise=require(_0x4e3d('0x2'));var rs=require('randomstring');var fs=require('fs');var Redis=require(_0x4e3d('0x3'));var db=require(_0x4e3d('0x4'))['db'];var utils=require('../../config/utils');var logger=require(_0x4e3d('0x5'))('rpc');var config=require(_0x4e3d('0x6'));var jayson=require(_0x4e3d('0x7'));var client=jayson['client'][_0x4e3d('0x8')]({'port':0x232a});function respondWithRpcPromise(_0x1d5c04,_0x5b544d,_0x40b814){return new BPromise(function(_0x4275b0,_0x436075){return client[_0x4e3d('0x9')](_0x1d5c04,_0x40b814)[_0x4e3d('0xa')](function(_0x2968cd){logger['info']('FreshsalesConfiguration,\x20%s,\x20%s',_0x5b544d,_0x4e3d('0xb'));logger[_0x4e3d('0xc')](_0x4e3d('0xd'),_0x5b544d,_0x4e3d('0xb'),JSON[_0x4e3d('0xe')](_0x2968cd));if(_0x2968cd[_0x4e3d('0xf')]){if(_0x2968cd['error'][_0x4e3d('0x10')]===0x1f4){logger[_0x4e3d('0xf')](_0x4e3d('0x11'),_0x5b544d,_0x2968cd[_0x4e3d('0xf')][_0x4e3d('0x12')]);return _0x436075(_0x2968cd[_0x4e3d('0xf')][_0x4e3d('0x12')]);}logger[_0x4e3d('0xf')]('FreshsalesConfiguration,\x20%s,\x20%s',_0x5b544d,_0x2968cd[_0x4e3d('0xf')][_0x4e3d('0x12')]);return _0x4275b0(_0x2968cd[_0x4e3d('0xf')]['message']);}else{logger[_0x4e3d('0x13')](_0x4e3d('0x11'),_0x5b544d,_0x4e3d('0xb'));_0x4275b0(_0x2968cd[_0x4e3d('0x14')][_0x4e3d('0x12')]);}})[_0x4e3d('0x15')](function(_0x28979d){logger[_0x4e3d('0xf')]('FreshsalesConfiguration,\x20%s,\x20%s',_0x5b544d,_0x28979d);_0x436075(_0x28979d);});});}
\ No newline at end of file
+var _0x36b4=['result','catch','lodash','util','ioredis','../../config/utils','rpc','../../config/environment','jayson/promise','client','http','request','then','info','FreshsalesConfiguration,\x20%s,\x20%s','debug','FreshsalesConfiguration,\x20%s,\x20%s,\x20%s','request\x20sent','stringify','error','code','message'];(function(_0x23394e,_0x30e9d2){var _0x2ba163=function(_0x2dc955){while(--_0x2dc955){_0x23394e['push'](_0x23394e['shift']());}};_0x2ba163(++_0x30e9d2);}(_0x36b4,0x18e));var _0x436b=function(_0x1f7191,_0x37bc37){_0x1f7191=_0x1f7191-0x0;var _0x29fd0d=_0x36b4[_0x1f7191];return _0x29fd0d;};'use strict';var _=require(_0x436b('0x0'));var util=require(_0x436b('0x1'));var moment=require('moment');var BPromise=require('bluebird');var rs=require('randomstring');var fs=require('fs');var Redis=require(_0x436b('0x2'));var db=require('../../mysqldb')['db'];var utils=require(_0x436b('0x3'));var logger=require('../../config/logger')(_0x436b('0x4'));var config=require(_0x436b('0x5'));var jayson=require(_0x436b('0x6'));var client=jayson[_0x436b('0x7')][_0x436b('0x8')]({'port':0x232a});function respondWithRpcPromise(_0x1769c4,_0x521781,_0x79482e){return new BPromise(function(_0xa31529,_0x59ff3c){return client[_0x436b('0x9')](_0x1769c4,_0x79482e)[_0x436b('0xa')](function(_0x328d26){logger[_0x436b('0xb')](_0x436b('0xc'),_0x521781,'request\x20sent');logger[_0x436b('0xd')](_0x436b('0xe'),_0x521781,_0x436b('0xf'),JSON[_0x436b('0x10')](_0x328d26));if(_0x328d26[_0x436b('0x11')]){if(_0x328d26[_0x436b('0x11')][_0x436b('0x12')]===0x1f4){logger[_0x436b('0x11')](_0x436b('0xc'),_0x521781,_0x328d26['error'][_0x436b('0x13')]);return _0x59ff3c(_0x328d26['error']['message']);}logger['error'](_0x436b('0xc'),_0x521781,_0x328d26[_0x436b('0x11')][_0x436b('0x13')]);return _0xa31529(_0x328d26[_0x436b('0x11')][_0x436b('0x13')]);}else{logger[_0x436b('0xb')](_0x436b('0xc'),_0x521781,'request\x20sent');_0xa31529(_0x328d26[_0x436b('0x14')][_0x436b('0x13')]);}})[_0x436b('0x15')](function(_0x44ba2c){logger[_0x436b('0x11')](_0x436b('0xc'),_0x521781,_0x44ba2c);_0x59ff3c(_0x44ba2c);});});}
\ No newline at end of file