1 // *************************************************************************
3 // * xCALLY Motion - The Omnichannel Contact Center *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved *
6 // *************************************************************************
8 // * Email: info@xcally.com *
9 // * Website: https://www.xcally.com *
11 // *************************************************************************
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. *
17 // *************************************************************************
18 var _0x2f36=['join','sequelize','html-to-text','iconv','exports','BOOLEAN','DATE','STRING','TEXT','long','ENUM','out','getDataValue','lastMsgBody','fromString','split'];(function(_0xc54faf,_0x3ad988){var _0x88476f=function(_0x1a2d62){while(--_0x1a2d62){_0xc54faf['push'](_0xc54faf['shift']());}};_0x88476f(++_0x3ad988);}(_0x2f36,0x191));var _0x62f3=function(_0x134c2e,_0x3573c4){_0x134c2e=_0x134c2e-0x0;var _0x2825db=_0x2f36[_0x134c2e];return _0x2825db;};'use strict';var Sequelize=require(_0x62f3('0x0'));var htmlToText=require(_0x62f3('0x1'));var iconv=require(_0x62f3('0x2'));module[_0x62f3('0x3')]={'closed':{'type':Sequelize[_0x62f3('0x4')],'defaultValue':![]},'closedAt':{'type':Sequelize[_0x62f3('0x5')]},'disposition':{'type':Sequelize[_0x62f3('0x6')]},'note':{'type':Sequelize[_0x62f3('0x6')]},'inReplyTo':{'type':Sequelize[_0x62f3('0x6')](0x1fe)},'to':{'type':Sequelize[_0x62f3('0x6')]},'cc':{'type':Sequelize[_0x62f3('0x7')](_0x62f3('0x8'))},'subject':{'type':Sequelize[_0x62f3('0x7')]()},'attach':{'type':Sequelize[_0x62f3('0x4')],'defaultValue':![]},'read1stAt':{'type':Sequelize[_0x62f3('0x5')]},'substatus':{'type':Sequelize[_0x62f3('0x6')](0x3c)},'substatusAt':{'type':Sequelize[_0x62f3('0x5')]},'firstMsgDirection':{'type':Sequelize[_0x62f3('0x9')]('in',_0x62f3('0xa')),'defaultValue':'in','allowNull':![]},'lastMsgAt':{'type':Sequelize[_0x62f3('0x5')]},'lastMsgDirection':{'type':Sequelize[_0x62f3('0x9')]('in',_0x62f3('0xa')),'defaultValue':'in','allowNull':![]},'lastMsgBody':{'type':Sequelize[_0x62f3('0x7')](_0x62f3('0x8')),'get':function(){try{return this[_0x62f3('0xb')](_0x62f3('0xc'))?htmlToText[_0x62f3('0xd')](this[_0x62f3('0xb')](_0x62f3('0xc')),{'preserveNewlines':!![],'singleNewLineParagraphs':!![],'ignoreImage':!![]})[_0x62f3('0xe')]('\x0a')['slice'](0x0,0x6)[_0x62f3('0xf')]('\x0a'):null;}catch(_0x36122b){return null;}}}};