Built motion from commit d5e4af8c.|2.6.23
[motion2.git] / server / api / mailApplication / mailApplication.rpc.js
index cabdfb4..49b86fa 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x204f=['attributes','limit','lodash','util','moment','bluebird','randomstring','../../mysqldb','../../config/utils','../../config/logger','client','http','request','then','info','request\x20sent','debug','MailApplication,\x20%s,\x20%s,\x20%s','stringify','error','code','MailApplication,\x20%s,\x20%s','message','result','catch','UpdateMailApplication','MailApplication','update','options'];(function(_0x1e1b12,_0x4ce9f5){var _0x118f5d=function(_0x2000aa){while(--_0x2000aa){_0x1e1b12['push'](_0x1e1b12['shift']());}};_0x118f5d(++_0x4ce9f5);}(_0x204f,0x15e));var _0xf204=function(_0x367584,_0x57e019){_0x367584=_0x367584-0x0;var _0xf1652f=_0x204f[_0x367584];return _0xf1652f;};'use strict';var _=require(_0xf204('0x0'));var util=require(_0xf204('0x1'));var moment=require(_0xf204('0x2'));var BPromise=require(_0xf204('0x3'));var rs=require(_0xf204('0x4'));var fs=require('fs');var Redis=require('ioredis');var db=require(_0xf204('0x5'))['db'];var utils=require(_0xf204('0x6'));var logger=require(_0xf204('0x7'))('rpc');var config=require('../../config/environment');var jayson=require('jayson/promise');var client=jayson[_0xf204('0x8')][_0xf204('0x9')]({'port':0x232a});function respondWithRpcPromise(_0x3d9e05,_0xa5b976,_0x382bcd){return new BPromise(function(_0x38a1aa,_0x2d4786){return client[_0xf204('0xa')](_0x3d9e05,_0x382bcd)[_0xf204('0xb')](function(_0xf9a346){logger[_0xf204('0xc')]('MailApplication,\x20%s,\x20%s',_0xa5b976,_0xf204('0xd'));logger[_0xf204('0xe')](_0xf204('0xf'),_0xa5b976,_0xf204('0xd'),JSON[_0xf204('0x10')](_0xf9a346));if(_0xf9a346[_0xf204('0x11')]){if(_0xf9a346[_0xf204('0x11')][_0xf204('0x12')]===0x1f4){logger[_0xf204('0x11')](_0xf204('0x13'),_0xa5b976,_0xf9a346[_0xf204('0x11')][_0xf204('0x14')]);return _0x2d4786(_0xf9a346['error'][_0xf204('0x14')]);}logger[_0xf204('0x11')](_0xf204('0x13'),_0xa5b976,_0xf9a346[_0xf204('0x11')][_0xf204('0x14')]);return _0x38a1aa(_0xf9a346[_0xf204('0x11')][_0xf204('0x14')]);}else{logger[_0xf204('0xc')](_0xf204('0x13'),_0xa5b976,'request\x20sent');_0x38a1aa(_0xf9a346[_0xf204('0x15')][_0xf204('0x14')]);}})[_0xf204('0x16')](function(_0x2b6001){logger[_0xf204('0x11')](_0xf204('0x13'),_0xa5b976,_0x2b6001);_0x2d4786(_0x2b6001);});});}exports[_0xf204('0x17')]=function(_0x4d85c8){var _0x1672c3=this;return new Promise(function(_0x41f38f,_0x49e7ce){return db[_0xf204('0x18')][_0xf204('0x19')](_0x4d85c8['body'],{'raw':_0x4d85c8[_0xf204('0x1a')]?_0x4d85c8['options']['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x4d85c8[_0xf204('0x1a')]?_0x4d85c8[_0xf204('0x1a')]['where']||null:null,'attributes':_0x4d85c8['options']?_0x4d85c8[_0xf204('0x1a')][_0xf204('0x1b')]||null:null,'limit':_0x4d85c8[_0xf204('0x1a')]?_0x4d85c8[_0xf204('0x1a')][_0xf204('0x1c')]||null:null})[_0xf204('0xb')](function(_0x43ac30){logger['info'](_0xf204('0x17'),_0x4d85c8);logger['debug'](_0xf204('0x17'),_0x4d85c8,JSON[_0xf204('0x10')](_0x43ac30));_0x41f38f(_0x43ac30);})[_0xf204('0x16')](function(_0x456482){logger[_0xf204('0x11')](_0xf204('0x17'),_0x456482[_0xf204('0x14')],_0x4d85c8);_0x49e7ce(_0x1672c3[_0xf204('0x11')](0x1f4,_0x456482[_0xf204('0x14')]));});});};
\ No newline at end of file
+var _0xed22=['MailApplication,\x20%s,\x20%s','request\x20sent','debug','MailApplication,\x20%s,\x20%s,\x20%s','stringify','error','message','info','result','catch','UpdateMailApplication','MailApplication','body','options','where','attributes','limit','util','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','rpc','../../config/environment','jayson/promise','client','http','request','then'];(function(_0x2293da,_0x3a3686){var _0x11c5cd=function(_0x3e43f0){while(--_0x3e43f0){_0x2293da['push'](_0x2293da['shift']());}};_0x11c5cd(++_0x3a3686);}(_0xed22,0x101));var _0x2ed2=function(_0x501078,_0x5bb1e9){_0x501078=_0x501078-0x0;var _0x18eaac=_0xed22[_0x501078];return _0x18eaac;};'use strict';var _=require('lodash');var util=require(_0x2ed2('0x0'));var moment=require('moment');var BPromise=require('bluebird');var rs=require(_0x2ed2('0x1'));var fs=require('fs');var Redis=require(_0x2ed2('0x2'));var db=require(_0x2ed2('0x3'))['db'];var utils=require(_0x2ed2('0x4'));var logger=require(_0x2ed2('0x5'))(_0x2ed2('0x6'));var config=require(_0x2ed2('0x7'));var jayson=require(_0x2ed2('0x8'));var client=jayson[_0x2ed2('0x9')][_0x2ed2('0xa')]({'port':0x232a});function respondWithRpcPromise(_0xd6db37,_0xd7eb08,_0x2fb359){return new BPromise(function(_0x2becf6,_0x1d0d9a){return client[_0x2ed2('0xb')](_0xd6db37,_0x2fb359)[_0x2ed2('0xc')](function(_0x69125d){logger['info'](_0x2ed2('0xd'),_0xd7eb08,_0x2ed2('0xe'));logger[_0x2ed2('0xf')](_0x2ed2('0x10'),_0xd7eb08,'request\x20sent',JSON[_0x2ed2('0x11')](_0x69125d));if(_0x69125d[_0x2ed2('0x12')]){if(_0x69125d[_0x2ed2('0x12')]['code']===0x1f4){logger[_0x2ed2('0x12')](_0x2ed2('0xd'),_0xd7eb08,_0x69125d[_0x2ed2('0x12')][_0x2ed2('0x13')]);return _0x1d0d9a(_0x69125d[_0x2ed2('0x12')][_0x2ed2('0x13')]);}logger[_0x2ed2('0x12')](_0x2ed2('0xd'),_0xd7eb08,_0x69125d['error'][_0x2ed2('0x13')]);return _0x2becf6(_0x69125d[_0x2ed2('0x12')][_0x2ed2('0x13')]);}else{logger[_0x2ed2('0x14')](_0x2ed2('0xd'),_0xd7eb08,_0x2ed2('0xe'));_0x2becf6(_0x69125d[_0x2ed2('0x15')][_0x2ed2('0x13')]);}})[_0x2ed2('0x16')](function(_0x1b7a9f){logger[_0x2ed2('0x12')](_0x2ed2('0xd'),_0xd7eb08,_0x1b7a9f);_0x1d0d9a(_0x1b7a9f);});});}exports[_0x2ed2('0x17')]=function(_0x1b5456){var _0x446644=this;return new Promise(function(_0x43e81e,_0x1d0471){return db[_0x2ed2('0x18')]['update'](_0x1b5456[_0x2ed2('0x19')],{'raw':_0x1b5456[_0x2ed2('0x1a')]?_0x1b5456['options']['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x1b5456[_0x2ed2('0x1a')]?_0x1b5456[_0x2ed2('0x1a')][_0x2ed2('0x1b')]||null:null,'attributes':_0x1b5456['options']?_0x1b5456[_0x2ed2('0x1a')][_0x2ed2('0x1c')]||null:null,'limit':_0x1b5456[_0x2ed2('0x1a')]?_0x1b5456['options'][_0x2ed2('0x1d')]||null:null})[_0x2ed2('0xc')](function(_0x4c0be7){logger[_0x2ed2('0x14')]('UpdateMailApplication',_0x1b5456);logger[_0x2ed2('0xf')](_0x2ed2('0x17'),_0x1b5456,JSON[_0x2ed2('0x11')](_0x4c0be7));_0x43e81e(_0x4c0be7);})[_0x2ed2('0x16')](function(_0x487978){logger['error'](_0x2ed2('0x17'),_0x487978['message'],_0x1b5456);_0x1d0471(_0x446644[_0x2ed2('0x12')](0x1f4,_0x487978[_0x2ed2('0x13')]));});});};
\ No newline at end of file