Built motion from commit 97153652.|2.6.26
[motion2.git] / server / api / intZendeskField / intZendeskField.rpc.js
index e9067ba..260b5fb 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xbb20=['ZendeskField,\x20%s,\x20%s,\x20%s','stringify','error','message','result','lodash','ioredis','../../mysqldb','../../config/utils','../../config/logger','jayson/promise','client','http','request','then','ZendeskField,\x20%s,\x20%s','request\x20sent'];(function(_0x3940f7,_0x5e5fef){var _0x572de1=function(_0x3a3848){while(--_0x3a3848){_0x3940f7['push'](_0x3940f7['shift']());}};_0x572de1(++_0x5e5fef);}(_0xbb20,0x8d));var _0x0bb2=function(_0xbf4237,_0x562717){_0xbf4237=_0xbf4237-0x0;var _0x24b797=_0xbb20[_0xbf4237];return _0x24b797;};'use strict';var _=require(_0x0bb2('0x0'));var util=require('util');var moment=require('moment');var BPromise=require('bluebird');var rs=require('randomstring');var fs=require('fs');var Redis=require(_0x0bb2('0x1'));var db=require(_0x0bb2('0x2'))['db'];var utils=require(_0x0bb2('0x3'));var logger=require(_0x0bb2('0x4'))('rpc');var config=require('../../config/environment');var jayson=require(_0x0bb2('0x5'));var client=jayson[_0x0bb2('0x6')][_0x0bb2('0x7')]({'port':0x232a});function respondWithRpcPromise(_0x539cac,_0x3004a4,_0x1465cb){return new BPromise(function(_0x408155,_0x150016){return client[_0x0bb2('0x8')](_0x539cac,_0x1465cb)[_0x0bb2('0x9')](function(_0x3c6250){logger['info'](_0x0bb2('0xa'),_0x3004a4,_0x0bb2('0xb'));logger['debug'](_0x0bb2('0xc'),_0x3004a4,_0x0bb2('0xb'),JSON[_0x0bb2('0xd')](_0x3c6250));if(_0x3c6250[_0x0bb2('0xe')]){if(_0x3c6250['error']['code']===0x1f4){logger[_0x0bb2('0xe')](_0x0bb2('0xa'),_0x3004a4,_0x3c6250[_0x0bb2('0xe')][_0x0bb2('0xf')]);return _0x150016(_0x3c6250[_0x0bb2('0xe')][_0x0bb2('0xf')]);}logger[_0x0bb2('0xe')](_0x0bb2('0xa'),_0x3004a4,_0x3c6250[_0x0bb2('0xe')][_0x0bb2('0xf')]);return _0x408155(_0x3c6250[_0x0bb2('0xe')][_0x0bb2('0xf')]);}else{logger['info'](_0x0bb2('0xa'),_0x3004a4,'request\x20sent');_0x408155(_0x3c6250[_0x0bb2('0x10')][_0x0bb2('0xf')]);}})['catch'](function(_0x5baace){logger[_0x0bb2('0xe')](_0x0bb2('0xa'),_0x3004a4,_0x5baace);_0x150016(_0x5baace);});});}
\ No newline at end of file
+var _0xa7b3=['../../mysqldb','../../config/utils','../../config/logger','../../config/environment','jayson/promise','http','request','then','info','ZendeskField,\x20%s,\x20%s','request\x20sent','debug','ZendeskField,\x20%s,\x20%s,\x20%s','error','code','message','catch','util','moment','bluebird','randomstring','ioredis'];(function(_0x5be253,_0x470b74){var _0x3fee0e=function(_0x12e485){while(--_0x12e485){_0x5be253['push'](_0x5be253['shift']());}};_0x3fee0e(++_0x470b74);}(_0xa7b3,0x7f));var _0x3a7b=function(_0x3b2bb4,_0x1c48c8){_0x3b2bb4=_0x3b2bb4-0x0;var _0x497e44=_0xa7b3[_0x3b2bb4];return _0x497e44;};'use strict';var _=require('lodash');var util=require(_0x3a7b('0x0'));var moment=require(_0x3a7b('0x1'));var BPromise=require(_0x3a7b('0x2'));var rs=require(_0x3a7b('0x3'));var fs=require('fs');var Redis=require(_0x3a7b('0x4'));var db=require(_0x3a7b('0x5'))['db'];var utils=require(_0x3a7b('0x6'));var logger=require(_0x3a7b('0x7'))('rpc');var config=require(_0x3a7b('0x8'));var jayson=require(_0x3a7b('0x9'));var client=jayson['client'][_0x3a7b('0xa')]({'port':0x232a});function respondWithRpcPromise(_0x30e06f,_0x382585,_0x5a5548){return new BPromise(function(_0x37c659,_0x2c5027){return client[_0x3a7b('0xb')](_0x30e06f,_0x5a5548)[_0x3a7b('0xc')](function(_0x23152b){logger[_0x3a7b('0xd')](_0x3a7b('0xe'),_0x382585,_0x3a7b('0xf'));logger[_0x3a7b('0x10')](_0x3a7b('0x11'),_0x382585,'request\x20sent',JSON['stringify'](_0x23152b));if(_0x23152b[_0x3a7b('0x12')]){if(_0x23152b[_0x3a7b('0x12')][_0x3a7b('0x13')]===0x1f4){logger['error'](_0x3a7b('0xe'),_0x382585,_0x23152b[_0x3a7b('0x12')]['message']);return _0x2c5027(_0x23152b[_0x3a7b('0x12')][_0x3a7b('0x14')]);}logger['error'](_0x3a7b('0xe'),_0x382585,_0x23152b[_0x3a7b('0x12')][_0x3a7b('0x14')]);return _0x37c659(_0x23152b[_0x3a7b('0x12')][_0x3a7b('0x14')]);}else{logger[_0x3a7b('0xd')](_0x3a7b('0xe'),_0x382585,_0x3a7b('0xf'));_0x37c659(_0x23152b['result'][_0x3a7b('0x14')]);}})[_0x3a7b('0x15')](function(_0x4ef295){logger[_0x3a7b('0x12')](_0x3a7b('0xe'),_0x382585,_0x4ef295);_0x2c5027(_0x4ef295);});});}
\ No newline at end of file