feat: GraphQL schema

This commit is contained in:
NGPixel
2017-08-06 21:05:10 -04:00
parent 62067caa62
commit 437b88bf58
8 changed files with 201 additions and 60 deletions

View File

@@ -5,6 +5,7 @@
*/
module.exports = db => {
db.User.belongsToMany(db.Group, { through: 'userGroups' })
db.Group.belongsToMany(db.User, { through: 'userGroups' })
db.Group.hasMany(db.Right, { as: 'groupRights' })
db.Document.hasMany(db.Tag, { as: 'documentTags' })
db.File.belongsTo(db.Folder)