Built motion from commit 896e83a8.|2.6.30
[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 _0x659c=['setDataValue','startedAt','subtract','closedAt','duration','DATE','format','MM-DD-YYYY\x20HH:mm','toString','createdAt','sequelize','../../config/environment','exports','getDataValue','value','STRING'];(function(_0xe0d64b,_0x5f0fef){var _0x480aed=function(_0x31a3ce){while(--_0x31a3ce){_0xe0d64b['push'](_0xe0d64b['shift']());}};_0x480aed(++_0x5f0fef);}(_0x659c,0x1aa));var _0xc659=function(_0x45c10a,_0x4b9090){_0x45c10a=_0x45c10a-0x0;var _0x3f680=_0x659c[_0x45c10a];return _0x3f680;};'use strict';var Sequelize=require(_0xc659('0x0'));var moment=require('moment');var path=require('path');var config=require(_0xc659('0x1'));module[_0xc659('0x2')]={'format':{'type':Sequelize['VIRTUAL'],'get':function(){return this[_0xc659('0x3')](_0xc659('0x4'))?path['extname'](this['getDataValue'](_0xc659('0x4'))):undefined;}},'interactionid':{'type':Sequelize[_0xc659('0x5')]},'channel':{'type':Sequelize[_0xc659('0x5')]},'value':{'type':Sequelize[_0xc659('0x5')],'set':function(_0x15e20b){var _0x33e9d9=_0x15e20b['replace'](/\\/g,'/');this['setDataValue'](_0xc659('0x4'),_0x33e9d9);}},'rating':{'type':Sequelize['INTEGER'],'validate':{'max':0x5,'min':0x0}},'duration':{'type':Sequelize['INTEGER'],'set':function(_0x4fadc2){this[_0xc659('0x6')](_0xc659('0x7'),moment()[_0xc659('0x8')](_0x4fadc2,'ms'));this[_0xc659('0x6')](_0xc659('0x9'),moment());this[_0xc659('0x6')](_0xc659('0xa'),_0x4fadc2);}},'startedAt':{'type':Sequelize[_0xc659('0xb')],'get':function(){return moment(this['getDataValue'](_0xc659('0x7')))[_0xc659('0xc')](_0xc659('0xd'))['toString']();}},'closedAt':{'type':Sequelize['DATE'],'get':function(){return moment(this[_0xc659('0x3')](_0xc659('0x9')))['format'](_0xc659('0xd'))[_0xc659('0xe')]();}},'createdAt':{'type':Sequelize[_0xc659('0xb')],'get':function(){return moment(this[_0xc659('0x3')](_0xc659('0xf')))[_0xc659('0xc')](_0xc659('0xd'))[_0xc659('0xe')]();}},'updatedAt':{'type':Sequelize[_0xc659('0xb')],'get':function(){return moment(this[_0xc659('0x3')]('updatedAt'))[_0xc659('0xc')](_0xc659('0xd'))[_0xc659('0xe')]();}}};