Built motion from commit 37e1ed56.|2.6.29
[motion2.git] / server / api / team / team.model.js
index 056e083..44e80fb 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xf059=['Fax','Mail','Openchannel','Sms','Voice','Whatsapp','resolve','then','all','lodash','./team.attributes','get','Queues','map','setDataValue','channel','catch','exports','define','teams'];(function(_0x441dd4,_0x582db9){var _0x54ea8b=function(_0x308f42){while(--_0x308f42){_0x441dd4['push'](_0x441dd4['shift']());}};_0x54ea8b(++_0x582db9);}(_0xf059,0x1c1));var _0x9f05=function(_0x38abab,_0x5614b6){_0x38abab=_0x38abab-0x0;var _0x1d2ca3=_0xf059[_0x38abab];return _0x1d2ca3;};'use strict';var _=require(_0x9f05('0x0'));var attributes=require(_0x9f05('0x1'));function getQueuesByChannel(_0x3abb4c,_0x1b4f42){var _0x3e8d23=_0x9f05('0x2')+_0x1b4f42+_0x9f05('0x3');return _0x3abb4c[_0x3e8d23]()['then'](function(_0x6b8bcd){return _[_0x9f05('0x4')](_0x6b8bcd,function(_0x3b017f){_0x3b017f[_0x9f05('0x5')](_0x9f05('0x6'),_0x1b4f42);return _0x3b017f;});})[_0x9f05('0x7')](function(_0x4c18b3){throw _0x4c18b3;});}module[_0x9f05('0x8')]=function(_0x5acc93){return _0x5acc93[_0x9f05('0x9')]('Team',attributes,{'tableName':_0x9f05('0xa'),'paranoid':![],'indexes':[],'timestamps':!![],'instanceMethods':{'getAssociatedQueues':function(){var _0x91e530=this;var _0x34c199=['Chat',_0x9f05('0xb'),_0x9f05('0xc'),_0x9f05('0xd'),_0x9f05('0xe'),_0x9f05('0xf'),_0x9f05('0x10')];return Promise[_0x9f05('0x11')]()[_0x9f05('0x12')](function(){var _0x3d3506=_[_0x9f05('0x4')](_0x34c199,function(_0x9411b9){return getQueuesByChannel(_0x91e530,_0x9411b9);});return Promise[_0x9f05('0x13')](_0x3d3506);})[_0x9f05('0x7')](function(_0x383d16){throw _0x383d16;});}}});};
\ No newline at end of file
+var _0x54d2=['then','map','setDataValue','catch','exports','define','teams','Chat','Mail','Sms','Voice','Whatsapp','resolve','Queues'];(function(_0x149b67,_0x1ca39c){var _0x3ba51b=function(_0x47216d){while(--_0x47216d){_0x149b67['push'](_0x149b67['shift']());}};_0x3ba51b(++_0x1ca39c);}(_0x54d2,0x15d));var _0x254d=function(_0x3a3079,_0x5053e1){_0x3a3079=_0x3a3079-0x0;var _0x16171f=_0x54d2[_0x3a3079];return _0x16171f;};'use strict';var _=require('lodash');var attributes=require('./team.attributes');function getQueuesByChannel(_0x1bf2fe,_0x205a07){var _0x4e2e2f='get'+_0x205a07+_0x254d('0x0');return _0x1bf2fe[_0x4e2e2f]()[_0x254d('0x1')](function(_0x2f328c){return _[_0x254d('0x2')](_0x2f328c,function(_0x1291c7){_0x1291c7[_0x254d('0x3')]('channel',_0x205a07);return _0x1291c7;});})[_0x254d('0x4')](function(_0x5ef04f){throw _0x5ef04f;});}module[_0x254d('0x5')]=function(_0x3f85d0){return _0x3f85d0[_0x254d('0x6')]('Team',attributes,{'tableName':_0x254d('0x7'),'paranoid':![],'indexes':[],'timestamps':!![],'instanceMethods':{'getAssociatedQueues':function(){var _0x19af2c=this;var _0x971be=[_0x254d('0x8'),'Fax',_0x254d('0x9'),'Openchannel',_0x254d('0xa'),_0x254d('0xb'),_0x254d('0xc')];return Promise[_0x254d('0xd')]()['then'](function(){var _0x110bd7=_[_0x254d('0x2')](_0x971be,function(_0x550639){return getQueuesByChannel(_0x19af2c,_0x550639);});return Promise['all'](_0x110bd7);})[_0x254d('0x4')](function(_0xd04fb9){throw _0xd04fb9;});}}});};
\ No newline at end of file