aec246d0298f6cc5a4e060a42dd15c71a229879d
[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 _0x6c4f=['name','STRING','long','type','select','parse','values','isArray','stringify','sequelize','lodash','exports','VIRTUAL','getDataValue','alias','setDataValue'];(function(_0x916a95,_0x3655d2){var _0x5b94b0=function(_0x49055e){while(--_0x49055e){_0x916a95['push'](_0x916a95['shift']());}};_0x5b94b0(++_0x3655d2);}(_0x6c4f,0x69));var _0xf6c4=function(_0x480948,_0x26934e){_0x480948=_0x480948-0x0;var _0x27e1ec=_0x6c4f[_0x480948];return _0x27e1ec;};'use strict';var Sequelize=require(_0xf6c4('0x0'));var _=require(_0xf6c4('0x1'));module[_0xf6c4('0x2')]={'name':{'type':Sequelize[_0xf6c4('0x3')],'get':function(_0x38dfa1){return this[_0xf6c4('0x4')](_0xf6c4('0x5'));}},'alias':{'type':Sequelize['STRING'],'allowNull':![],'set':function(_0x149d26){this[_0xf6c4('0x6')](_0xf6c4('0x5'),_0x149d26?_0x149d26:this['getDataValue'](_0xf6c4('0x7')));}},'type':{'type':Sequelize[_0xf6c4('0x8')],'allowNull':![]},'values':{'type':Sequelize['TEXT'](_0xf6c4('0x9')),'get':function(){if(this['getDataValue'](_0xf6c4('0xa'))===_0xf6c4('0xb')){return JSON[_0xf6c4('0xc')](this[_0xf6c4('0x4')](_0xf6c4('0xd')));}else{return this[_0xf6c4('0x4')]('values');}},'set':function(_0x8716fd){if(Array[_0xf6c4('0xe')](_0x8716fd)){this['setDataValue'](_0xf6c4('0xd'),JSON[_0xf6c4('0xf')](_0x8716fd));}else{this[_0xf6c4('0x6')]('values',_0x8716fd);}}},'required':{'type':Sequelize['BOOLEAN'],'defaultValue':![]}};