Built motion from commit dbf3a7e2.|2.6.30
[motion2.git] / server / api / intDynamics365Account / intDynamics365Account.rpc.js
index 216c3f8..0cf220f 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xd1fe=['jayson/promise','client','http','request','then','info','Dynamics365Account,\x20%s,\x20%s','debug','Dynamics365Account,\x20%s,\x20%s,\x20%s','request\x20sent','stringify','error','code','message','result','catch','GetDynamics365Account','Dynamics365Account','findAll','options','raw','where','limit','include','map','attributes','model','ShowDynamics365Account','find','lodash','util','moment','randomstring','../../config/utils','../../config/logger','rpc','../../config/environment'];(function(_0x2f4613,_0x234c4f){var _0x3bb842=function(_0x278897){while(--_0x278897){_0x2f4613['push'](_0x2f4613['shift']());}};_0x3bb842(++_0x234c4f);}(_0xd1fe,0x145));var _0xed1f=function(_0xbbee58,_0x239bfa){_0xbbee58=_0xbbee58-0x0;var _0x56d11b=_0xd1fe[_0xbbee58];return _0x56d11b;};'use strict';var _=require(_0xed1f('0x0'));var util=require(_0xed1f('0x1'));var moment=require(_0xed1f('0x2'));var BPromise=require('bluebird');var rs=require(_0xed1f('0x3'));var fs=require('fs');var Redis=require('ioredis');var db=require('../../mysqldb')['db'];var utils=require(_0xed1f('0x4'));var logger=require(_0xed1f('0x5'))(_0xed1f('0x6'));var config=require(_0xed1f('0x7'));var jayson=require(_0xed1f('0x8'));var client=jayson[_0xed1f('0x9')][_0xed1f('0xa')]({'port':0x232a});function respondWithRpcPromise(_0xda3607,_0x1143bd,_0xf5038d){return new BPromise(function(_0x2e4392,_0x3fe2c9){return client[_0xed1f('0xb')](_0xda3607,_0xf5038d)[_0xed1f('0xc')](function(_0x4bd78c){logger[_0xed1f('0xd')](_0xed1f('0xe'),_0x1143bd,'request\x20sent');logger[_0xed1f('0xf')](_0xed1f('0x10'),_0x1143bd,_0xed1f('0x11'),JSON[_0xed1f('0x12')](_0x4bd78c));if(_0x4bd78c[_0xed1f('0x13')]){if(_0x4bd78c[_0xed1f('0x13')][_0xed1f('0x14')]===0x1f4){logger[_0xed1f('0x13')](_0xed1f('0xe'),_0x1143bd,_0x4bd78c[_0xed1f('0x13')][_0xed1f('0x15')]);return _0x3fe2c9(_0x4bd78c[_0xed1f('0x13')][_0xed1f('0x15')]);}logger[_0xed1f('0x13')]('Dynamics365Account,\x20%s,\x20%s',_0x1143bd,_0x4bd78c['error']['message']);return _0x2e4392(_0x4bd78c[_0xed1f('0x13')]['message']);}else{logger[_0xed1f('0xd')](_0xed1f('0xe'),_0x1143bd,_0xed1f('0x11'));_0x2e4392(_0x4bd78c[_0xed1f('0x16')][_0xed1f('0x15')]);}})[_0xed1f('0x17')](function(_0x436b41){logger['error']('Dynamics365Account,\x20%s,\x20%s',_0x1143bd,_0x436b41);_0x3fe2c9(_0x436b41);});});}exports[_0xed1f('0x18')]=function(_0x581ea6){var _0x3c280c=this;return new Promise(function(_0x5f4c0d,_0x1e756d){return db[_0xed1f('0x19')][_0xed1f('0x1a')]({'raw':_0x581ea6['options']?_0x581ea6[_0xed1f('0x1b')][_0xed1f('0x1c')]===undefined?!![]:![]:!![],'where':_0x581ea6[_0xed1f('0x1b')]?_0x581ea6[_0xed1f('0x1b')][_0xed1f('0x1d')]||null:null,'attributes':_0x581ea6[_0xed1f('0x1b')]?_0x581ea6[_0xed1f('0x1b')]['attributes']||null:null,'limit':_0x581ea6['options']?_0x581ea6[_0xed1f('0x1b')][_0xed1f('0x1e')]||null:null,'include':_0x581ea6[_0xed1f('0x1b')]?_0x581ea6[_0xed1f('0x1b')][_0xed1f('0x1f')]?_[_0xed1f('0x20')](_0x581ea6[_0xed1f('0x1b')][_0xed1f('0x1f')],function(_0x6716e5){return{'model':db[_0x6716e5['model']],'as':_0x6716e5['as'],'attributes':_0x6716e5[_0xed1f('0x21')],'include':_0x6716e5[_0xed1f('0x1f')]?_[_0xed1f('0x20')](_0x6716e5[_0xed1f('0x1f')],function(_0x1ab460){return{'model':db[_0x1ab460[_0xed1f('0x22')]],'as':_0x1ab460['as'],'attributes':_0x1ab460[_0xed1f('0x21')],'include':_0x1ab460[_0xed1f('0x1f')]?_[_0xed1f('0x20')](_0x1ab460[_0xed1f('0x1f')],function(_0x6e7e2f){return{'model':db[_0x6e7e2f[_0xed1f('0x22')]],'as':_0x6e7e2f['as'],'attributes':_0x6e7e2f[_0xed1f('0x21')]};}):[]};}):[]};}):[]:[]})[_0xed1f('0xc')](function(_0x22eb49){logger[_0xed1f('0xd')](_0xed1f('0x18'),_0x581ea6);logger[_0xed1f('0xf')](_0xed1f('0x18'),_0x581ea6,JSON['stringify'](_0x22eb49));_0x5f4c0d(_0x22eb49);})[_0xed1f('0x17')](function(_0x11a7ca){logger['error'](_0xed1f('0x18'),_0x11a7ca[_0xed1f('0x15')],_0x581ea6);_0x1e756d(_0x3c280c[_0xed1f('0x13')](0x1f4,_0x11a7ca[_0xed1f('0x15')]));});});};exports[_0xed1f('0x23')]=function(_0x541e46){var _0xd3b497=this;return new Promise(function(_0x4420f3,_0x924921){return db[_0xed1f('0x19')][_0xed1f('0x24')]({'raw':_0x541e46['options']?_0x541e46[_0xed1f('0x1b')][_0xed1f('0x1c')]===undefined?!![]:![]:!![],'where':_0x541e46[_0xed1f('0x1b')]?_0x541e46['options'][_0xed1f('0x1d')]||null:null,'attributes':_0x541e46[_0xed1f('0x1b')]?_0x541e46['options'][_0xed1f('0x21')]||null:null,'include':_0x541e46[_0xed1f('0x1b')]?_0x541e46[_0xed1f('0x1b')][_0xed1f('0x1f')]?_[_0xed1f('0x20')](_0x541e46[_0xed1f('0x1b')]['include'],function(_0x4a771b){return{'model':db[_0x4a771b[_0xed1f('0x22')]],'as':_0x4a771b['as'],'attributes':_0x4a771b['attributes'],'include':_0x4a771b[_0xed1f('0x1f')]?_[_0xed1f('0x20')](_0x4a771b[_0xed1f('0x1f')],function(_0x211c51){return{'model':db[_0x211c51[_0xed1f('0x22')]],'as':_0x211c51['as'],'attributes':_0x211c51[_0xed1f('0x21')],'include':_0x211c51[_0xed1f('0x1f')]?_[_0xed1f('0x20')](_0x211c51[_0xed1f('0x1f')],function(_0x10b2f2){return{'model':db[_0x10b2f2[_0xed1f('0x22')]],'as':_0x10b2f2['as'],'attributes':_0x10b2f2[_0xed1f('0x21')]};}):[]};}):[]};}):[]:[]})[_0xed1f('0xc')](function(_0x37a1ad){logger[_0xed1f('0xd')](_0xed1f('0x23'),_0x541e46);logger[_0xed1f('0xf')](_0xed1f('0x23'),_0x541e46,JSON[_0xed1f('0x12')](_0x37a1ad));_0x4420f3(_0x37a1ad);})['catch'](function(_0x1fa3a6){logger['error'](_0xed1f('0x23'),_0x1fa3a6[_0xed1f('0x15')],_0x541e46);_0x924921(_0xd3b497[_0xed1f('0x13')](0x1f4,_0x1fa3a6['message']));});});};
\ No newline at end of file
+var _0xfac1=['message','result','catch','GetDynamics365Account','Dynamics365Account','findAll','options','raw','where','include','map','model','attributes','stringify','ShowDynamics365Account','find','lodash','util','moment','bluebird','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','../../config/environment','jayson/promise','client','request','then','info','Dynamics365Account,\x20%s,\x20%s','debug','Dynamics365Account,\x20%s,\x20%s,\x20%s','request\x20sent','error','code'];(function(_0x37a03a,_0x4828b4){var _0x317b23=function(_0x46df2d){while(--_0x46df2d){_0x37a03a['push'](_0x37a03a['shift']());}};_0x317b23(++_0x4828b4);}(_0xfac1,0xa4));var _0x1fac=function(_0x47a491,_0x45e171){_0x47a491=_0x47a491-0x0;var _0x3b176b=_0xfac1[_0x47a491];return _0x3b176b;};'use strict';var _=require(_0x1fac('0x0'));var util=require(_0x1fac('0x1'));var moment=require(_0x1fac('0x2'));var BPromise=require(_0x1fac('0x3'));var rs=require(_0x1fac('0x4'));var fs=require('fs');var Redis=require(_0x1fac('0x5'));var db=require(_0x1fac('0x6'))['db'];var utils=require(_0x1fac('0x7'));var logger=require(_0x1fac('0x8'))('rpc');var config=require(_0x1fac('0x9'));var jayson=require(_0x1fac('0xa'));var client=jayson[_0x1fac('0xb')]['http']({'port':0x232a});function respondWithRpcPromise(_0xf01d50,_0x111815,_0x336ae7){return new BPromise(function(_0x516d6e,_0x3bda36){return client[_0x1fac('0xc')](_0xf01d50,_0x336ae7)[_0x1fac('0xd')](function(_0x405ee1){logger[_0x1fac('0xe')](_0x1fac('0xf'),_0x111815,'request\x20sent');logger[_0x1fac('0x10')](_0x1fac('0x11'),_0x111815,_0x1fac('0x12'),JSON['stringify'](_0x405ee1));if(_0x405ee1[_0x1fac('0x13')]){if(_0x405ee1[_0x1fac('0x13')][_0x1fac('0x14')]===0x1f4){logger[_0x1fac('0x13')]('Dynamics365Account,\x20%s,\x20%s',_0x111815,_0x405ee1[_0x1fac('0x13')][_0x1fac('0x15')]);return _0x3bda36(_0x405ee1[_0x1fac('0x13')][_0x1fac('0x15')]);}logger[_0x1fac('0x13')](_0x1fac('0xf'),_0x111815,_0x405ee1[_0x1fac('0x13')]['message']);return _0x516d6e(_0x405ee1[_0x1fac('0x13')]['message']);}else{logger[_0x1fac('0xe')](_0x1fac('0xf'),_0x111815,'request\x20sent');_0x516d6e(_0x405ee1[_0x1fac('0x16')][_0x1fac('0x15')]);}})[_0x1fac('0x17')](function(_0x1ab1d2){logger['error']('Dynamics365Account,\x20%s,\x20%s',_0x111815,_0x1ab1d2);_0x3bda36(_0x1ab1d2);});});}exports[_0x1fac('0x18')]=function(_0x51df8f){var _0x2d7d63=this;return new Promise(function(_0x382089,_0x12aa3c){return db[_0x1fac('0x19')][_0x1fac('0x1a')]({'raw':_0x51df8f[_0x1fac('0x1b')]?_0x51df8f[_0x1fac('0x1b')][_0x1fac('0x1c')]===undefined?!![]:![]:!![],'where':_0x51df8f[_0x1fac('0x1b')]?_0x51df8f[_0x1fac('0x1b')][_0x1fac('0x1d')]||null:null,'attributes':_0x51df8f[_0x1fac('0x1b')]?_0x51df8f[_0x1fac('0x1b')]['attributes']||null:null,'limit':_0x51df8f[_0x1fac('0x1b')]?_0x51df8f[_0x1fac('0x1b')]['limit']||null:null,'include':_0x51df8f[_0x1fac('0x1b')]?_0x51df8f['options'][_0x1fac('0x1e')]?_[_0x1fac('0x1f')](_0x51df8f[_0x1fac('0x1b')][_0x1fac('0x1e')],function(_0x2ff7fe){return{'model':db[_0x2ff7fe[_0x1fac('0x20')]],'as':_0x2ff7fe['as'],'attributes':_0x2ff7fe[_0x1fac('0x21')],'include':_0x2ff7fe[_0x1fac('0x1e')]?_[_0x1fac('0x1f')](_0x2ff7fe[_0x1fac('0x1e')],function(_0x39805e){return{'model':db[_0x39805e[_0x1fac('0x20')]],'as':_0x39805e['as'],'attributes':_0x39805e[_0x1fac('0x21')],'include':_0x39805e[_0x1fac('0x1e')]?_[_0x1fac('0x1f')](_0x39805e[_0x1fac('0x1e')],function(_0x2be3c2){return{'model':db[_0x2be3c2[_0x1fac('0x20')]],'as':_0x2be3c2['as'],'attributes':_0x2be3c2[_0x1fac('0x21')]};}):[]};}):[]};}):[]:[]})[_0x1fac('0xd')](function(_0x5743f6){logger[_0x1fac('0xe')](_0x1fac('0x18'),_0x51df8f);logger[_0x1fac('0x10')]('GetDynamics365Account',_0x51df8f,JSON[_0x1fac('0x22')](_0x5743f6));_0x382089(_0x5743f6);})[_0x1fac('0x17')](function(_0x544d95){logger[_0x1fac('0x13')](_0x1fac('0x18'),_0x544d95[_0x1fac('0x15')],_0x51df8f);_0x12aa3c(_0x2d7d63[_0x1fac('0x13')](0x1f4,_0x544d95[_0x1fac('0x15')]));});});};exports[_0x1fac('0x23')]=function(_0x1ea47e){var _0x1ca76f=this;return new Promise(function(_0x58c1f9,_0x3775b7){return db[_0x1fac('0x19')][_0x1fac('0x24')]({'raw':_0x1ea47e[_0x1fac('0x1b')]?_0x1ea47e['options'][_0x1fac('0x1c')]===undefined?!![]:![]:!![],'where':_0x1ea47e['options']?_0x1ea47e[_0x1fac('0x1b')][_0x1fac('0x1d')]||null:null,'attributes':_0x1ea47e[_0x1fac('0x1b')]?_0x1ea47e['options']['attributes']||null:null,'include':_0x1ea47e[_0x1fac('0x1b')]?_0x1ea47e[_0x1fac('0x1b')][_0x1fac('0x1e')]?_[_0x1fac('0x1f')](_0x1ea47e['options'][_0x1fac('0x1e')],function(_0x24a3d3){return{'model':db[_0x24a3d3['model']],'as':_0x24a3d3['as'],'attributes':_0x24a3d3[_0x1fac('0x21')],'include':_0x24a3d3[_0x1fac('0x1e')]?_[_0x1fac('0x1f')](_0x24a3d3['include'],function(_0x26718c){return{'model':db[_0x26718c[_0x1fac('0x20')]],'as':_0x26718c['as'],'attributes':_0x26718c[_0x1fac('0x21')],'include':_0x26718c[_0x1fac('0x1e')]?_[_0x1fac('0x1f')](_0x26718c['include'],function(_0x434362){return{'model':db[_0x434362[_0x1fac('0x20')]],'as':_0x434362['as'],'attributes':_0x434362[_0x1fac('0x21')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x2f2490){logger[_0x1fac('0xe')](_0x1fac('0x23'),_0x1ea47e);logger['debug'](_0x1fac('0x23'),_0x1ea47e,JSON[_0x1fac('0x22')](_0x2f2490));_0x58c1f9(_0x2f2490);})['catch'](function(_0x27f5f3){logger[_0x1fac('0x13')](_0x1fac('0x23'),_0x27f5f3['message'],_0x1ea47e);_0x3775b7(_0x1ca76f[_0x1fac('0x13')](0x1f4,_0x27f5f3[_0x1fac('0x15')]));});});};
\ No newline at end of file