Built motion from commit 936e8062.|2.5.33
[motion2.git] / server / api / cmCustomField / cmCustomField.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 _0x8ca1=['setDataValue','getDataValue','name','TEXT','long','values','isArray','stringify','BOOLEAN','lodash','VIRTUAL','STRING'];(function(_0x3dd15e,_0x1f0015){var _0x231fd0=function(_0x4f680a){while(--_0x4f680a){_0x3dd15e['push'](_0x3dd15e['shift']());}};_0x231fd0(++_0x1f0015);}(_0x8ca1,0x69));var _0x18ca=function(_0x14add3,_0x13ce8d){_0x14add3=_0x14add3-0x0;var _0x4a174f=_0x8ca1[_0x14add3];return _0x4a174f;};'use strict';var Sequelize=require('sequelize');var _=require(_0x18ca('0x0'));module['exports']={'name':{'type':Sequelize[_0x18ca('0x1')],'get':function(_0x4eeecb){return this['getDataValue']('alias');}},'alias':{'type':Sequelize[_0x18ca('0x2')],'allowNull':![],'set':function(_0x5e810f){this[_0x18ca('0x3')]('alias',_0x5e810f?_0x5e810f:this[_0x18ca('0x4')](_0x18ca('0x5')));}},'type':{'type':Sequelize['STRING'],'allowNull':![]},'values':{'type':Sequelize[_0x18ca('0x6')](_0x18ca('0x7')),'get':function(){if(this['getDataValue']('type')==='select'){return JSON['parse'](this[_0x18ca('0x4')](_0x18ca('0x8')));}else{return this[_0x18ca('0x4')]('values');}},'set':function(_0x1020e9){if(Array[_0x18ca('0x9')](_0x1020e9)){this[_0x18ca('0x3')](_0x18ca('0x8'),JSON[_0x18ca('0xa')](_0x1020e9));}else{this[_0x18ca('0x3')](_0x18ca('0x8'),_0x1020e9);}}},'required':{'type':Sequelize[_0x18ca('0xb')],'defaultValue':![]},'clickToAction':{'type':Sequelize[_0x18ca('0xb')],'defaultValue':![]},'actionType':{'type':Sequelize['ENUM']('voice')}};