927c58ad4b1e0384618434bc69b6be81f9718f94
[motion2.git] / server / api / mailSubstatus / mailSubstatus.model.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and   *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0xadf9=['_previousDataValues','catch','./mailSubstatus.attributes','exports','define','MailSubstatus','update','name','mailSubstatus'];(function(_0x348ed6,_0x58bd43){var _0x495876=function(_0x315f1){while(--_0x315f1){_0x348ed6['push'](_0x348ed6['shift']());}};_0x495876(++_0x58bd43);}(_0xadf9,0xa4));var _0x9adf=function(_0x53f5ec,_0x34bca9){_0x53f5ec=_0x53f5ec-0x0;var _0x4e2d6a=_0xadf9[_0x53f5ec];return _0x4e2d6a;};'use strict';var attributes=require(_0x9adf('0x0'));module[_0x9adf('0x1')]=function(_0x44646b){var _0x581fb4=_0x44646b['models'];return _0x44646b[_0x9adf('0x2')](_0x9adf('0x3'),attributes,{'tableName':'mail_substatuses','paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'afterUpdate':function(_0x38dce5,_0x37e7fc,_0x23f17f){return _0x581fb4['Condition'][_0x9adf('0x4')]({'value':_0x38dce5[_0x9adf('0x5')]},{'where':{'field':_0x9adf('0x6'),'value':_0x38dce5[_0x9adf('0x7')][_0x9adf('0x5')]}})['then'](function(){_0x23f17f();})[_0x9adf('0x8')](function(_0x1d7d85){_0x23f17f(_0x1d7d85);});}}});};