summaryrefslogtreecommitdiffstats
path: root/finished-application/backend/src/schema.graphql
diff options
context:
space:
mode:
authorRandy Ridge <randyridge@gmail.com>2018-09-14 20:01:25 -0400
committerGitHub <noreply@github.com>2018-09-14 20:01:25 -0400
commit908180c77cd38011eeedcae949613da2a3391e5e (patch)
treeb59bf1aae819a04d453cde72f6e601f5561a740f /finished-application/backend/src/schema.graphql
parent1f6667d233a4a2e9df977204d83a8f749c050c75 (diff)
parentb3bebda57ba187b7fa10398054b54c05d3fd3555 (diff)
Merge branch 'master' into randyridge/our
Diffstat (limited to 'finished-application/backend/src/schema.graphql')
-rw-r--r--finished-application/backend/src/schema.graphql40
1 files changed, 20 insertions, 20 deletions
diff --git a/finished-application/backend/src/schema.graphql b/finished-application/backend/src/schema.graphql
index 07533eb..8a8eeeb 100644
--- a/finished-application/backend/src/schema.graphql
+++ b/finished-application/backend/src/schema.graphql
@@ -1,39 +1,39 @@
-# The Below line looks like a comment, but it's not!
# import * from './generated/prisma.graphql'
-type Query {
- me: User
- order(id: ID!): Order!
- orders(where: OrderWhereInput, orderBy: OrderOrderByInput, skip: Int, after: String, before: String, first: Int, last: Int): [Order]!
- items(where: ItemWhereInput, orderBy: ItemOrderByInput, skip: Int, after: String, before: String, first: Int, last: Int): [Item]!
- itemsConnection(where: ItemWhereInput, orderBy: ItemOrderByInput, first: Int, last: Int, skip: Int): ItemConnection!
+type SuccessMessage {
+ message: String
}
type Mutation {
+ createItem(title: String, description: String, price: Int, image: String, largeImage: String): Item!
+ updateItem(id: ID!, title: String, description: String, price: Int): Item!
+ deleteItem(id: ID!): Item
signup(email: String!, password: String!, name: String!): User!
signin(email: String!, password: String!): User!
- requestReset(email: String!): User
+ signout: SuccessMessage
+ requestReset(email: String!): SuccessMessage
resetPassword(resetToken: String!, password: String!, confirmPassword: String!): User!
- createItem(title: String, description: String, price: Int, image: String, largeImage: String): Item!
- deleteItem(id: ID!): Item!
- updateItem(id: ID!, title: String, description: String, price: Int): Item!
+ updatePermissions(permissions: [Permission], userId: ID!): User
addToCart(id: ID!): CartItem
removeFromCart(id: ID!): CartItem
createOrder(token: String!): Order!
- updateUser(name: String): User
- signout: SuccessMessage
- updatePermissions(permissions: [Permission], userId: ID!): User
}
-type SuccessMessage {
- message: String
+type Query {
+ items(where: ItemWhereInput, orderBy: ItemOrderByInput, skip: Int, first: Int): [Item]!
+ item(where: ItemWhereUniqueInput!): Item
+ itemsConnection(where: ItemWhereInput): ItemConnection!
+ me: User
+ users: [User]!
+ order(id: ID!): Order
+ orders(orderBy: OrderOrderByInput): [Order]!
}
-type User {
+type User{
id: ID!
- email: String!
name: String!
- orders: [Order!]!
+ email: String!
+ permissions: [Permission!]!
cart: [CartItem!]!
- permissions: [Permission]!
+ orders: [OrderItem]
}