Built motion from commit (unavailable).|2.5.10
[motion2.git] / server / api / interval / interval.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 _0xcfac=['./interval.attributes','../../components/extensions/rewrite','exports','define','Interval','rewrite','lodash','util','../../config/logger','api','moment','bluebird','request-promise','path','rimraf'];(function(_0x31bade,_0x244a88){var _0x68ef90=function(_0x4038db){while(--_0x4038db){_0x31bade['push'](_0x31bade['shift']());}};_0x68ef90(++_0x244a88);}(_0xcfac,0x105));var _0xccfa=function(_0x1215b4,_0x4e5c40){_0x1215b4=_0x1215b4-0x0;var _0x2c220d=_0xcfac[_0x1215b4];return _0x2c220d;};'use strict';var _=require(_0xccfa('0x0'));var util=require(_0xccfa('0x1'));var logger=require(_0xccfa('0x2'))(_0xccfa('0x3'));var moment=require(_0xccfa('0x4'));var BPromise=require(_0xccfa('0x5'));var rp=require(_0xccfa('0x6'));var fs=require('fs');var path=require(_0xccfa('0x7'));var rimraf=require(_0xccfa('0x8'));var config=require('../../config/environment');var attributes=require(_0xccfa('0x9'));var extensions=require(_0xccfa('0xa'));module[_0xccfa('0xb')]=function(_0x1ba378,_0x1529e7){return _0x1ba378[_0xccfa('0xc')](_0xccfa('0xd'),attributes,{'tableName':'tools_intervals','paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'afterCreate':function(_0x3ffc00,_0xf20174){extensions[_0xccfa('0xe')](_0x1ba378,_0x3ffc00);},'afterBulkCreate':function(_0x27b3cb,_0x19e0b3,_0x4f3db0){_0x4f3db0();extensions[_0xccfa('0xe')](_0x1ba378,_0x27b3cb[0x0]);},'afterUpdate':function(_0x6ec8be,_0x49ed6e){extensions[_0xccfa('0xe')](_0x1ba378,_0x6ec8be);},'afterDestroy':function(_0x3c1cbc,_0x8b8e33){extensions[_0xccfa('0xe')](_0x1ba378,_0x3c1cbc);}}});};