5 var crypto = require('crypto');
7 module.exports = function(sequelize, DataTypes) {
9 var ChatWebsite = sequelize.define('ChatWebsite', {
10 name: DataTypes.STRING,
12 type: DataTypes.STRING,
15 description: DataTypes.STRING,
17 type: DataTypes.STRING,
18 defaultValue: '#000080'
21 type: DataTypes.STRING,
22 defaultValue: '#000080'
25 type: DataTypes.STRING,
26 defaultValue: '#000080'
28 remote: DataTypes.STRING,
30 type: DataTypes.BOOLEAN,
34 type: DataTypes.ENUM('rounded', 'squared'),
35 defaultValue: 'rounded'
38 type: DataTypes.STRING,
39 defaultValue: 'We are here!'
42 type: DataTypes.STRING,
43 defaultValue: '<strong>Questions?<\/strong><br \/>Insert your name and email address to start a live-chat with our support team.'
45 username_placeholder: {
46 type: DataTypes.STRING,
47 defaultValue: 'Your name'
50 type: DataTypes.STRING,
51 defaultValue: 'Your e-mail address'
54 type: DataTypes.STRING,
58 type: DataTypes.STRING,
59 defaultValue: 'Contact us'
62 type: DataTypes.STRING,
63 defaultValue: '<strong>We\'re not online.<\/strong><br \/>It doesn\'t mean we\'re not there to help - leave your message below and we\'ll be in touch as soon as possible.'
65 enquiry_message_placeholder: {
66 type: DataTypes.STRING,
67 defaultValue: 'Your message...'
70 type: DataTypes.STRING,
71 defaultValue: 'Leave message'
73 download_transcript: {
74 type: DataTypes.BOOLEAN,
78 tableName: 'chat_websites',
79 associate: function(models) {
81 ChatWebsite.hasMany(models.ChatRoom);
82 ChatWebsite.hasMany(models.ChatApplication);