Built motion from commit 0dbf6b8.|0.0.131
[motion.git] / server / models / chat_website.js
index d840865..6d06923 100644 (file)
@@ -131,6 +131,48 @@ module.exports = function(sequelize, DataTypes) {
                message_title: {
                        type: DataTypes.STRING,
                        defaultValue: 'Message'
+               },
+               logo: {
+                       type: DataTypes.STRING
+               },
+               defaultLogo: {
+                       type: DataTypes.BOOLEAN,
+                       defaultValue: true
+               },
+               whiteLabel: {
+                       type: DataTypes.STRING,
+                       defaultValue: 'Powered by xCALLY'
+               },
+               defaultWhiteLabel: {
+                       type: DataTypes.BOOLEAN,
+                       defaultValue: true
+               },
+               acceptUrl: {
+                       type: DataTypes.STRING
+               },
+               rejectUrl: {
+                       type: DataTypes.STRING
+               },
+               closeUrl: {
+                       type: DataTypes.STRING
+               },
+               closeMethod: {
+                       type: DataTypes.ENUM('GET', 'POST')
+               },
+               acceptMethod: {
+                       type: DataTypes.ENUM('GET', 'POST')
+               },
+               rejectMethod: {
+                       type: DataTypes.ENUM('GET', 'POST')
+               },
+               actions: {
+                       type: DataTypes.STRING,
+                       get: function() {
+                               return this.getDataValue('actions') ? JSON.parse(this.getDataValue('actions')) : [];
+                       },
+                       set: function(val) {
+                               return this.setDataValue('actions', JSON.stringify(val));
+                       }
                }
        }, {
                tableName: 'chat_websites',