Built motion from commit 42801a18.|2.6.28
[motion2.git] / server / api / openchannelApplication / openchannelApplication.rpc.js
index e12ecaf..eac8e42 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x0341=['limit','lodash','util','moment','bluebird','randomstring','ioredis','../../mysqldb','../../config/utils','rpc','../../config/environment','client','http','request','then','info','OpenchannelApplication,\x20%s,\x20%s','request\x20sent','debug','OpenchannelApplication,\x20%s,\x20%s,\x20%s','stringify','error','message','result','UpdateOpenchannelApplication','OpenchannelApplication','update','body','options','where','attributes'];(function(_0x73a665,_0x6ed407){var _0x2fa8d8=function(_0x24916d){while(--_0x24916d){_0x73a665['push'](_0x73a665['shift']());}};_0x2fa8d8(++_0x6ed407);}(_0x0341,0x175));var _0x1034=function(_0x36e5ba,_0x13fbf6){_0x36e5ba=_0x36e5ba-0x0;var _0x4e5ce5=_0x0341[_0x36e5ba];return _0x4e5ce5;};'use strict';var _=require(_0x1034('0x0'));var util=require(_0x1034('0x1'));var moment=require(_0x1034('0x2'));var BPromise=require(_0x1034('0x3'));var rs=require(_0x1034('0x4'));var fs=require('fs');var Redis=require(_0x1034('0x5'));var db=require(_0x1034('0x6'))['db'];var utils=require(_0x1034('0x7'));var logger=require('../../config/logger')(_0x1034('0x8'));var config=require(_0x1034('0x9'));var jayson=require('jayson/promise');var client=jayson[_0x1034('0xa')][_0x1034('0xb')]({'port':0x232a});function respondWithRpcPromise(_0x4c6a0f,_0x543d86,_0x8fe533){return new BPromise(function(_0x1a54fd,_0x5181cf){return client[_0x1034('0xc')](_0x4c6a0f,_0x8fe533)[_0x1034('0xd')](function(_0x4a8e40){logger[_0x1034('0xe')](_0x1034('0xf'),_0x543d86,_0x1034('0x10'));logger[_0x1034('0x11')](_0x1034('0x12'),_0x543d86,_0x1034('0x10'),JSON[_0x1034('0x13')](_0x4a8e40));if(_0x4a8e40[_0x1034('0x14')]){if(_0x4a8e40[_0x1034('0x14')]['code']===0x1f4){logger['error']('OpenchannelApplication,\x20%s,\x20%s',_0x543d86,_0x4a8e40[_0x1034('0x14')][_0x1034('0x15')]);return _0x5181cf(_0x4a8e40['error']['message']);}logger[_0x1034('0x14')]('OpenchannelApplication,\x20%s,\x20%s',_0x543d86,_0x4a8e40['error'][_0x1034('0x15')]);return _0x1a54fd(_0x4a8e40[_0x1034('0x14')]['message']);}else{logger[_0x1034('0xe')](_0x1034('0xf'),_0x543d86,_0x1034('0x10'));_0x1a54fd(_0x4a8e40[_0x1034('0x16')][_0x1034('0x15')]);}})['catch'](function(_0x2c983f){logger[_0x1034('0x14')](_0x1034('0xf'),_0x543d86,_0x2c983f);_0x5181cf(_0x2c983f);});});}exports[_0x1034('0x17')]=function(_0x2a7396){var _0x201fc8=this;return new Promise(function(_0x51413c,_0x26ea34){return db[_0x1034('0x18')][_0x1034('0x19')](_0x2a7396[_0x1034('0x1a')],{'raw':_0x2a7396[_0x1034('0x1b')]?_0x2a7396[_0x1034('0x1b')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x2a7396[_0x1034('0x1b')]?_0x2a7396[_0x1034('0x1b')][_0x1034('0x1c')]||null:null,'attributes':_0x2a7396[_0x1034('0x1b')]?_0x2a7396[_0x1034('0x1b')][_0x1034('0x1d')]||null:null,'limit':_0x2a7396['options']?_0x2a7396[_0x1034('0x1b')][_0x1034('0x1e')]||null:null})[_0x1034('0xd')](function(_0x4120e3){logger[_0x1034('0xe')](_0x1034('0x17'),_0x2a7396);logger[_0x1034('0x11')](_0x1034('0x17'),_0x2a7396,JSON[_0x1034('0x13')](_0x4120e3));_0x51413c(_0x4120e3);})['catch'](function(_0x22f707){logger[_0x1034('0x14')](_0x1034('0x17'),_0x22f707[_0x1034('0x15')],_0x2a7396);_0x26ea34(_0x201fc8['error'](0x1f4,_0x22f707[_0x1034('0x15')]));});});};
\ No newline at end of file
+var _0x2821=['http','request','then','info','OpenchannelApplication,\x20%s,\x20%s','request\x20sent','OpenchannelApplication,\x20%s,\x20%s,\x20%s','stringify','error','code','message','catch','UpdateOpenchannelApplication','OpenchannelApplication','body','options','where','attributes','limit','debug','util','moment','bluebird','ioredis','../../mysqldb','../../config/utils','../../config/logger','rpc','../../config/environment','client'];(function(_0x3dd15e,_0x1f0015){var _0x231fd0=function(_0x4f680a){while(--_0x4f680a){_0x3dd15e['push'](_0x3dd15e['shift']());}};_0x231fd0(++_0x1f0015);}(_0x2821,0x1f4));var _0x1282=function(_0x116de3,_0x476ef8){_0x116de3=_0x116de3-0x0;var _0xbe4997=_0x2821[_0x116de3];return _0xbe4997;};'use strict';var _=require('lodash');var util=require(_0x1282('0x0'));var moment=require(_0x1282('0x1'));var BPromise=require(_0x1282('0x2'));var rs=require('randomstring');var fs=require('fs');var Redis=require(_0x1282('0x3'));var db=require(_0x1282('0x4'))['db'];var utils=require(_0x1282('0x5'));var logger=require(_0x1282('0x6'))(_0x1282('0x7'));var config=require(_0x1282('0x8'));var jayson=require('jayson/promise');var client=jayson[_0x1282('0x9')][_0x1282('0xa')]({'port':0x232a});function respondWithRpcPromise(_0x10ca2c,_0x349d6d,_0x1e484b){return new BPromise(function(_0x5ab6ed,_0x102022){return client[_0x1282('0xb')](_0x10ca2c,_0x1e484b)[_0x1282('0xc')](function(_0x581191){logger[_0x1282('0xd')](_0x1282('0xe'),_0x349d6d,_0x1282('0xf'));logger['debug'](_0x1282('0x10'),_0x349d6d,'request\x20sent',JSON[_0x1282('0x11')](_0x581191));if(_0x581191['error']){if(_0x581191[_0x1282('0x12')][_0x1282('0x13')]===0x1f4){logger[_0x1282('0x12')](_0x1282('0xe'),_0x349d6d,_0x581191[_0x1282('0x12')]['message']);return _0x102022(_0x581191[_0x1282('0x12')][_0x1282('0x14')]);}logger[_0x1282('0x12')](_0x1282('0xe'),_0x349d6d,_0x581191[_0x1282('0x12')][_0x1282('0x14')]);return _0x5ab6ed(_0x581191[_0x1282('0x12')][_0x1282('0x14')]);}else{logger[_0x1282('0xd')](_0x1282('0xe'),_0x349d6d,_0x1282('0xf'));_0x5ab6ed(_0x581191['result'][_0x1282('0x14')]);}})[_0x1282('0x15')](function(_0x1f90a6){logger['error'](_0x1282('0xe'),_0x349d6d,_0x1f90a6);_0x102022(_0x1f90a6);});});}exports[_0x1282('0x16')]=function(_0x2edc6e){var _0x3f480a=this;return new Promise(function(_0x3f3a3c,_0x127037){return db[_0x1282('0x17')]['update'](_0x2edc6e[_0x1282('0x18')],{'raw':_0x2edc6e[_0x1282('0x19')]?_0x2edc6e[_0x1282('0x19')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x2edc6e[_0x1282('0x19')]?_0x2edc6e['options'][_0x1282('0x1a')]||null:null,'attributes':_0x2edc6e[_0x1282('0x19')]?_0x2edc6e[_0x1282('0x19')][_0x1282('0x1b')]||null:null,'limit':_0x2edc6e[_0x1282('0x19')]?_0x2edc6e[_0x1282('0x19')][_0x1282('0x1c')]||null:null})[_0x1282('0xc')](function(_0xcd537a){logger['info'](_0x1282('0x16'),_0x2edc6e);logger[_0x1282('0x1d')](_0x1282('0x16'),_0x2edc6e,JSON['stringify'](_0xcd537a));_0x3f3a3c(_0xcd537a);})[_0x1282('0x15')](function(_0xece630){logger[_0x1282('0x12')](_0x1282('0x16'),_0xece630[_0x1282('0x14')],_0x2edc6e);_0x127037(_0x3f480a[_0x1282('0x12')](0x1f4,_0xece630[_0x1282('0x14')]));});});};
\ No newline at end of file