Built motion from commit (unavailable).|2.5.11
[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 _0x159b=['rewrite','lodash','util','../../config/logger','api','moment','bluebird','request-promise','path','../../config/environment','./interval.attributes','../../components/extensions/rewrite','exports','define','Interval','tools_intervals'];(function(_0x180c35,_0x16bc0a){var _0x425cf8=function(_0x9ed6c0){while(--_0x9ed6c0){_0x180c35['push'](_0x180c35['shift']());}};_0x425cf8(++_0x16bc0a);}(_0x159b,0x181));var _0xb159=function(_0x11e404,_0x47e1af){_0x11e404=_0x11e404-0x0;var _0x27b0ea=_0x159b[_0x11e404];return _0x27b0ea;};'use strict';var _=require(_0xb159('0x0'));var util=require(_0xb159('0x1'));var logger=require(_0xb159('0x2'))(_0xb159('0x3'));var moment=require(_0xb159('0x4'));var BPromise=require(_0xb159('0x5'));var rp=require(_0xb159('0x6'));var fs=require('fs');var path=require(_0xb159('0x7'));var rimraf=require('rimraf');var config=require(_0xb159('0x8'));var attributes=require(_0xb159('0x9'));var extensions=require(_0xb159('0xa'));module[_0xb159('0xb')]=function(_0x4a6e2e,_0x42f080){return _0x4a6e2e[_0xb159('0xc')](_0xb159('0xd'),attributes,{'tableName':_0xb159('0xe'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'afterCreate':function(_0x11afdc,_0x7f9727){extensions[_0xb159('0xf')](_0x4a6e2e,_0x11afdc);},'afterBulkCreate':function(_0x27238a,_0x2df975,_0x130e72){_0x130e72();extensions[_0xb159('0xf')](_0x4a6e2e,_0x27238a[0x0]);},'afterUpdate':function(_0x45a7c9,_0x424e93){extensions['rewrite'](_0x4a6e2e,_0x45a7c9);},'afterDestroy':function(_0x4b3df1,_0x36386e){extensions[_0xb159('0xf')](_0x4a6e2e,_0x4b3df1);}}});};