feat: GraphQL setting, right, folder resolvers

This commit is contained in:
NGPixel
2017-08-19 22:51:25 -04:00
parent 02183f82ec
commit 574e4b97f4
12 changed files with 232 additions and 1 deletions

View File

@@ -19,9 +19,27 @@ module.exports = {
},
limit: 1
})
},
modifyDocument(obj, args) {
return wiki.db.Document.update({
title: args.title,
subtitle: args.subtitle
}, {
where: { id: args.id }
})
},
moveDocument(obj, args) {
return wiki.db.Document.update({
path: args.path
}, {
where: { id: args.id }
})
}
},
Document: {
comments(doc) {
return doc.getComments()
},
tags(doc) {
return doc.getTags()
}