396b3ade63f598a3730cbb59eda8c584d7fd5c20
[motion2.git] / server / api / screenRecording / screenRecording.attributes.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 _0xbff2=['../../config/environment','exports','VIRTUAL','getDataValue','value','extname','STRING','replace','setDataValue','duration','startedAt','toString','DATE','closedAt','format','createdAt','MM-DD-YYYY\x20HH:mm','updatedAt','sequelize','moment','path'];(function(_0x265308,_0x43adb7){var _0x28b812=function(_0x58b317){while(--_0x58b317){_0x265308['push'](_0x265308['shift']());}};_0x28b812(++_0x43adb7);}(_0xbff2,0x10e));var _0x2bff=function(_0x2571c4,_0x156e5b){_0x2571c4=_0x2571c4-0x0;var _0x2e11c7=_0xbff2[_0x2571c4];return _0x2e11c7;};'use strict';var Sequelize=require(_0x2bff('0x0'));var moment=require(_0x2bff('0x1'));var path=require(_0x2bff('0x2'));var config=require(_0x2bff('0x3'));module[_0x2bff('0x4')]={'format':{'type':Sequelize[_0x2bff('0x5')],'get':function(){return this[_0x2bff('0x6')](_0x2bff('0x7'))?path[_0x2bff('0x8')](this['getDataValue'](_0x2bff('0x7'))):undefined;}},'interactionid':{'type':Sequelize[_0x2bff('0x9')]},'channel':{'type':Sequelize['STRING']},'value':{'type':Sequelize['STRING'],'set':function(_0x48838e){var _0x318d56=_0x48838e[_0x2bff('0xa')](/\\/g,'/');this['setDataValue'](_0x2bff('0x7'),_0x318d56);}},'rating':{'type':Sequelize['INTEGER'],'validate':{'max':0x5,'min':0x0}},'duration':{'type':Sequelize['INTEGER'],'set':function(_0x172498){this['setDataValue']('startedAt',moment()['subtract'](_0x172498,'ms'));this[_0x2bff('0xb')]('closedAt',moment());this[_0x2bff('0xb')](_0x2bff('0xc'),_0x172498);}},'startedAt':{'type':Sequelize['DATE'],'get':function(){return moment(this[_0x2bff('0x6')](_0x2bff('0xd')))['format']('MM-DD-YYYY\x20HH:mm')[_0x2bff('0xe')]();}},'closedAt':{'type':Sequelize[_0x2bff('0xf')],'get':function(){return moment(this['getDataValue'](_0x2bff('0x10')))[_0x2bff('0x11')]('MM-DD-YYYY\x20HH:mm')[_0x2bff('0xe')]();}},'createdAt':{'type':Sequelize[_0x2bff('0xf')],'get':function(){return moment(this[_0x2bff('0x6')](_0x2bff('0x12')))['format'](_0x2bff('0x13'))[_0x2bff('0xe')]();}},'updatedAt':{'type':Sequelize[_0x2bff('0xf')],'get':function(){return moment(this[_0x2bff('0x6')](_0x2bff('0x14')))[_0x2bff('0x11')]('MM-DD-YYYY\x20HH:mm')[_0x2bff('0xe')]();}}};