Built motion from commit b5413ace.|2.6.9
[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 _0x13a4=['BOOLEAN','ENUM','VIRTUAL','getDataValue','alias','STRING','setDataValue','name','type','select','values','isArray','stringify'];(function(_0xbb6ac4,_0xc27d8d){var _0x320563=function(_0x48bbd9){while(--_0x48bbd9){_0xbb6ac4['push'](_0xbb6ac4['shift']());}};_0x320563(++_0xc27d8d);}(_0x13a4,0x91));var _0x413a=function(_0x3d865d,_0x3e04f8){_0x3d865d=_0x3d865d-0x0;var _0x49fda5=_0x13a4[_0x3d865d];return _0x49fda5;};'use strict';var Sequelize=require('sequelize');var _=require('lodash');module['exports']={'name':{'type':Sequelize[_0x413a('0x0')],'get':function(_0x39daf5){return this[_0x413a('0x1')](_0x413a('0x2'));}},'alias':{'type':Sequelize[_0x413a('0x3')],'allowNull':![],'set':function(_0x29f0c9){this[_0x413a('0x4')](_0x413a('0x2'),_0x29f0c9?_0x29f0c9:this['getDataValue'](_0x413a('0x5')));}},'type':{'type':Sequelize[_0x413a('0x3')],'allowNull':![]},'values':{'type':Sequelize['TEXT']('long'),'get':function(){if(this[_0x413a('0x1')](_0x413a('0x6'))===_0x413a('0x7')){return JSON['parse'](this[_0x413a('0x1')](_0x413a('0x8')));}else{return this['getDataValue'](_0x413a('0x8'));}},'set':function(_0x43f0dd){if(Array[_0x413a('0x9')](_0x43f0dd)){this[_0x413a('0x4')](_0x413a('0x8'),JSON[_0x413a('0xa')](_0x43f0dd));}else{this[_0x413a('0x4')]('values',_0x43f0dd);}}},'required':{'type':Sequelize[_0x413a('0xb')],'defaultValue':![]},'clickToAction':{'type':Sequelize[_0x413a('0xb')],'defaultValue':![]},'actionType':{'type':Sequelize[_0x413a('0xc')]('voice')}};