summaryrefslogtreecommitdiffstats
path: root/server/models/config.js
diff options
context:
space:
mode:
authorUdo Walter2018-09-17 23:34:40 +0200
committerUdo Walter2018-09-17 23:34:40 +0200
commit20932daf5ab54721118726d78340e78d0793cbe3 (patch)
tree5da3385a404554736ce107aa49e49d8596fd7172 /server/models/config.js
parentadd ipxe entry and config database migrations and models (diff)
downloadbas-20932daf5ab54721118726d78340e78d0793cbe3.tar.gz
bas-20932daf5ab54721118726d78340e78d0793cbe3.tar.xz
bas-20932daf5ab54721118726d78340e78d0793cbe3.zip
add ipxe config relation to groups and clients
Diffstat (limited to 'server/models/config.js')
-rw-r--r--server/models/config.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/server/models/config.js b/server/models/config.js
index 11661fd..aee8892 100644
--- a/server/models/config.js
+++ b/server/models/config.js
@@ -22,6 +22,8 @@ module.exports = (sequelize, DataTypes) => {
keyBind: DataTypes.STRING
}, { timestamps: false, freezeTableName: true })
config.belongsToMany(models.entry, { as: 'entries', through: ConfigXEntry, foreignKey: 'configId', otherKey: 'entryId' })
+ config.hasMany(models.group)
+ config.hasMany(models.client)
}
return config
}