summaryrefslogtreecommitdiffstats
path: root/server/models/client.js
diff options
context:
space:
mode:
Diffstat (limited to 'server/models/client.js')
-rw-r--r--server/models/client.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/server/models/client.js b/server/models/client.js
index ad3bc28..5789788 100644
--- a/server/models/client.js
+++ b/server/models/client.js
@@ -8,15 +8,16 @@ module.exports = (sequelize, DataTypes) => {
type: DataTypes.INTEGER
},
name: DataTypes.STRING,
+ description: DataTypes.STRING(2048),
ip: DataTypes.STRING,
mac: DataTypes.STRING,
uuid: DataTypes.STRING
}, {
timestamps: false
})
- var GroupXClient = sequelize.define('group_x_client', {}, { timestamps: false, freezeTableName: true })
client.associate = function (models) {
- client.belongsToMany(models.group, { as: 'groups', through: GroupXClient, foreignKey: 'clientId', otherKey: 'groupId'})
+ var GroupXClient = sequelize.define('group_x_client', {}, { timestamps: false, freezeTableName: true })
+ client.belongsToMany(models.group, { as: 'groups', through: GroupXClient, foreignKey: 'clientId', otherKey: 'groupId' })
}
return client
}