Built motion from commit d5e4af8c.|2.6.23
[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 _0x3c82=['_previousDataValues','then','catch','models','MailSubstatus','mail_substatuses','name','mailSubstatus'];(function(_0x524515,_0x52d779){var _0x1ce231=function(_0x103cec){while(--_0x103cec){_0x524515['push'](_0x524515['shift']());}};_0x1ce231(++_0x52d779);}(_0x3c82,0x1f3));var _0x23c8=function(_0x5e477e,_0x50aebb){_0x5e477e=_0x5e477e-0x0;var _0x408a61=_0x3c82[_0x5e477e];return _0x408a61;};'use strict';var attributes=require('./mailSubstatus.attributes');module['exports']=function(_0x5d96af){var _0x5c16a0=_0x5d96af[_0x23c8('0x0')];return _0x5d96af['define'](_0x23c8('0x1'),attributes,{'tableName':_0x23c8('0x2'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'afterUpdate':function(_0x1e5b3c,_0x13ebe1,_0x5f480b){return _0x5c16a0['Condition']['update']({'value':_0x1e5b3c[_0x23c8('0x3')]},{'where':{'field':_0x23c8('0x4'),'value':_0x1e5b3c[_0x23c8('0x5')][_0x23c8('0x3')]}})[_0x23c8('0x6')](function(){_0x5f480b();})[_0x23c8('0x7')](function(_0x2bcb30){_0x5f480b(_0x2bcb30);});}}});};