00360296f24ca450c6f9ac94f8591608462fa32c
[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 _0x7d5a=['clientSideLoggingEnabledSince','./user-setting.attributes','exports','define','UserSetting','user_settings'];(function(_0x13d2a2,_0x4a5e40){var _0x39445b=function(_0x48af7b){while(--_0x48af7b){_0x13d2a2['push'](_0x13d2a2['shift']());}};_0x39445b(++_0x4a5e40);}(_0x7d5a,0x17b));var _0xa7d5=function(_0x40ab1c,_0x2e4cf1){_0x40ab1c=_0x40ab1c-0x0;var _0x40b651=_0x7d5a[_0x40ab1c];return _0x40b651;};'use strict';var attributes=require(_0xa7d5('0x0'));module[_0xa7d5('0x1')]=function(_0x125acd){return _0x125acd[_0xa7d5('0x2')](_0xa7d5('0x3'),attributes,{'tableName':_0xa7d5('0x4'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x10df7a){if(!_0x10df7a['clientSideLoggingEnabled'])_0x10df7a['clientSideLoggingEnabledSince']=null;else if(_0x10df7a[_0xa7d5('0x5')]===null)_0x10df7a[_0xa7d5('0x5')]=new Date();}}});};