d3fa36f9dbcafe0a62c58bdabcfa6eb0173059fe
[motion2.git] / server / api / smsAccount / smsAccount.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 _0x7b90=['generate','twilio','connectel','plivo','bandwidth','csc','infobip','intelepeer','ENUM','BOOLEAN','INTEGER','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','mandatoryDispositionPauseId','setDataValue','mandatoryDisposition','sequelize','exports','name','STRING'];(function(_0xed30d2,_0x14ed5e){var _0x3c188d=function(_0x3811da){while(--_0x3811da){_0xed30d2['push'](_0xed30d2['shift']());}};_0x3c188d(++_0x14ed5e);}(_0x7b90,0x152));var _0x07b9=function(_0x2f5ac5,_0x1ee939){_0x2f5ac5=_0x2f5ac5-0x0;var _0x37c9a8=_0x7b90[_0x2f5ac5];return _0x37c9a8;};'use strict';var Sequelize=require(_0x07b9('0x0'));var rs=require('randomstring');module[_0x07b9('0x1')]={'name':{'type':Sequelize['STRING'],'unique':_0x07b9('0x2'),'allowNull':![]},'key':{'type':Sequelize[_0x07b9('0x3')],'allowNull':![]},'remote':{'type':Sequelize['STRING'],'allowNull':![]},'token':{'type':Sequelize[_0x07b9('0x3')],'defaultValue':function(){return rs[_0x07b9('0x4')]();}},'phone':{'type':Sequelize[_0x07b9('0x3')]},'type':{'type':Sequelize['ENUM'](_0x07b9('0x5'),'skebby',_0x07b9('0x6'),'clicksend',_0x07b9('0x7'),'clickatell',_0x07b9('0x8'),_0x07b9('0x9'),_0x07b9('0xa'),_0x07b9('0xb'))},'accountSid':{'type':Sequelize[_0x07b9('0x3')]},'authId':{'type':Sequelize[_0x07b9('0x3')]},'authToken':{'type':Sequelize[_0x07b9('0x3')]},'smsMethod':{'type':Sequelize[_0x07b9('0xc')]('SI','TI','GP')},'username':{'type':Sequelize['STRING']},'password':{'type':Sequelize[_0x07b9('0x3')]},'apiKey':{'type':Sequelize['STRING']},'applicationId':{'type':Sequelize[_0x07b9('0x3')]},'accountId':{'type':Sequelize['STRING']},'senderString':{'type':Sequelize[_0x07b9('0x3')]},'deliveryReport':{'type':Sequelize[_0x07b9('0xd')],'defaultValue':![]},'description':{'type':Sequelize[_0x07b9('0x3')]},'notificationTemplate':{'type':Sequelize['TEXT'],'defaultValue':function(){return'Account:\x20{{account.name}}<br/>{{#queue}}Queue:\x20{{queue.name}}<br/>{{/queue}}From\x20:\x20{{from}}';}},'notificationSound':{'type':Sequelize[_0x07b9('0xd')],'defaultValue':!![]},'notificationShake':{'type':Sequelize[_0x07b9('0xd')],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0x07b9('0xe')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'queueTransfer':{'type':Sequelize[_0x07b9('0xd')],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0x07b9('0xe')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize[_0x07b9('0xd')],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize['INTEGER'],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'baseUrl':{'type':Sequelize[_0x07b9('0x3')]},'mandatoryDispositionPauseId':{'type':Sequelize[_0x07b9('0xe')],'comment':'Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled'},'mandatoryDisposition':{'type':Sequelize[_0x07b9('0xd')],'defaultValue':![],'comment':_0x07b9('0xf'),'set':function(_0x17376a){if(!_0x17376a)this['setDataValue'](_0x07b9('0x10'),null);this[_0x07b9('0x11')](_0x07b9('0x12'),_0x17376a);}}};