Browse Source

fix(docs): Update example mutation on landing page

Michael Bromley 5 years ago
parent
commit
6fb13e4fa1
1 changed files with 16 additions and 10 deletions
  1. 16 10
      docs/layouts/index.en.html

+ 16 - 10
docs/layouts/index.en.html

@@ -41,17 +41,23 @@
             <div class="graphql-playground-tab" data-name="Add To Order">
                 mutation {
                   addItemToOrder(productVariantId: 5 quantity: 1) {
-                    code
-                    total
-                    state
-                    lines {
-                      productVariant {
-                        id
-                        name
+                    ...on Order {
+                      code
+                      total
+                      state
+                      lines {
+                        productVariant {
+                          id
+                          name
+                        }
+                        unitPrice
+                        quantity
+                        totalPrice
                       }
-                      unitPrice
-                      quantity
-                      totalPrice
+                    }
+                    ...on ErrorResult {
+                      errorCode
+                      message
                     }
                   }
                 }