Built motion from commit fade34fd.|2.5.41
[motion2.git] / server / api / intSugarcrmField / intSugarcrmField.rpc.js
index 7884c74..fe3d675 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xfc7b=['request\x20sent','catch','lodash','util','moment','bluebird','randomstring','ioredis','rpc','../../config/environment','jayson/promise','client','http','then','info','SugarcrmField,\x20%s,\x20%s','SugarcrmField,\x20%s,\x20%s,\x20%s','stringify','error','code','message'];(function(_0x5b93e5,_0x4102bf){var _0x204cae=function(_0x594cbc){while(--_0x594cbc){_0x5b93e5['push'](_0x5b93e5['shift']());}};_0x204cae(++_0x4102bf);}(_0xfc7b,0xd4));var _0xbfc7=function(_0x541ef4,_0x3c5081){_0x541ef4=_0x541ef4-0x0;var _0x35f405=_0xfc7b[_0x541ef4];return _0x35f405;};'use strict';var _=require(_0xbfc7('0x0'));var util=require(_0xbfc7('0x1'));var moment=require(_0xbfc7('0x2'));var BPromise=require(_0xbfc7('0x3'));var rs=require(_0xbfc7('0x4'));var fs=require('fs');var Redis=require(_0xbfc7('0x5'));var db=require('../../mysqldb')['db'];var utils=require('../../config/utils');var logger=require('../../config/logger')(_0xbfc7('0x6'));var config=require(_0xbfc7('0x7'));var jayson=require(_0xbfc7('0x8'));var client=jayson[_0xbfc7('0x9')][_0xbfc7('0xa')]({'port':0x232a});function respondWithRpcPromise(_0x36b17c,_0x360a16,_0x324e85){return new BPromise(function(_0x279f55,_0x10e912){return client['request'](_0x36b17c,_0x324e85)[_0xbfc7('0xb')](function(_0x5e83e1){logger[_0xbfc7('0xc')](_0xbfc7('0xd'),_0x360a16,'request\x20sent');logger['debug'](_0xbfc7('0xe'),_0x360a16,'request\x20sent',JSON[_0xbfc7('0xf')](_0x5e83e1));if(_0x5e83e1['error']){if(_0x5e83e1[_0xbfc7('0x10')][_0xbfc7('0x11')]===0x1f4){logger['error']('SugarcrmField,\x20%s,\x20%s',_0x360a16,_0x5e83e1[_0xbfc7('0x10')][_0xbfc7('0x12')]);return _0x10e912(_0x5e83e1[_0xbfc7('0x10')][_0xbfc7('0x12')]);}logger[_0xbfc7('0x10')](_0xbfc7('0xd'),_0x360a16,_0x5e83e1[_0xbfc7('0x10')][_0xbfc7('0x12')]);return _0x279f55(_0x5e83e1[_0xbfc7('0x10')]['message']);}else{logger[_0xbfc7('0xc')]('SugarcrmField,\x20%s,\x20%s',_0x360a16,_0xbfc7('0x13'));_0x279f55(_0x5e83e1['result'][_0xbfc7('0x12')]);}})[_0xbfc7('0x14')](function(_0x14922c){logger[_0xbfc7('0x10')](_0xbfc7('0xd'),_0x360a16,_0x14922c);_0x10e912(_0x14922c);});});}
\ No newline at end of file
+var _0xd48e=['message','result','catch','lodash','moment','bluebird','randomstring','../../mysqldb','../../config/logger','rpc','../../config/environment','jayson/promise','client','http','request','then','info','request\x20sent','SugarcrmField,\x20%s,\x20%s,\x20%s','error','code','SugarcrmField,\x20%s,\x20%s'];(function(_0x2bf141,_0x31eac7){var _0x48277b=function(_0x9fe560){while(--_0x9fe560){_0x2bf141['push'](_0x2bf141['shift']());}};_0x48277b(++_0x31eac7);}(_0xd48e,0x1a5));var _0xed48=function(_0x39e283,_0x247e6b){_0x39e283=_0x39e283-0x0;var _0x7de89f=_0xd48e[_0x39e283];return _0x7de89f;};'use strict';var _=require(_0xed48('0x0'));var util=require('util');var moment=require(_0xed48('0x1'));var BPromise=require(_0xed48('0x2'));var rs=require(_0xed48('0x3'));var fs=require('fs');var Redis=require('ioredis');var db=require(_0xed48('0x4'))['db'];var utils=require('../../config/utils');var logger=require(_0xed48('0x5'))(_0xed48('0x6'));var config=require(_0xed48('0x7'));var jayson=require(_0xed48('0x8'));var client=jayson[_0xed48('0x9')][_0xed48('0xa')]({'port':0x232a});function respondWithRpcPromise(_0x425d63,_0x18a1ec,_0x1151b2){return new BPromise(function(_0x1d49db,_0x5c809c){return client[_0xed48('0xb')](_0x425d63,_0x1151b2)[_0xed48('0xc')](function(_0x3913f6){logger[_0xed48('0xd')]('SugarcrmField,\x20%s,\x20%s',_0x18a1ec,_0xed48('0xe'));logger['debug'](_0xed48('0xf'),_0x18a1ec,_0xed48('0xe'),JSON['stringify'](_0x3913f6));if(_0x3913f6[_0xed48('0x10')]){if(_0x3913f6[_0xed48('0x10')][_0xed48('0x11')]===0x1f4){logger['error'](_0xed48('0x12'),_0x18a1ec,_0x3913f6[_0xed48('0x10')][_0xed48('0x13')]);return _0x5c809c(_0x3913f6[_0xed48('0x10')]['message']);}logger[_0xed48('0x10')]('SugarcrmField,\x20%s,\x20%s',_0x18a1ec,_0x3913f6[_0xed48('0x10')][_0xed48('0x13')]);return _0x1d49db(_0x3913f6[_0xed48('0x10')][_0xed48('0x13')]);}else{logger[_0xed48('0xd')](_0xed48('0x12'),_0x18a1ec,_0xed48('0xe'));_0x1d49db(_0x3913f6[_0xed48('0x14')][_0xed48('0x13')]);}})[_0xed48('0x15')](function(_0x3da2fa){logger[_0xed48('0x10')](_0xed48('0x12'),_0x18a1ec,_0x3da2fa);_0x5c809c(_0x3da2fa);});});}
\ No newline at end of file