Built motion from commit da617fac.|2.6.6
[motion2.git] / server / api / disposition / disposition.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 _0xb3f0=['name_fax','name_openchannel','WhatsappAccountId','util','../../config/logger','moment','bluebird','path','rimraf','../../config/environment','./disposition.attributes','exports','Disposition','tools_dispositions','name_voice','ListId','name','ChatWebsiteId','name_mail','name_sms','SmsAccountId'];(function(_0x44474f,_0x431580){var _0x427d97=function(_0x53f7d4){while(--_0x53f7d4){_0x44474f['push'](_0x44474f['shift']());}};_0x427d97(++_0x431580);}(_0xb3f0,0x96));var _0x0b3f=function(_0x365be9,_0x3c88b9){_0x365be9=_0x365be9-0x0;var _0x185c12=_0xb3f0[_0x365be9];return _0x185c12;};'use strict';var _=require('lodash');var util=require(_0x0b3f('0x0'));var logger=require(_0x0b3f('0x1'))('api');var moment=require(_0x0b3f('0x2'));var BPromise=require(_0x0b3f('0x3'));var rp=require('request-promise');var fs=require('fs');var path=require(_0x0b3f('0x4'));var rimraf=require(_0x0b3f('0x5'));var config=require(_0x0b3f('0x6'));var attributes=require(_0x0b3f('0x7'));module[_0x0b3f('0x8')]=function(_0x37cf64,_0x15d87d){return _0x37cf64['define'](_0x0b3f('0x9'),attributes,{'tableName':_0x0b3f('0xa'),'paranoid':![],'indexes':[{'unique':!![],'name':_0x0b3f('0xb'),'fields':['name',_0x0b3f('0xc')]},{'unique':!![],'name':'name_chat','fields':[_0x0b3f('0xd'),_0x0b3f('0xe')]},{'unique':!![],'name':_0x0b3f('0xf'),'fields':[_0x0b3f('0xd'),'MailAccountId']},{'unique':!![],'name':_0x0b3f('0x10'),'fields':[_0x0b3f('0xd'),_0x0b3f('0x11')]},{'unique':!![],'name':_0x0b3f('0x12'),'fields':[_0x0b3f('0xd'),'FaxAccountId']},{'unique':!![],'name':_0x0b3f('0x13'),'fields':[_0x0b3f('0xd'),'OpenchannelAccountId']},{'unique':!![],'name':'name_whatsapp','fields':[_0x0b3f('0xd'),_0x0b3f('0x14')]}],'timestamps':!![]});};