From eabff7cd396d1f37ceb929e666f082ce57f07919 Mon Sep 17 00:00:00 2001 From: Wes Bos Date: Fri, 2 Feb 2018 15:23:20 -0500 Subject: updateS --- backend/src/schema.graphql | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) (limited to 'backend/src/schema.graphql') diff --git a/backend/src/schema.graphql b/backend/src/schema.graphql index 788d490..993236e 100644 --- a/backend/src/schema.graphql +++ b/backend/src/schema.graphql @@ -1,10 +1,25 @@ -# import Post, Item, ItemCreateInput from './generated/prisma.graphql' +# import ItemWhereInput, ItemOrderByInput, allItems, Post, Item, ItemCreateInput, ItemOrderByInput, ItemWhereInput from './generated/prisma.graphql' type Query { feed: [Post!]! drafts: [Post!]! post(id: ID!): Post! me: User + itemsConnection( + where: ItemWhereInput + orderBy: ItemOrderByInput + skip: Int + after: String + before: String + first: Int + last: Int + ): ItemConnection! + items( + where: ItemWhereInput + orderBy: ItemOrderByInput + skip: Int + first: Int + ): [Item]! } # import Mutation from './generated/prisma.graphql' @@ -16,8 +31,9 @@ type Mutation { publish(id: ID!): Post! deletePost(id: ID!): Post! updatePost(id: ID!, title: String, text: String): Post! - createItem(data: ItemCreateInput): Item! + createItem(title: String, description: String, price: Int): Item! deleteItem(id: ID!): Item! + updateItem(id: ID!, title: String, description: String, price: Int): Item! } type AuthPayload { -- cgit v1.3