Built motion from commit ff78e754.|2.6.29
[motion2.git] / server / api / openchannelInteraction / openchannelInteraction.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 _0x737f=['utf8mb4','utf8mb4_unicode_ci','changed','closed','closedAt','YYYY-MM-DD\x20HH:mm:ss','lodash','util','../../config/logger','api','moment','request-promise','path','rimraf','../../config/environment','./openchannelInteraction.attributes','exports','define','openchannel_interactions'];(function(_0x7d9d62,_0x59061b){var _0x3ed57a=function(_0x55df71){while(--_0x55df71){_0x7d9d62['push'](_0x7d9d62['shift']());}};_0x3ed57a(++_0x59061b);}(_0x737f,0x8b));var _0xf737=function(_0x3d15ba,_0x10d3ae){_0x3d15ba=_0x3d15ba-0x0;var _0xd9714d=_0x737f[_0x3d15ba];return _0xd9714d;};'use strict';var _=require(_0xf737('0x0'));var util=require(_0xf737('0x1'));var logger=require(_0xf737('0x2'))(_0xf737('0x3'));var moment=require(_0xf737('0x4'));var BPromise=require('bluebird');var rp=require(_0xf737('0x5'));var fs=require('fs');var path=require(_0xf737('0x6'));var rimraf=require(_0xf737('0x7'));var config=require(_0xf737('0x8'));var attributes=require(_0xf737('0x9'));module[_0xf737('0xa')]=function(_0x1d7ff3,_0x57c7dc){return _0x1d7ff3[_0xf737('0xb')]('OpenchannelInteraction',attributes,{'tableName':_0xf737('0xc'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0xf737('0xd'),'collate':_0xf737('0xe'),'hooks':{'beforeUpdate':function(_0x3288c6,_0x32fe39,_0x38957d){if(_0x3288c6[_0xf737('0xf')](_0xf737('0x10'))){_0x3288c6[_0xf737('0x11')]=moment()['format'](_0xf737('0x12'));}_0x38957d(null,_0x3288c6);}}});};