Add query for all uploads
This commit is contained in:
parent
14be2c2433
commit
0dd7f4a9b4
@ -9,8 +9,9 @@ const getNewVal = (result) => {
|
||||
|
||||
export default {
|
||||
Query: {
|
||||
ignore () {
|
||||
return null
|
||||
async allUploads () {
|
||||
const db = getRethinkDB()
|
||||
return await db.table('uploads')
|
||||
}
|
||||
},
|
||||
Mutation: {
|
||||
|
||||
@ -13,8 +13,7 @@ input Upload {
|
||||
}
|
||||
|
||||
type Query {
|
||||
# GraphQL will not work without defining a query.
|
||||
ignore: Boolean
|
||||
allUploads: [File]
|
||||
}
|
||||
|
||||
type Mutation {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user