bda00c8968c5a1111bc2b777beb81d357eed5508
[motion2.git] / server / api / user-setting / user-setting.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 _0xd9dc=['user_settings','clientSideLoggingEnabledSince','exports','UserSetting'];(function(_0x1dd82f,_0x52acb7){var _0x353ca4=function(_0x5ee4c9){while(--_0x5ee4c9){_0x1dd82f['push'](_0x1dd82f['shift']());}};_0x353ca4(++_0x52acb7);}(_0xd9dc,0x1be));var _0xcd9d=function(_0x3a5b74,_0x4960ee){_0x3a5b74=_0x3a5b74-0x0;var _0x366746=_0xd9dc[_0x3a5b74];return _0x366746;};'use strict';var attributes=require('./user-setting.attributes');module[_0xcd9d('0x0')]=function(_0xc135c5){return _0xc135c5['define'](_0xcd9d('0x1'),attributes,{'tableName':_0xcd9d('0x2'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x8b7ba5){if(!_0x8b7ba5['clientSideLoggingEnabled'])_0x8b7ba5[_0xcd9d('0x3')]=null;else if(_0x8b7ba5[_0xcd9d('0x3')]===null)_0x8b7ba5[_0xcd9d('0x3')]=new Date();}}});};