diff --git a/.github/workflows/test-env-cleanup.yml b/.github/workflows/test-env-cleanup.yml index a0216056d..b4832c83b 100644 --- a/.github/workflows/test-env-cleanup.yml +++ b/.github/workflows/test-env-cleanup.yml @@ -14,7 +14,7 @@ jobs: - name: Set domain # Set test instance domain based on branch name slug run: | - echo "::set-env name=domain::${{ env.GITHUB_HEAD_REF_SLUG }}.dashboard.saleor.rocks" + echo "::set-env name=domain::${{ env.GITHUB_HEAD_REF_SLUG_URL }}.dashboard.saleor.rocks" - name: Configure AWS credentials uses: aws-actions/configure-aws-credentials@v1 @@ -34,4 +34,4 @@ jobs: with: step: deactivate-env token: ${{ secrets.GITHUB_TOKEN }} - env: ${{ env.GITHUB_HEAD_REF_SLUG }} + env: ${{ env.GITHUB_HEAD_REF_SLUG_URL }} diff --git a/.github/workflows/test-env-deploy.yml b/.github/workflows/test-env-deploy.yml index c9eb2f345..dd2c55321 100644 --- a/.github/workflows/test-env-deploy.yml +++ b/.github/workflows/test-env-deploy.yml @@ -22,7 +22,7 @@ jobs: with: step: start token: ${{ secrets.GITHUB_TOKEN }} - env: ${{ env.GITHUB_HEAD_REF_SLUG }} + env: ${{ env.GITHUB_HEAD_REF_SLUG_URL }} ref: ${{ github.head_ref }} - name: Cache node modules @@ -63,7 +63,7 @@ jobs: - name: Set domain # Set test instance domain based on branch name slug run: | - echo "::set-env name=domain::${{ env.GITHUB_HEAD_REF_SLUG }}.dashboard.saleor.rocks" + echo "::set-env name=domain::${{ env.GITHUB_HEAD_REF_SLUG_URL }}.dashboard.saleor.rocks" - name: Configure AWS credentials uses: aws-actions/configure-aws-credentials@v1 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e06870906..52f3bd4bd 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -81,8 +81,8 @@ jobs: env: API_URI: https://pwa.demo.saleor.rocks/graphql/ with: - start: | - npm start + build: npm run build + start: npx http-server -a localhost -p 9000 build/dashboard wait-on: http://localhost:9000/ wait-on-timeout: 120 - uses: actions/upload-artifact@v1 diff --git a/CHANGELOG.md b/CHANGELOG.md index 6b68a94ec..55da894a7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,16 @@ All notable, unreleased changes to this project will be documented in this file. - Refactor authorization - #624 by @dominik-zeglen - Fix minor bugs - #628 by @dominik-zeglen - Add navigator button - #635 by @dominik-zeglen +- Update to newest schema - #638 by @dominik-zeglen +- Fix missing save button - #636 by @dominik-zeglen +- Fix user avatars - #639 by @dominik-zeglen +- Reset modal state after closing - #644 by @dominik-zeglen +- Fix incorrect messages - #643 by @dominik-zeglen +- Do not use devserver to run cypress tests - #650 by @dominik-zeglen +- Fix updating product that has no variants - #649 by @dominik-zeglen +- Update checkbox design - #651 by @dominik-zeglen +- Add warehouse choice - #646 by @dominik-zeglen +- Fix user management modal actions - #637 by @eaglesemanation ## 2.10.1 diff --git a/assets/images/navigator.svg b/assets/images/navigator.svg new file mode 100644 index 000000000..dbbde3b2f --- /dev/null +++ b/assets/images/navigator.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/locale/defaultMessages.json b/locale/defaultMessages.json index 92fbc001a..f5faf5e7b 100644 --- a/locale/defaultMessages.json +++ b/locale/defaultMessages.json @@ -205,6 +205,62 @@ "context": "vat not included in order price", "string": "does not apply" }, + "productExportFieldCategory": { + "context": "product field", + "string": "Category" + }, + "productExportFieldCollections": { + "context": "product field", + "string": "Collections" + }, + "productExportFieldDescription": { + "context": "product field", + "string": "Description" + }, + "productExportFieldName": { + "context": "product field", + "string": "Name" + }, + "productExportFieldPrice": { + "context": "product field", + "string": "Cost Price" + }, + "productExportFieldProductImages": { + "context": "product field", + "string": "Product Images" + }, + "productExportFieldProductWeight": { + "context": "product field", + "string": "Export Product Weight" + }, + "productExportFieldTaxes": { + "context": "product field", + "string": "Charge Taxes" + }, + "productExportFieldType": { + "context": "product field", + "string": "Type" + }, + "productExportFieldVariantImages": { + "context": "product field", + "string": "Variant Images" + }, + "productExportFieldVariantPrice": { + "context": "product field", + "string": "Variant Price" + }, + "productExportFieldVariantSku": { + "context": "product field", + "string": "Export Variant SKU" + }, + "productExportFieldVariantWeight": { + "context": "product field", + "string": "Export Variant Weight" + }, + "productExportFieldVisibility": { + "context": "product field", + "string": "Visibility" + }, "productStatusLabel": { "context": "product", "string": "Published" @@ -557,9 +613,9 @@ "context": "apps content", "string": "You don’t have any installed apps in your dashboard" }, - "src_dot_apps_dot_components_dot_InstalledApps_dot_2008086393": { + "src_dot_apps_dot_components_dot_InstalledApps_dot_3504763431": { "context": "section header", - "string": "Thirdparty Apps" + "string": "Third-party Apps" }, "src_dot_apps_dot_components_dot_Marketplace_dot_2932910073": { "context": "section header", @@ -1055,6 +1111,9 @@ "context": "dialog title", "string": "Delete products" }, + "src_dot_categories_dot_views_dot_3296953393": { + "string": "Remember this will also unpin all products assigned to this category, making them unavailable in storefront." + }, "src_dot_categories_dot_views_dot_3488150607": { "string": "Remember this will also delete all products assigned to this category." }, @@ -1512,6 +1571,9 @@ "src_dot_components_dot_MultiSelectField_dot_4205644805": { "string": "No results found" }, + "src_dot_components_dot_NavigatorButton_dot_154826674": { + "string": "Navigator" + }, "src_dot_components_dot_Navigator_dot_1116468870": { "context": "navigator placeholder", "string": "Order Number" @@ -3922,34 +3984,22 @@ "context": "product name", "string": "Name" }, + "src_dot_products_dot_components_dot_ProductExportDialog_dot_1004476569": { + "context": "option", + "string": "Export stock for all warehouses" + }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_108342258": { "context": "button", "string": "Load More" }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_1459686496": { - "context": "product field", - "string": "Visibility" - }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_1547327218": { "context": "there are more elements of list that are hidden", "string": "and {number} more" }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_1755013298": { - "context": "product field", - "string": "Category" - }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_1890035856": { "context": "informations about product organization, header", "string": "Product Organization" }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_1952810469": { - "context": "product field", - "string": "Type" - }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_2051669917": { - "context": "product field", - "string": "Cost Price" - }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_2119710854": { "context": "informations about product seo, header", "string": "SEO Information" @@ -3958,10 +4008,6 @@ "context": "export selected products to csv file", "string": "Selected products ({number})" }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_222873645": { - "context": "product field", - "string": "Collections" - }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_2318723509": { "context": "export products to csv file, choice field label", "string": "Export information for:" @@ -3970,6 +4016,10 @@ "context": "export all products to csv file", "string": "All products ({number})" }, + "src_dot_products_dot_components_dot_ProductExportDialog_dot_2474350154": { + "context": "list of warehouses", + "string": "Warehouses A to Z" + }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_2659464408": { "context": "product export to csv file, header", "string": "Information exported" @@ -3982,10 +4032,6 @@ "context": "export products to csv file, button", "string": "export products" }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_2949617129": { - "context": "product field", - "string": "Product Images" - }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_3012202273": { "context": "export products to csv file, dialog header", "string": "Export Information" @@ -3994,14 +4040,6 @@ "context": "product export to csv file, header", "string": "Export Settings" }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_3374163063": { - "context": "product field", - "string": "Description" - }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_3441755345": { - "context": "product field", - "string": "Charge Taxes" - }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_3443345452": { "context": "selectt all options", "string": "Select All" @@ -4010,13 +4048,12 @@ "context": "export products as spreadsheet", "string": "Spreadsheet for Excel, Numbers etc." }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_3544554440": { - "context": "product field", - "string": "Variant Weight" - }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_3599582104": { "string": "Search Atrtibuttes" }, + "src_dot_products_dot_components_dot_ProductExportDialog_dot_3902059658": { + "string": "Export Product Stock Quantity to CSV" + }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_3919525499": { "context": "informations about product stock, header", "string": "Inventory Information" @@ -4025,10 +4062,6 @@ "context": "export products as csv file", "string": "Plain CSV file" }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_4160582036": { - "context": "product field", - "string": "Variant Price" - }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_472026385": { "context": "select product informations to be exported", "string": "Information exported:" @@ -4037,14 +4070,6 @@ "context": "input helper text, search attributes", "string": "Search by attribute name" }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_636461959": { - "context": "product field", - "string": "Name" - }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_693960049": { - "context": "product field", - "string": "SKU" - }, "src_dot_products_dot_components_dot_ProductExportDialog_dot_700651641": { "context": "export filtered products to csv file", "string": "Current search ({number})" @@ -4053,14 +4078,6 @@ "context": "informations about product prices etc, header", "string": "Financial Information" }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_746695941": { - "context": "product field", - "string": "Weight" - }, - "src_dot_products_dot_components_dot_ProductExportDialog_dot_897437458": { - "context": "product field", - "string": "Variant Images" - }, "src_dot_products_dot_components_dot_ProductImageNavigation_dot_3060635772": { "context": "section header", "string": "All Photos" @@ -5731,6 +5748,10 @@ "context": "dialog header", "string": "Delete Webhook" }, + "src_dot_webhooks_dot_components_dot_WebhookEvents_dot_1087314240": { + "context": "event", + "string": "Checkout updated" + }, "src_dot_webhooks_dot_components_dot_WebhookEvents_dot_1368317066": { "context": "event", "string": "Invoice deleted" @@ -5743,6 +5764,10 @@ "context": "event", "string": "Order updated" }, + "src_dot_webhooks_dot_components_dot_WebhookEvents_dot_2240725235": { + "context": "event", + "string": "Checkout created" + }, "src_dot_webhooks_dot_components_dot_WebhookEvents_dot_2454751033": { "context": "event", "string": "All events" diff --git a/schema.graphql b/schema.graphql index b016539da..fb385d55b 100644 --- a/schema.graphql +++ b/schema.graphql @@ -4,40 +4,28 @@ schema { } type AccountAddressCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! address: Address } type AccountAddressDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! address: Address } type AccountAddressUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! address: Address } type AccountDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! user: User } @@ -89,10 +77,7 @@ input AccountInput { } type AccountRegister { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") requiresConfirmation: Boolean accountErrors: [AccountError!]! user: User @@ -105,36 +90,24 @@ input AccountRegisterInput { } type AccountRequestDeletion { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! } type AccountSetDefaultAddress { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! } type AccountUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! user: User } type AccountUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! user: User } @@ -157,20 +130,14 @@ type Address implements Node { } type AddressCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! address: Address } type AddressDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! address: Address @@ -191,10 +158,7 @@ input AddressInput { } type AddressSetDefault { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! } @@ -205,10 +169,7 @@ enum AddressTypeEnum { } type AddressUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! address: Address @@ -243,14 +204,8 @@ type App implements Node & ObjectWithMetadata { tokens: [AppToken] privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") type: AppTypeEnum webhooks: [Webhook] aboutApp: String @@ -265,10 +220,7 @@ type App implements Node & ObjectWithMetadata { } type AppActivate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") appErrors: [AppError!]! app: App } @@ -285,38 +237,26 @@ type AppCountableEdge { } type AppCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") authToken: String appErrors: [AppError!]! app: App } type AppDeactivate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") appErrors: [AppError!]! app: App } type AppDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") appErrors: [AppError!]! app: App } type AppDeleteFailedInstallation { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") appErrors: [AppError!]! appInstallation: AppInstallation } @@ -345,10 +285,7 @@ enum AppErrorCode { } type AppFetchManifest { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") manifest: Manifest appErrors: [AppError!]! } @@ -366,10 +303,7 @@ input AppInput { } type AppInstall { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") appErrors: [AppError!]! appInstallation: AppInstallation } @@ -382,20 +316,17 @@ input AppInstallInput { } type AppInstallation implements Node & Job { - status: JobStatusEnum! - message: String - createdAt: DateTime! - updatedAt: DateTime! appName: String! manifestUrl: String! id: ID! + status: JobStatusEnum! + createdAt: DateTime! + updatedAt: DateTime! + message: String } type AppRetryInstall { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") appErrors: [AppError!]! appInstallation: AppInstallation } @@ -417,20 +348,14 @@ type AppToken implements Node { } type AppTokenCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") authToken: String appErrors: [AppError!]! appToken: AppToken } type AppTokenDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") appErrors: [AppError!]! appToken: AppToken } @@ -441,10 +366,7 @@ input AppTokenInput { } type AppTokenVerify { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") valid: Boolean! appErrors: [AppError!]! } @@ -455,47 +377,25 @@ enum AppTypeEnum { } type AppUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") appErrors: [AppError!]! app: App } type AssignNavigation { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") menu: Menu menuErrors: [MenuError!]! } type Attribute implements Node & ObjectWithMetadata { id: ID! - productTypes( - before: String - after: String - first: Int - last: Int - ): ProductTypeCountableConnection! - productVariantTypes( - before: String - after: String - first: Int - last: Int - ): ProductTypeCountableConnection! + productTypes(before: String, after: String, first: Int, last: Int): ProductTypeCountableConnection! + productVariantTypes(before: String, after: String, first: Int, last: Int): ProductTypeCountableConnection! privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") inputType: AttributeInputTypeEnum name: String slug: String @@ -510,10 +410,7 @@ type Attribute implements Node & ObjectWithMetadata { } type AttributeAssign { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productType: ProductType productErrors: [ProductAttributeError!]! } @@ -524,28 +421,19 @@ input AttributeAssignInput { } type AttributeBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productErrors: [ProductError!]! } type AttributeClearMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! attribute: Attribute } type AttributeClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! attribute: Attribute } @@ -562,10 +450,7 @@ type AttributeCountableEdge { } type AttributeCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") attribute: Attribute productErrors: [ProductError!]! } @@ -585,10 +470,7 @@ input AttributeCreateInput { } type AttributeDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! attribute: Attribute } @@ -618,10 +500,7 @@ enum AttributeInputTypeEnum { } type AttributeReorderValues { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") attribute: Attribute productErrors: [ProductError!]! } @@ -651,10 +530,7 @@ type AttributeTranslatableContent implements Node { } type AttributeTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! attribute: Attribute } @@ -671,19 +547,13 @@ enum AttributeTypeEnum { } type AttributeUnassign { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productType: ProductType productErrors: [ProductError!]! } type AttributeUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") attribute: Attribute productErrors: [ProductError!]! } @@ -703,19 +573,13 @@ input AttributeUpdateInput { } type AttributeUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! attribute: Attribute } type AttributeUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! attribute: Attribute } @@ -724,28 +588,19 @@ type AttributeValue implements Node { id: ID! name: String slug: String - type: AttributeValueType - @deprecated( - reason: "Use the `inputType` field to determine the type of attribute's value. This field will be removed after 2020-07-31." - ) + type: AttributeValueType @deprecated(reason: "Use the `inputType` field to determine the type of attribute's value. This field will be removed after 2020-07-31.") translation(languageCode: LanguageCodeEnum!): AttributeValueTranslation inputType: AttributeInputTypeEnum } type AttributeValueBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productErrors: [ProductError!]! } type AttributeValueCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") attribute: Attribute productErrors: [ProductError!]! attributeValue: AttributeValue @@ -756,10 +611,7 @@ input AttributeValueCreateInput { } type AttributeValueDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") attribute: Attribute productErrors: [ProductError!]! attributeValue: AttributeValue @@ -778,10 +630,7 @@ type AttributeValueTranslatableContent implements Node { } type AttributeValueTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! attributeValue: AttributeValue } @@ -800,10 +649,7 @@ enum AttributeValueType { } type AttributeValueUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") attribute: Attribute productErrors: [ProductError!]! attributeValue: AttributeValue @@ -815,20 +661,14 @@ type AuthorizationKey { } type AuthorizationKeyAdd { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") authorizationKey: AuthorizationKey shop: Shop shopErrors: [ShopError!]! } type AuthorizationKeyDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") authorizationKey: AuthorizationKey shop: Shop shopErrors: [ShopError!]! @@ -877,61 +717,30 @@ type Category implements Node & ObjectWithMetadata { level: Int! privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) - ancestors( - before: String - after: String - first: Int - last: Int - ): CategoryCountableConnection - products( - before: String - after: String - first: Int - last: Int - ): ProductCountableConnection - url: String - @deprecated(reason: "This field will be removed after 2020-07-31.") - children( - before: String - after: String - first: Int - last: Int - ): CategoryCountableConnection + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") + ancestors(before: String, after: String, first: Int, last: Int): CategoryCountableConnection + products(before: String, after: String, first: Int, last: Int): ProductCountableConnection + url: String @deprecated(reason: "This field will be removed after 2020-07-31.") + children(before: String, after: String, first: Int, last: Int): CategoryCountableConnection backgroundImage(size: Int): Image translation(languageCode: LanguageCodeEnum!): CategoryTranslation } type CategoryBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productErrors: [ProductError!]! } type CategoryClearMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! category: Category } type CategoryClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! category: Category } @@ -948,19 +757,13 @@ type CategoryCountableEdge { } type CategoryCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! category: Category } type CategoryDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! category: Category } @@ -1003,10 +806,7 @@ type CategoryTranslatableContent implements Node { } type CategoryTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! category: Category } @@ -1022,28 +822,19 @@ type CategoryTranslation implements Node { } type CategoryUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! category: Category } type CategoryUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! category: Category } type CategoryUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! category: Category } @@ -1065,14 +856,8 @@ type Checkout implements Node & ObjectWithMetadata { id: ID! privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") availableShippingMethods: [ShippingMethod]! availablePaymentGateways: [PaymentGateway!]! email: String! @@ -1085,46 +870,31 @@ type Checkout implements Node & ObjectWithMetadata { } type CheckoutAddPromoCode { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } type CheckoutBillingAddressUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } type CheckoutClearMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkoutErrors: [CheckoutError!]! checkout: Checkout } type CheckoutClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkoutErrors: [CheckoutError!]! checkout: Checkout } type CheckoutComplete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order confirmationNeeded: Boolean! checkoutErrors: [CheckoutError!]! @@ -1142,10 +912,7 @@ type CheckoutCountableEdge { } type CheckoutCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") created: Boolean checkoutErrors: [CheckoutError!]! checkout: Checkout @@ -1159,28 +926,19 @@ input CheckoutCreateInput { } type CheckoutCustomerAttach { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } type CheckoutCustomerDetach { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } type CheckoutEmailUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } @@ -1233,10 +991,7 @@ type CheckoutLineCountableEdge { } type CheckoutLineDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } @@ -1247,74 +1002,50 @@ input CheckoutLineInput { } type CheckoutLinesAdd { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } type CheckoutLinesUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } type CheckoutPaymentCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout payment: Payment paymentErrors: [PaymentError!]! } type CheckoutRemovePromoCode { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } type CheckoutShippingAddressUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } type CheckoutShippingMethodUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkout: Checkout checkoutErrors: [CheckoutError!]! } type CheckoutUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkoutErrors: [CheckoutError!]! checkout: Checkout } type CheckoutUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") checkoutErrors: [CheckoutError!]! checkout: Checkout } @@ -1336,65 +1067,39 @@ type Collection implements Node & ObjectWithMetadata { slug: String! privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) - products( - before: String - after: String - first: Int - last: Int - ): ProductCountableConnection + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") + products(before: String, after: String, first: Int, last: Int): ProductCountableConnection backgroundImage(size: Int): Image translation(languageCode: LanguageCodeEnum!): CollectionTranslation } type CollectionAddProducts { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") collection: Collection productErrors: [ProductError!]! } type CollectionBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productErrors: [ProductError!]! } type CollectionBulkPublish { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productErrors: [ProductError!]! } type CollectionClearMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! collection: Collection } type CollectionClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! collection: Collection } @@ -1411,10 +1116,7 @@ type CollectionCountableEdge { } type CollectionCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! collection: Collection } @@ -1433,10 +1135,7 @@ input CollectionCreateInput { } type CollectionDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! collection: Collection } @@ -1465,19 +1164,13 @@ enum CollectionPublished { } type CollectionRemoveProducts { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") collection: Collection productErrors: [ProductError!]! } type CollectionReorderProducts { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") collection: Collection productErrors: [ProductError!]! } @@ -1505,10 +1198,7 @@ type CollectionTranslatableContent implements Node { } type CollectionTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! collection: Collection } @@ -1524,28 +1214,19 @@ type CollectionTranslation implements Node { } type CollectionUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! collection: Collection } type CollectionUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! collection: Collection } type CollectionUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! collection: Collection } @@ -1571,19 +1252,13 @@ enum ConfigurationTypeFieldEnum { } type ConfirmAccount { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! } type ConfirmEmailChange { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! } @@ -1848,10 +1523,7 @@ type CountryDisplay { } type CreateToken { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") token: String refreshToken: String csrfToken: String @@ -1861,35 +1533,26 @@ type CreateToken { type CreditCard { brand: String! - firstDigits: String! + firstDigits: String lastDigits: String! - expMonth: Int! - expYear: Int! + expMonth: Int + expYear: Int } type CustomerBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! accountErrors: [AccountError!]! } type CustomerCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! user: User } type CustomerDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! user: User } @@ -1940,10 +1603,7 @@ input CustomerInput { } type CustomerUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! user: User } @@ -1963,29 +1623,20 @@ input DateTimeRangeInput { } type DeactivateAllUserTokens { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! } scalar Decimal type DeleteMetadata { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") metadataErrors: [MetadataError!]! item: ObjectWithMetadata } type DeletePrivateMetadata { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") metadataErrors: [MetadataError!]! item: ObjectWithMetadata } @@ -2001,14 +1652,8 @@ type DigitalContent implements Node & ObjectWithMetadata { id: ID! privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") } type DigitalContentCountableConnection { @@ -2023,20 +1668,14 @@ type DigitalContentCountableEdge { } type DigitalContentCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") variant: ProductVariant content: DigitalContent productErrors: [ProductError!]! } type DigitalContentDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") variant: ProductVariant productErrors: [ProductError!]! } @@ -2049,10 +1688,7 @@ input DigitalContentInput { } type DigitalContentUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") variant: ProductVariant content: DigitalContent productErrors: [ProductError!]! @@ -2076,10 +1712,7 @@ type DigitalContentUrl implements Node { } type DigitalContentUrlCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! digitalContentUrl: DigitalContentUrl } @@ -2121,28 +1754,19 @@ type Domain { } type DraftOrderBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! orderErrors: [OrderError!]! } type DraftOrderComplete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order orderErrors: [OrderError!]! } type DraftOrderCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") orderErrors: [OrderError!]! order: Order } @@ -2160,10 +1784,7 @@ input DraftOrderCreateInput { } type DraftOrderDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") orderErrors: [OrderError!]! order: Order } @@ -2180,49 +1801,34 @@ input DraftOrderInput { } type DraftOrderLineDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order orderLine: OrderLine orderErrors: [OrderError!]! } type DraftOrderLineUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order orderErrors: [OrderError!]! orderLine: OrderLine } type DraftOrderLinesBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! orderErrors: [OrderError!]! } type DraftOrderLinesCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order orderLines: [OrderLine!] orderErrors: [OrderError!]! } type DraftOrderUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") orderErrors: [OrderError!]! order: Order } @@ -2269,6 +1875,7 @@ type ExportFile implements Node & Job { status: JobStatusEnum! createdAt: DateTime! updatedAt: DateTime! + message: String url: String events: [ExportEvent!] } @@ -2342,24 +1949,15 @@ type Fulfillment implements Node & ObjectWithMetadata { created: DateTime! privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") lines: [FulfillmentLine] statusDisplay: String warehouse: Warehouse } type FulfillmentCancel { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") fulfillment: Fulfillment order: Order orderErrors: [OrderError!]! @@ -2370,18 +1968,12 @@ input FulfillmentCancelInput { } type FulfillmentClearMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") fulfillment: Fulfillment } type FulfillmentClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") fulfillment: Fulfillment } @@ -2397,26 +1989,17 @@ enum FulfillmentStatus { } type FulfillmentUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") fulfillment: Fulfillment } type FulfillmentUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") fulfillment: Fulfillment } type FulfillmentUpdateTracking { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") fulfillment: Fulfillment order: Order orderErrors: [OrderError!]! @@ -2453,10 +2036,7 @@ type GiftCard implements Node { } type GiftCardActivate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") giftCard: GiftCard giftCardErrors: [GiftCardError!]! } @@ -2473,10 +2053,7 @@ type GiftCardCountableEdge { } type GiftCardCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") giftCardErrors: [GiftCardError!]! giftCard: GiftCard } @@ -2490,10 +2067,7 @@ input GiftCardCreateInput { } type GiftCardDeactivate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") giftCard: GiftCard giftCardErrors: [GiftCardError!]! } @@ -2514,10 +2088,7 @@ enum GiftCardErrorCode { } type GiftCardUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") giftCardErrors: [GiftCardError!]! giftCard: GiftCard } @@ -2549,10 +2120,7 @@ type GroupCountableEdge { } type HomepageCollectionUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shop: Shop shopErrors: [ShopError!]! } @@ -2574,24 +2142,16 @@ type Invoice implements ObjectWithMetadata & Job & Node { number: String externalUrl: String privateMetadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") createdAt: DateTime! updatedAt: DateTime! + message: String url: String } type InvoiceCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") invoiceErrors: [InvoiceError!]! invoice: Invoice } @@ -2602,10 +2162,7 @@ input InvoiceCreateInput { } type InvoiceDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") invoiceErrors: [InvoiceError!]! invoice: Invoice } @@ -2627,38 +2184,26 @@ enum InvoiceErrorCode { } type InvoiceRequest { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order invoiceErrors: [InvoiceError!]! invoice: Invoice } type InvoiceRequestDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") invoiceErrors: [InvoiceError!]! invoice: Invoice } type InvoiceSendEmail { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") invoiceErrors: [InvoiceError!]! invoice: Invoice } type InvoiceUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") invoiceErrors: [InvoiceError!]! invoice: Invoice } @@ -2669,6 +2214,7 @@ interface Job { status: JobStatusEnum! createdAt: DateTime! updatedAt: DateTime! + message: String } enum JobStatusEnum { @@ -2759,10 +2305,7 @@ type Menu implements Node { } type MenuBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! menuErrors: [MenuError!]! } @@ -2779,10 +2322,7 @@ type MenuCountableEdge { } type MenuCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") menuErrors: [MenuError!]! menu: Menu } @@ -2793,10 +2333,7 @@ input MenuCreateInput { } type MenuDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") menuErrors: [MenuError!]! menu: Menu } @@ -2842,10 +2379,7 @@ type MenuItem implements Node { } type MenuItemBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! menuErrors: [MenuError!]! } @@ -2862,10 +2396,7 @@ type MenuItemCountableEdge { } type MenuItemCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") menuErrors: [MenuError!]! menuItem: MenuItem } @@ -2881,10 +2412,7 @@ input MenuItemCreateInput { } type MenuItemDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") menuErrors: [MenuError!]! menuItem: MenuItem } @@ -2902,10 +2430,7 @@ input MenuItemInput { } type MenuItemMove { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") menu: Menu menuErrors: [MenuError!]! } @@ -2929,10 +2454,7 @@ type MenuItemTranslatableContent implements Node { } type MenuItemTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! menuItem: MenuItem } @@ -2944,10 +2466,7 @@ type MenuItemTranslation implements Node { } type MenuItemUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") menuErrors: [MenuError!]! menuItem: MenuItem } @@ -2967,10 +2486,7 @@ input MenuSortingInput { } type MenuUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") menuErrors: [MenuError!]! menu: Menu } @@ -3028,10 +2544,7 @@ type MetadataItem { type Money { currency: String! amount: Float! - localized: String! - @deprecated( - reason: "Price formatting according to the current locale should be handled by the frontend client. This field will be removed after 2020-07-31." - ) + localized: String! @deprecated(reason: "Price formatting according to the current locale should be handled by the frontend client. This field will be removed after 2020-07-31.") } type MoneyRange { @@ -3051,418 +2564,152 @@ type Mutation { createWarehouse(input: WarehouseCreateInput!): WarehouseCreate updateWarehouse(id: ID!, input: WarehouseUpdateInput!): WarehouseUpdate deleteWarehouse(id: ID!): WarehouseDelete - assignWarehouseShippingZone( - id: ID! - shippingZoneIds: [ID!]! - ): WarehouseShippingZoneAssign - unassignWarehouseShippingZone( - id: ID! - shippingZoneIds: [ID!]! - ): WarehouseShippingZoneUnassign - authorizationKeyAdd( - input: AuthorizationKeyInput! - keyType: AuthorizationKeyType! - ): AuthorizationKeyAdd + assignWarehouseShippingZone(id: ID!, shippingZoneIds: [ID!]!): WarehouseShippingZoneAssign + unassignWarehouseShippingZone(id: ID!, shippingZoneIds: [ID!]!): WarehouseShippingZoneUnassign + authorizationKeyAdd(input: AuthorizationKeyInput!, keyType: AuthorizationKeyType!): AuthorizationKeyAdd authorizationKeyDelete(keyType: AuthorizationKeyType!): AuthorizationKeyDelete - staffNotificationRecipientCreate( - input: StaffNotificationRecipientInput! - ): StaffNotificationRecipientCreate - staffNotificationRecipientUpdate( - id: ID! - input: StaffNotificationRecipientInput! - ): StaffNotificationRecipientUpdate + staffNotificationRecipientCreate(input: StaffNotificationRecipientInput!): StaffNotificationRecipientCreate + staffNotificationRecipientUpdate(id: ID!, input: StaffNotificationRecipientInput!): StaffNotificationRecipientUpdate staffNotificationRecipientDelete(id: ID!): StaffNotificationRecipientDelete homepageCollectionUpdate(collection: ID): HomepageCollectionUpdate shopDomainUpdate(input: SiteDomainInput): ShopDomainUpdate shopSettingsUpdate(input: ShopSettingsInput!): ShopSettingsUpdate shopFetchTaxRates: ShopFetchTaxRates - shopSettingsTranslate( - input: ShopSettingsTranslationInput! - languageCode: LanguageCodeEnum! - ): ShopSettingsTranslate + shopSettingsTranslate(input: ShopSettingsTranslationInput!, languageCode: LanguageCodeEnum!): ShopSettingsTranslate shopAddressUpdate(input: AddressInput): ShopAddressUpdate shippingPriceCreate(input: ShippingPriceInput!): ShippingPriceCreate shippingPriceDelete(id: ID!): ShippingPriceDelete shippingPriceBulkDelete(ids: [ID]!): ShippingPriceBulkDelete shippingPriceUpdate(id: ID!, input: ShippingPriceInput!): ShippingPriceUpdate - shippingPriceTranslate( - id: ID! - input: NameTranslationInput! - languageCode: LanguageCodeEnum! - ): ShippingPriceTranslate + shippingPriceTranslate(id: ID!, input: NameTranslationInput!, languageCode: LanguageCodeEnum!): ShippingPriceTranslate shippingZoneCreate(input: ShippingZoneCreateInput!): ShippingZoneCreate shippingZoneDelete(id: ID!): ShippingZoneDelete shippingZoneBulkDelete(ids: [ID]!): ShippingZoneBulkDelete - shippingZoneUpdate( - id: ID! - input: ShippingZoneUpdateInput! - ): ShippingZoneUpdate + shippingZoneUpdate(id: ID!, input: ShippingZoneUpdateInput!): ShippingZoneUpdate attributeCreate(input: AttributeCreateInput!): AttributeCreate attributeDelete(id: ID!): AttributeDelete attributeBulkDelete(ids: [ID]!): AttributeBulkDelete - attributeAssign( - operations: [AttributeAssignInput]! - productTypeId: ID! - ): AttributeAssign + attributeAssign(operations: [AttributeAssignInput]!, productTypeId: ID!): AttributeAssign attributeUnassign(attributeIds: [ID]!, productTypeId: ID!): AttributeUnassign attributeUpdate(id: ID!, input: AttributeUpdateInput!): AttributeUpdate - attributeTranslate( - id: ID! - input: NameTranslationInput! - languageCode: LanguageCodeEnum! - ): AttributeTranslate - attributeUpdateMetadata(id: ID!, input: MetaInput!): AttributeUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - attributeClearMetadata(id: ID!, input: MetaPath!): AttributeClearMeta - @deprecated( - reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - attributeUpdatePrivateMetadata( - id: ID! - input: MetaInput! - ): AttributeUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - attributeClearPrivateMetadata( - id: ID! - input: MetaPath! - ): AttributeClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - attributeValueCreate( - attribute: ID! - input: AttributeValueCreateInput! - ): AttributeValueCreate + attributeTranslate(id: ID!, input: NameTranslationInput!, languageCode: LanguageCodeEnum!): AttributeTranslate + attributeUpdateMetadata(id: ID!, input: MetaInput!): AttributeUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31.") + attributeClearMetadata(id: ID!, input: MetaPath!): AttributeClearMeta @deprecated(reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31.") + attributeUpdatePrivateMetadata(id: ID!, input: MetaInput!): AttributeUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + attributeClearPrivateMetadata(id: ID!, input: MetaPath!): AttributeClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + attributeValueCreate(attribute: ID!, input: AttributeValueCreateInput!): AttributeValueCreate attributeValueDelete(id: ID!): AttributeValueDelete attributeValueBulkDelete(ids: [ID]!): AttributeValueBulkDelete - attributeValueUpdate( - id: ID! - input: AttributeValueCreateInput! - ): AttributeValueUpdate - attributeValueTranslate( - id: ID! - input: NameTranslationInput! - languageCode: LanguageCodeEnum! - ): AttributeValueTranslate - attributeReorderValues( - attributeId: ID! - moves: [ReorderInput]! - ): AttributeReorderValues + attributeValueUpdate(id: ID!, input: AttributeValueCreateInput!): AttributeValueUpdate + attributeValueTranslate(id: ID!, input: NameTranslationInput!, languageCode: LanguageCodeEnum!): AttributeValueTranslate + attributeReorderValues(attributeId: ID!, moves: [ReorderInput]!): AttributeReorderValues categoryCreate(input: CategoryInput!, parent: ID): CategoryCreate categoryDelete(id: ID!): CategoryDelete categoryBulkDelete(ids: [ID]!): CategoryBulkDelete categoryUpdate(id: ID!, input: CategoryInput!): CategoryUpdate - categoryTranslate( - id: ID! - input: TranslationInput! - languageCode: LanguageCodeEnum! - ): CategoryTranslate - categoryUpdateMetadata(id: ID!, input: MetaInput!): CategoryUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - categoryClearMetadata(id: ID!, input: MetaPath!): CategoryClearMeta - @deprecated( - reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - categoryUpdatePrivateMetadata( - id: ID! - input: MetaInput! - ): CategoryUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - categoryClearPrivateMetadata( - id: ID! - input: MetaPath! - ): CategoryClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - collectionAddProducts( - collectionId: ID! - products: [ID]! - ): CollectionAddProducts + categoryTranslate(id: ID!, input: TranslationInput!, languageCode: LanguageCodeEnum!): CategoryTranslate + categoryUpdateMetadata(id: ID!, input: MetaInput!): CategoryUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31.") + categoryClearMetadata(id: ID!, input: MetaPath!): CategoryClearMeta @deprecated(reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31.") + categoryUpdatePrivateMetadata(id: ID!, input: MetaInput!): CategoryUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + categoryClearPrivateMetadata(id: ID!, input: MetaPath!): CategoryClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + collectionAddProducts(collectionId: ID!, products: [ID]!): CollectionAddProducts collectionCreate(input: CollectionCreateInput!): CollectionCreate collectionDelete(id: ID!): CollectionDelete - collectionReorderProducts( - collectionId: ID! - moves: [MoveProductInput]! - ): CollectionReorderProducts + collectionReorderProducts(collectionId: ID!, moves: [MoveProductInput]!): CollectionReorderProducts collectionBulkDelete(ids: [ID]!): CollectionBulkDelete - collectionBulkPublish( - ids: [ID]! - isPublished: Boolean! - ): CollectionBulkPublish - collectionRemoveProducts( - collectionId: ID! - products: [ID]! - ): CollectionRemoveProducts + collectionBulkPublish(ids: [ID]!, isPublished: Boolean!): CollectionBulkPublish + collectionRemoveProducts(collectionId: ID!, products: [ID]!): CollectionRemoveProducts collectionUpdate(id: ID!, input: CollectionInput!): CollectionUpdate - collectionTranslate( - id: ID! - input: TranslationInput! - languageCode: LanguageCodeEnum! - ): CollectionTranslate - collectionUpdateMetadata(id: ID!, input: MetaInput!): CollectionUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - collectionClearMetadata(id: ID!, input: MetaPath!): CollectionClearMeta - @deprecated( - reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - collectionUpdatePrivateMetadata( - id: ID! - input: MetaInput! - ): CollectionUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - collectionClearPrivateMetadata( - id: ID! - input: MetaPath! - ): CollectionClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) + collectionTranslate(id: ID!, input: TranslationInput!, languageCode: LanguageCodeEnum!): CollectionTranslate + collectionUpdateMetadata(id: ID!, input: MetaInput!): CollectionUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31.") + collectionClearMetadata(id: ID!, input: MetaPath!): CollectionClearMeta @deprecated(reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31.") + collectionUpdatePrivateMetadata(id: ID!, input: MetaInput!): CollectionUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + collectionClearPrivateMetadata(id: ID!, input: MetaPath!): CollectionClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") productCreate(input: ProductCreateInput!): ProductCreate productDelete(id: ID!): ProductDelete productBulkDelete(ids: [ID]!): ProductBulkDelete productBulkPublish(ids: [ID]!, isPublished: Boolean!): ProductBulkPublish productUpdate(id: ID!, input: ProductInput!): ProductUpdate - productTranslate( - id: ID! - input: TranslationInput! - languageCode: LanguageCodeEnum! - ): ProductTranslate - productUpdateMetadata(id: ID!, input: MetaInput!): ProductUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - productClearMetadata(id: ID!, input: MetaPath!): ProductClearMeta - @deprecated( - reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - productUpdatePrivateMetadata( - id: ID! - input: MetaInput! - ): ProductUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - productClearPrivateMetadata( - id: ID! - input: MetaPath! - ): ProductClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) + productTranslate(id: ID!, input: TranslationInput!, languageCode: LanguageCodeEnum!): ProductTranslate + productUpdateMetadata(id: ID!, input: MetaInput!): ProductUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31.") + productClearMetadata(id: ID!, input: MetaPath!): ProductClearMeta @deprecated(reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31.") + productUpdatePrivateMetadata(id: ID!, input: MetaInput!): ProductUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + productClearPrivateMetadata(id: ID!, input: MetaPath!): ProductClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") productImageCreate(input: ProductImageCreateInput!): ProductImageCreate productImageDelete(id: ID!): ProductImageDelete productImageBulkDelete(ids: [ID]!): ProductImageBulkDelete productImageReorder(imagesIds: [ID]!, productId: ID!): ProductImageReorder - productImageUpdate( - id: ID! - input: ProductImageUpdateInput! - ): ProductImageUpdate + productImageUpdate(id: ID!, input: ProductImageUpdateInput!): ProductImageUpdate productTypeCreate(input: ProductTypeInput!): ProductTypeCreate productTypeDelete(id: ID!): ProductTypeDelete productTypeBulkDelete(ids: [ID]!): ProductTypeBulkDelete productTypeUpdate(id: ID!, input: ProductTypeInput!): ProductTypeUpdate - productTypeReorderAttributes( - moves: [ReorderInput]! - productTypeId: ID! - type: AttributeTypeEnum! - ): ProductTypeReorderAttributes - productTypeUpdateMetadata(id: ID!, input: MetaInput!): ProductTypeUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - productTypeClearMetadata(id: ID!, input: MetaPath!): ProductTypeClearMeta - @deprecated( - reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - productTypeUpdatePrivateMetadata( - id: ID! - input: MetaInput! - ): ProductTypeUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - productTypeClearPrivateMetadata( - id: ID! - input: MetaPath! - ): ProductTypeClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - digitalContentCreate( - input: DigitalContentUploadInput! - variantId: ID! - ): DigitalContentCreate + productTypeReorderAttributes(moves: [ReorderInput]!, productTypeId: ID!, type: AttributeTypeEnum!): ProductTypeReorderAttributes + productTypeUpdateMetadata(id: ID!, input: MetaInput!): ProductTypeUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31.") + productTypeClearMetadata(id: ID!, input: MetaPath!): ProductTypeClearMeta @deprecated(reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31.") + productTypeUpdatePrivateMetadata(id: ID!, input: MetaInput!): ProductTypeUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + productTypeClearPrivateMetadata(id: ID!, input: MetaPath!): ProductTypeClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + digitalContentCreate(input: DigitalContentUploadInput!, variantId: ID!): DigitalContentCreate digitalContentDelete(variantId: ID!): DigitalContentDelete - digitalContentUpdate( - input: DigitalContentInput! - variantId: ID! - ): DigitalContentUpdate - digitalContentUrlCreate( - input: DigitalContentUrlCreateInput! - ): DigitalContentUrlCreate + digitalContentUpdate(input: DigitalContentInput!, variantId: ID!): DigitalContentUpdate + digitalContentUrlCreate(input: DigitalContentUrlCreateInput!): DigitalContentUrlCreate productVariantCreate(input: ProductVariantCreateInput!): ProductVariantCreate productVariantDelete(id: ID!): ProductVariantDelete - productVariantBulkCreate( - product: ID! - variants: [ProductVariantBulkCreateInput]! - ): ProductVariantBulkCreate + productVariantBulkCreate(product: ID!, variants: [ProductVariantBulkCreateInput]!): ProductVariantBulkCreate productVariantBulkDelete(ids: [ID]!): ProductVariantBulkDelete - productVariantStocksCreate( - stocks: [StockInput!]! - variantId: ID! - ): ProductVariantStocksCreate - productVariantStocksDelete( - variantId: ID! - warehouseIds: [ID!] - ): ProductVariantStocksDelete - productVariantStocksUpdate( - stocks: [StockInput!]! - variantId: ID! - ): ProductVariantStocksUpdate - productVariantUpdate( - id: ID! - input: ProductVariantInput! - ): ProductVariantUpdate - productVariantTranslate( - id: ID! - input: NameTranslationInput! - languageCode: LanguageCodeEnum! - ): ProductVariantTranslate - productVariantUpdateMetadata( - id: ID! - input: MetaInput! - ): ProductVariantUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - productVariantClearMetadata( - id: ID! - input: MetaPath! - ): ProductVariantClearMeta - @deprecated( - reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - productVariantUpdatePrivateMetadata( - id: ID! - input: MetaInput! - ): ProductVariantUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - productVariantClearPrivateMetadata( - id: ID! - input: MetaPath! - ): ProductVariantClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) + productVariantStocksCreate(stocks: [StockInput!]!, variantId: ID!): ProductVariantStocksCreate + productVariantStocksDelete(variantId: ID!, warehouseIds: [ID!]): ProductVariantStocksDelete + productVariantStocksUpdate(stocks: [StockInput!]!, variantId: ID!): ProductVariantStocksUpdate + productVariantUpdate(id: ID!, input: ProductVariantInput!): ProductVariantUpdate + productVariantTranslate(id: ID!, input: NameTranslationInput!, languageCode: LanguageCodeEnum!): ProductVariantTranslate + productVariantUpdateMetadata(id: ID!, input: MetaInput!): ProductVariantUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31.") + productVariantClearMetadata(id: ID!, input: MetaPath!): ProductVariantClearMeta @deprecated(reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31.") + productVariantUpdatePrivateMetadata(id: ID!, input: MetaInput!): ProductVariantUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + productVariantClearPrivateMetadata(id: ID!, input: MetaPath!): ProductVariantClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") variantImageAssign(imageId: ID!, variantId: ID!): VariantImageAssign variantImageUnassign(imageId: ID!, variantId: ID!): VariantImageUnassign paymentCapture(amount: Decimal, paymentId: ID!): PaymentCapture paymentRefund(amount: Decimal, paymentId: ID!): PaymentRefund paymentVoid(paymentId: ID!): PaymentVoid - paymentSecureConfirm(paymentId: ID!): PaymentSecureConfirm pageCreate(input: PageInput!): PageCreate pageDelete(id: ID!): PageDelete pageBulkDelete(ids: [ID]!): PageBulkDelete pageBulkPublish(ids: [ID]!, isPublished: Boolean!): PageBulkPublish pageUpdate(id: ID!, input: PageInput!): PageUpdate - pageTranslate( - id: ID! - input: PageTranslationInput! - languageCode: LanguageCodeEnum! - ): PageTranslate + pageTranslate(id: ID!, input: PageTranslationInput!, languageCode: LanguageCodeEnum!): PageTranslate draftOrderComplete(id: ID!): DraftOrderComplete draftOrderCreate(input: DraftOrderCreateInput!): DraftOrderCreate draftOrderDelete(id: ID!): DraftOrderDelete draftOrderBulkDelete(ids: [ID]!): DraftOrderBulkDelete draftOrderLinesBulkDelete(ids: [ID]!): DraftOrderLinesBulkDelete - draftOrderLinesCreate( - id: ID! - input: [OrderLineCreateInput]! - ): DraftOrderLinesCreate + draftOrderLinesCreate(id: ID!, input: [OrderLineCreateInput]!): DraftOrderLinesCreate draftOrderLineDelete(id: ID!): DraftOrderLineDelete draftOrderLineUpdate(id: ID!, input: OrderLineInput!): DraftOrderLineUpdate draftOrderUpdate(id: ID!, input: DraftOrderInput!): DraftOrderUpdate orderAddNote(order: ID!, input: OrderAddNoteInput!): OrderAddNote orderCancel(id: ID!): OrderCancel orderCapture(amount: Decimal!, id: ID!): OrderCapture - orderClearPrivateMeta(id: ID!, input: MetaPath!): OrderClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - orderClearMeta(input: MetaPath!, token: UUID!): OrderClearMeta - @deprecated( - reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31." - ) + orderClearPrivateMeta(id: ID!, input: MetaPath!): OrderClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + orderClearMeta(input: MetaPath!, token: UUID!): OrderClearMeta @deprecated(reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31.") orderFulfill(input: OrderFulfillInput!, order: ID): OrderFulfill - orderFulfillmentCancel( - id: ID! - input: FulfillmentCancelInput! - ): FulfillmentCancel - orderFulfillmentUpdateTracking( - id: ID! - input: FulfillmentUpdateTrackingInput! - ): FulfillmentUpdateTracking - orderFulfillmentClearMeta(id: ID!, input: MetaPath!): FulfillmentClearMeta - @deprecated( - reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - orderFulfillmentClearPrivateMeta( - id: ID! - input: MetaPath! - ): FulfillmentClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - orderFulfillmentUpdateMeta(id: ID!, input: MetaInput!): FulfillmentUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - orderFulfillmentUpdatePrivateMeta( - id: ID! - input: MetaInput! - ): FulfillmentUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) + orderFulfillmentCancel(id: ID!, input: FulfillmentCancelInput!): FulfillmentCancel + orderFulfillmentUpdateTracking(id: ID!, input: FulfillmentUpdateTrackingInput!): FulfillmentUpdateTracking + orderFulfillmentClearMeta(id: ID!, input: MetaPath!): FulfillmentClearMeta @deprecated(reason: "Use the `deleteMetadata` mutation instead. This field will be removed after 2020-07-31.") + orderFulfillmentClearPrivateMeta(id: ID!, input: MetaPath!): FulfillmentClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + orderFulfillmentUpdateMeta(id: ID!, input: MetaInput!): FulfillmentUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31.") + orderFulfillmentUpdatePrivateMeta(id: ID!, input: MetaInput!): FulfillmentUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") orderMarkAsPaid(id: ID!): OrderMarkAsPaid orderRefund(amount: Decimal!, id: ID!): OrderRefund orderUpdate(id: ID!, input: OrderUpdateInput!): OrderUpdate - orderUpdateMeta(input: MetaInput!, token: UUID!): OrderUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - orderUpdatePrivateMeta(id: ID!, input: MetaInput!): OrderUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31." - ) - orderUpdateShipping( - order: ID! - input: OrderUpdateShippingInput - ): OrderUpdateShipping + orderUpdateMeta(input: MetaInput!, token: UUID!): OrderUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation instead. This field will be removed after 2020-07-31.") + orderUpdatePrivateMeta(id: ID!, input: MetaInput!): OrderUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation instead. This field will be removed after 2020-07-31.") + orderUpdateShipping(order: ID!, input: OrderUpdateShippingInput): OrderUpdateShipping orderVoid(id: ID!): OrderVoid orderBulkCancel(ids: [ID]!): OrderBulkCancel deleteMetadata(id: ID!, keys: [String!]!): DeleteMetadata deletePrivateMetadata(id: ID!, keys: [String!]!): DeletePrivateMetadata updateMetadata(id: ID!, input: [MetadataInput!]!): UpdateMetadata - updatePrivateMetadata( - id: ID! - input: [MetadataInput!]! - ): UpdatePrivateMetadata + updatePrivateMetadata(id: ID!, input: [MetadataInput!]!): UpdatePrivateMetadata assignNavigation(menu: ID, navigationType: NavigationType!): AssignNavigation menuCreate(input: MenuCreateInput!): MenuCreate menuDelete(id: ID!): MenuDelete @@ -3472,11 +2719,7 @@ type Mutation { menuItemDelete(id: ID!): MenuItemDelete menuItemBulkDelete(ids: [ID]!): MenuItemBulkDelete menuItemUpdate(id: ID!, input: MenuItemInput!): MenuItemUpdate - menuItemTranslate( - id: ID! - input: NameTranslationInput! - languageCode: LanguageCodeEnum! - ): MenuItemTranslate + menuItemTranslate(id: ID!, input: NameTranslationInput!, languageCode: LanguageCodeEnum!): MenuItemTranslate menuItemMove(menu: ID!, moves: [MenuItemMoveInput]!): MenuItemMove invoiceRequest(number: String, orderId: ID!): InvoiceRequest invoiceRequestDelete(id: ID!): InvoiceRequestDelete @@ -3495,150 +2738,68 @@ type Mutation { saleUpdate(id: ID!, input: SaleInput!): SaleUpdate saleCataloguesAdd(id: ID!, input: CatalogueInput!): SaleAddCatalogues saleCataloguesRemove(id: ID!, input: CatalogueInput!): SaleRemoveCatalogues - saleTranslate( - id: ID! - input: NameTranslationInput! - languageCode: LanguageCodeEnum! - ): SaleTranslate + saleTranslate(id: ID!, input: NameTranslationInput!, languageCode: LanguageCodeEnum!): SaleTranslate voucherCreate(input: VoucherInput!): VoucherCreate voucherDelete(id: ID!): VoucherDelete voucherBulkDelete(ids: [ID]!): VoucherBulkDelete voucherUpdate(id: ID!, input: VoucherInput!): VoucherUpdate voucherCataloguesAdd(id: ID!, input: CatalogueInput!): VoucherAddCatalogues - voucherCataloguesRemove( - id: ID! - input: CatalogueInput! - ): VoucherRemoveCatalogues - voucherTranslate( - id: ID! - input: NameTranslationInput! - languageCode: LanguageCodeEnum! - ): VoucherTranslate - checkoutAddPromoCode( - checkoutId: ID! - promoCode: String! - ): CheckoutAddPromoCode - checkoutBillingAddressUpdate( - billingAddress: AddressInput! - checkoutId: ID! - ): CheckoutBillingAddressUpdate - checkoutComplete( - checkoutId: ID! - redirectUrl: String - storeSource: Boolean = false - ): CheckoutComplete + voucherCataloguesRemove(id: ID!, input: CatalogueInput!): VoucherRemoveCatalogues + voucherTranslate(id: ID!, input: NameTranslationInput!, languageCode: LanguageCodeEnum!): VoucherTranslate + exportProducts(input: ExportProductsInput!): ExportProducts + checkoutAddPromoCode(checkoutId: ID!, promoCode: String!): CheckoutAddPromoCode + checkoutBillingAddressUpdate(billingAddress: AddressInput!, checkoutId: ID!): CheckoutBillingAddressUpdate + checkoutComplete(checkoutId: ID!, redirectUrl: String, storeSource: Boolean = false): CheckoutComplete checkoutCreate(input: CheckoutCreateInput!): CheckoutCreate - checkoutCustomerAttach( - checkoutId: ID! - customerId: ID - ): CheckoutCustomerAttach + checkoutCustomerAttach(checkoutId: ID!, customerId: ID): CheckoutCustomerAttach checkoutCustomerDetach(checkoutId: ID!): CheckoutCustomerDetach checkoutEmailUpdate(checkoutId: ID, email: String!): CheckoutEmailUpdate checkoutLineDelete(checkoutId: ID!, lineId: ID): CheckoutLineDelete - checkoutLinesAdd( - checkoutId: ID! - lines: [CheckoutLineInput]! - ): CheckoutLinesAdd - checkoutLinesUpdate( - checkoutId: ID! - lines: [CheckoutLineInput]! - ): CheckoutLinesUpdate - checkoutRemovePromoCode( - checkoutId: ID! - promoCode: String! - ): CheckoutRemovePromoCode - checkoutPaymentCreate( - checkoutId: ID! - input: PaymentInput! - ): CheckoutPaymentCreate - checkoutShippingAddressUpdate( - checkoutId: ID! - shippingAddress: AddressInput! - ): CheckoutShippingAddressUpdate - checkoutShippingMethodUpdate( - checkoutId: ID - shippingMethodId: ID! - ): CheckoutShippingMethodUpdate - checkoutUpdateMetadata(id: ID!, input: MetaInput!): CheckoutUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation. This field will be removed after 2020-07-31." - ) - checkoutClearMetadata(id: ID!, input: MetaPath!): CheckoutClearMeta - @deprecated( - reason: "Use the `deleteMetadata` mutation. This field will be removed after 2020-07-31." - ) - checkoutUpdatePrivateMetadata( - id: ID! - input: MetaInput! - ): CheckoutUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation. This field will be removed after 2020-07-31." - ) - checkoutClearPrivateMetadata( - id: ID! - input: MetaPath! - ): CheckoutClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation. This field will be removed after 2020-07-31." - ) + checkoutLinesAdd(checkoutId: ID!, lines: [CheckoutLineInput]!): CheckoutLinesAdd + checkoutLinesUpdate(checkoutId: ID!, lines: [CheckoutLineInput]!): CheckoutLinesUpdate + checkoutRemovePromoCode(checkoutId: ID!, promoCode: String!): CheckoutRemovePromoCode + checkoutPaymentCreate(checkoutId: ID!, input: PaymentInput!): CheckoutPaymentCreate + checkoutShippingAddressUpdate(checkoutId: ID!, shippingAddress: AddressInput!): CheckoutShippingAddressUpdate + checkoutShippingMethodUpdate(checkoutId: ID, shippingMethodId: ID!): CheckoutShippingMethodUpdate + checkoutUpdateMetadata(id: ID!, input: MetaInput!): CheckoutUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation. This field will be removed after 2020-07-31.") + checkoutClearMetadata(id: ID!, input: MetaPath!): CheckoutClearMeta @deprecated(reason: "Use the `deleteMetadata` mutation. This field will be removed after 2020-07-31.") + checkoutUpdatePrivateMetadata(id: ID!, input: MetaInput!): CheckoutUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation. This field will be removed after 2020-07-31.") + checkoutClearPrivateMetadata(id: ID!, input: MetaPath!): CheckoutClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation. This field will be removed after 2020-07-31.") appCreate(input: AppInput!): AppCreate appUpdate(id: ID!, input: AppInput!): AppUpdate appDelete(id: ID!): AppDelete appTokenCreate(input: AppTokenInput!): AppTokenCreate appTokenDelete(id: ID!): AppTokenDelete appTokenVerify(token: String!): AppTokenVerify - tokenCreate(email: String!, password: String!): CreateToken - tokenRefresh(csrfToken: String, refreshToken: String): RefreshToken - tokenVerify(token: String!): VerifyToken - tokensDeactivateAll: DeactivateAllUserTokens appInstall(input: AppInstallInput!): AppInstall - appRetryInstall( - activateAfterInstallation: Boolean = true - id: ID! - ): AppRetryInstall + appRetryInstall(activateAfterInstallation: Boolean = true, id: ID!): AppRetryInstall appDeleteFailedInstallation(id: ID!): AppDeleteFailedInstallation appFetchManifest(manifestUrl: String!): AppFetchManifest appActivate(id: ID!): AppActivate appDeactivate(id: ID!): AppDeactivate - requestPasswordReset( - email: String! - redirectUrl: String! - ): RequestPasswordReset + tokenCreate(email: String!, password: String!): CreateToken + tokenRefresh(csrfToken: String, refreshToken: String): RefreshToken + tokenVerify(token: String!): VerifyToken + tokensDeactivateAll: DeactivateAllUserTokens + requestPasswordReset(email: String!, redirectUrl: String!): RequestPasswordReset confirmAccount(email: String!, token: String!): ConfirmAccount setPassword(email: String!, password: String!, token: String!): SetPassword passwordChange(newPassword: String!, oldPassword: String!): PasswordChange - requestEmailChange( - newEmail: String! - password: String! - redirectUrl: String! - ): RequestEmailChange + requestEmailChange(newEmail: String!, password: String!, redirectUrl: String!): RequestEmailChange confirmEmailChange(token: String!): ConfirmEmailChange - accountAddressCreate( - input: AddressInput! - type: AddressTypeEnum - ): AccountAddressCreate + accountAddressCreate(input: AddressInput!, type: AddressTypeEnum): AccountAddressCreate accountAddressUpdate(id: ID!, input: AddressInput!): AccountAddressUpdate accountAddressDelete(id: ID!): AccountAddressDelete - accountSetDefaultAddress( - id: ID! - type: AddressTypeEnum! - ): AccountSetDefaultAddress + accountSetDefaultAddress(id: ID!, type: AddressTypeEnum!): AccountSetDefaultAddress accountRegister(input: AccountRegisterInput!): AccountRegister accountUpdate(input: AccountInput!): AccountUpdate accountRequestDeletion(redirectUrl: String!): AccountRequestDeletion accountDelete(token: String!): AccountDelete - accountUpdateMeta(input: MetaInput!): AccountUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation. This field will be removed after 2020-07-31." - ) + accountUpdateMeta(input: MetaInput!): AccountUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation. This field will be removed after 2020-07-31.") addressCreate(input: AddressInput!, userId: ID!): AddressCreate addressUpdate(id: ID!, input: AddressInput!): AddressUpdate addressDelete(id: ID!): AddressDelete - addressSetDefault( - addressId: ID! - type: AddressTypeEnum! - userId: ID! - ): AddressSetDefault + addressSetDefault(addressId: ID!, type: AddressTypeEnum!, userId: ID!): AddressSetDefault customerCreate(input: UserCreateInput!): CustomerCreate customerUpdate(id: ID!, input: CustomerInput!): CustomerUpdate customerDelete(id: ID!): CustomerDelete @@ -3650,68 +2811,19 @@ type Mutation { userAvatarUpdate(image: Upload!): UserAvatarUpdate userAvatarDelete: UserAvatarDelete userBulkSetActive(ids: [ID]!, isActive: Boolean!): UserBulkSetActive - userUpdateMetadata(id: ID!, input: MetaInput!): UserUpdateMeta - @deprecated( - reason: "Use the `updateMetadata` mutation. This field will be removed after 2020-07-31." - ) - userClearMetadata(id: ID!, input: MetaPath!): UserClearMeta - @deprecated( - reason: "Use the `deleteMetadata` mutation. This field will be removed after 2020-07-31." - ) - userUpdatePrivateMetadata(id: ID!, input: MetaInput!): UserUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation. This field will be removed after 2020-07-31." - ) - userClearPrivateMetadata(id: ID!, input: MetaPath!): UserClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation. This field will be removed after 2020-07-31." - ) - serviceAccountCreate(input: ServiceAccountInput!): ServiceAccountCreate - @deprecated( - reason: "Use the `appCreate` mutation instead. This field will be removed after 2020-07-31." - ) - serviceAccountUpdate( - id: ID! - input: ServiceAccountInput! - ): ServiceAccountUpdate - @deprecated( - reason: "Use the `appUpdate` mutation instead. This field will be removed after 2020-07-31." - ) - serviceAccountDelete(id: ID!): ServiceAccountDelete - @deprecated( - reason: "Use the `appDelete` mutation instead. This field will be removed after 2020-07-31." - ) - serviceAccountUpdatePrivateMetadata( - id: ID! - input: MetaInput! - ): ServiceAccountUpdatePrivateMeta - @deprecated( - reason: "Use the `updatePrivateMetadata` mutation with App instead.This field will be removed after 2020-07-31." - ) - serviceAccountClearPrivateMetadata( - id: ID! - input: MetaPath! - ): ServiceAccountClearPrivateMeta - @deprecated( - reason: "Use the `deletePrivateMetadata` mutation with App instead.This field will be removed after 2020-07-31." - ) - serviceAccountTokenCreate( - input: ServiceAccountTokenInput! - ): ServiceAccountTokenCreate - @deprecated( - reason: "Use the `appTokenCreate` mutation instead. This field will be removed after 2020-07-31." - ) - serviceAccountTokenDelete(id: ID!): ServiceAccountTokenDelete - @deprecated( - reason: "Use the `appTokenDelete` mutation instead. This field will be removed after 2020-07-31." - ) - permissionGroupCreate( - input: PermissionGroupCreateInput! - ): PermissionGroupCreate - permissionGroupUpdate( - id: ID! - input: PermissionGroupUpdateInput! - ): PermissionGroupUpdate + userUpdateMetadata(id: ID!, input: MetaInput!): UserUpdateMeta @deprecated(reason: "Use the `updateMetadata` mutation. This field will be removed after 2020-07-31.") + userClearMetadata(id: ID!, input: MetaPath!): UserClearMeta @deprecated(reason: "Use the `deleteMetadata` mutation. This field will be removed after 2020-07-31.") + userUpdatePrivateMetadata(id: ID!, input: MetaInput!): UserUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation. This field will be removed after 2020-07-31.") + userClearPrivateMetadata(id: ID!, input: MetaPath!): UserClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation. This field will be removed after 2020-07-31.") + serviceAccountCreate(input: ServiceAccountInput!): ServiceAccountCreate @deprecated(reason: "Use the `appCreate` mutation instead. This field will be removed after 2020-07-31.") + serviceAccountUpdate(id: ID!, input: ServiceAccountInput!): ServiceAccountUpdate @deprecated(reason: "Use the `appUpdate` mutation instead. This field will be removed after 2020-07-31.") + serviceAccountDelete(id: ID!): ServiceAccountDelete @deprecated(reason: "Use the `appDelete` mutation instead. This field will be removed after 2020-07-31.") + serviceAccountUpdatePrivateMetadata(id: ID!, input: MetaInput!): ServiceAccountUpdatePrivateMeta @deprecated(reason: "Use the `updatePrivateMetadata` mutation with App instead.This field will be removed after 2020-07-31.") + serviceAccountClearPrivateMetadata(id: ID!, input: MetaPath!): ServiceAccountClearPrivateMeta @deprecated(reason: "Use the `deletePrivateMetadata` mutation with App instead.This field will be removed after 2020-07-31.") + serviceAccountTokenCreate(input: ServiceAccountTokenInput!): ServiceAccountTokenCreate @deprecated(reason: "Use the `appTokenCreate` mutation instead. This field will be removed after 2020-07-31.") + serviceAccountTokenDelete(id: ID!): ServiceAccountTokenDelete @deprecated(reason: "Use the `appTokenDelete` mutation instead. This field will be removed after 2020-07-31.") + permissionGroupCreate(input: PermissionGroupCreateInput!): PermissionGroupCreate + permissionGroupUpdate(id: ID!, input: PermissionGroupUpdateInput!): PermissionGroupUpdate permissionGroupDelete(id: ID!): PermissionGroupDelete } @@ -3736,14 +2848,8 @@ interface Node { interface ObjectWithMetadata { privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") } type Order implements Node & ObjectWithMetadata { @@ -3769,14 +2875,8 @@ type Order implements Node & ObjectWithMetadata { weight: Weight privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") fulfillments: [Fulfillment]! lines: [OrderLine]! actions: [OrderAction]! @@ -3807,10 +2907,7 @@ enum OrderAction { } type OrderAddNote { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order event: OrderEvent orderErrors: [OrderError!]! @@ -3821,45 +2918,30 @@ input OrderAddNoteInput { } type OrderBulkCancel { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! orderErrors: [OrderError!]! } type OrderCancel { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order orderErrors: [OrderError!]! } type OrderCapture { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order orderErrors: [OrderError!]! } type OrderClearMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order } type OrderClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order } @@ -4004,10 +3086,7 @@ input OrderFilterInput { } type OrderFulfill { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") fulfillments: [Fulfillment] order: Order orderErrors: [OrderError!]! @@ -4055,19 +3134,13 @@ input OrderLineInput { } type OrderMarkAsPaid { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order orderErrors: [OrderError!]! } type OrderRefund { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order orderErrors: [OrderError!]! } @@ -4104,10 +3177,7 @@ enum OrderStatusFilter { } type OrderUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") orderErrors: [OrderError!]! order: Order } @@ -4119,26 +3189,17 @@ input OrderUpdateInput { } type OrderUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order } type OrderUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order } type OrderUpdateShipping { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order orderErrors: [OrderError!]! } @@ -4148,10 +3209,7 @@ input OrderUpdateShippingInput { } type OrderVoid { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") order: Order orderErrors: [OrderError!]! } @@ -4171,19 +3229,13 @@ type Page implements Node { } type PageBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! pageErrors: [PageError!]! } type PageBulkPublish { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! pageErrors: [PageError!]! } @@ -4200,19 +3252,13 @@ type PageCountableEdge { } type PageCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") pageErrors: [PageError!]! page: Page } type PageDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") pageErrors: [PageError!]! page: Page } @@ -4277,10 +3323,7 @@ type PageTranslatableContent implements Node { } type PageTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! page: PageTranslatableContent } @@ -4304,19 +3347,13 @@ input PageTranslationInput { } type PageUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") pageErrors: [PageError!]! page: Page } type PasswordChange { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! } @@ -4330,14 +3367,11 @@ type Payment implements Node { token: String! checkout: Checkout order: Order - billingEmail: String! customerIpAddress: String - extraData: String! chargeStatus: PaymentChargeStatusEnum! actions: [OrderAction]! total: Money capturedAmount: Money - billingAddress: Address transactions: [Transaction] availableCaptureAmount: Money availableRefundAmount: Money @@ -4345,10 +3379,7 @@ type Payment implements Node { } type PaymentCapture { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") payment: Payment paymentErrors: [PaymentError!]! } @@ -4408,19 +3439,7 @@ input PaymentInput { } type PaymentRefund { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) - payment: Payment - paymentErrors: [PaymentError!]! -} - -type PaymentSecureConfirm { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") payment: Payment paymentErrors: [PaymentError!]! } @@ -4431,10 +3450,7 @@ type PaymentSource { } type PaymentVoid { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") payment: Payment paymentErrors: [PaymentError!]! } @@ -4463,10 +3479,7 @@ enum PermissionEnum { } type PermissionGroupCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") permissionGroupErrors: [PermissionGroupError!]! group: Group } @@ -4478,10 +3491,7 @@ input PermissionGroupCreateInput { } type PermissionGroupDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") permissionGroupErrors: [PermissionGroupError!]! group: Group } @@ -4519,10 +3529,7 @@ input PermissionGroupSortingInput { } type PermissionGroupUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") permissionGroupErrors: [PermissionGroupError!]! group: Group } @@ -4585,10 +3592,7 @@ input PluginSortingInput { } type PluginUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") plugin: Plugin pluginsErrors: [PluginError!]! } @@ -4620,16 +3624,9 @@ type Product implements Node & ObjectWithMetadata { weight: Weight privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) - url: String! - @deprecated(reason: "This field will be removed after 2020-07-31.") + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") + url: String! @deprecated(reason: "This field will be removed after 2020-07-31.") thumbnail(size: Int): Image pricing: ProductPricingInfo isAvailable: Boolean @@ -4653,37 +3650,25 @@ type ProductAttributeError { } type ProductBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productErrors: [ProductError!]! } type ProductBulkPublish { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productErrors: [ProductError!]! } type ProductClearMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! product: Product } type ProductClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! product: Product } @@ -4700,10 +3685,7 @@ type ProductCountableEdge { } type ProductCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! product: Product } @@ -4730,10 +3712,7 @@ input ProductCreateInput { } type ProductDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! product: Product } @@ -4799,19 +3778,13 @@ type ProductImage implements Node { } type ProductImageBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productErrors: [ProductError!]! } type ProductImageCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") product: Product image: ProductImage productErrors: [ProductError!]! @@ -4824,30 +3797,21 @@ input ProductImageCreateInput { } type ProductImageDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") product: Product image: ProductImage productErrors: [ProductError!]! } type ProductImageReorder { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") product: Product images: [ProductImage] productErrors: [ProductError!]! } type ProductImageUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") product: Product image: ProductImage productErrors: [ProductError!]! @@ -4917,10 +3881,7 @@ type ProductTranslatableContent implements Node { } type ProductTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! product: Product } @@ -4945,56 +3906,30 @@ type ProductType implements Node & ObjectWithMetadata { weight: Weight privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) - products( - before: String - after: String - first: Int - last: Int - ): ProductCountableConnection + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") + products(before: String, after: String, first: Int, last: Int): ProductCountableConnection taxRate: TaxRateType taxType: TaxType variantAttributes: [Attribute] productAttributes: [Attribute] - availableAttributes( - filter: AttributeFilterInput - before: String - after: String - first: Int - last: Int - ): AttributeCountableConnection + availableAttributes(filter: AttributeFilterInput, before: String, after: String, first: Int, last: Int): AttributeCountableConnection } type ProductTypeBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productErrors: [ProductError!]! } type ProductTypeClearMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productType: ProductType } type ProductTypeClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productType: ProductType } @@ -5016,19 +3951,13 @@ type ProductTypeCountableEdge { } type ProductTypeCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productType: ProductType } type ProductTypeDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productType: ProductType } @@ -5058,10 +3987,7 @@ input ProductTypeInput { } type ProductTypeReorderAttributes { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productType: ProductType productErrors: [ProductError!]! } @@ -5078,55 +4004,37 @@ input ProductTypeSortingInput { } type ProductTypeUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productType: ProductType } type ProductTypeUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productType: ProductType } type ProductTypeUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productType: ProductType } type ProductUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! product: Product } type ProductUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! product: Product } type ProductUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! product: Product } @@ -5140,32 +4048,14 @@ type ProductVariant implements Node & ObjectWithMetadata { weight: Weight privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) - quantity: Int! - @deprecated( - reason: "Use the stock field instead. This field will be removed after 2020-07-31." - ) - quantityAllocated: Int - @deprecated( - reason: "Use the stock field instead. This field will be removed after 2020-07-31." - ) - stockQuantity: Int! - @deprecated( - reason: "Use the quantityAvailable field instead. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") + quantity: Int! @deprecated(reason: "Use the stock field instead. This field will be removed after 2020-07-31.") + quantityAllocated: Int @deprecated(reason: "Use the stock field instead. This field will be removed after 2020-07-31.") + stockQuantity: Int! @deprecated(reason: "Use the quantityAvailable field instead. This field will be removed after 2020-07-31.") price: Money pricing: VariantPricingInfo - isAvailable: Boolean - @deprecated( - reason: "Use the stock field instead. This field will be removed after 2020-07-31." - ) + isAvailable: Boolean @deprecated(reason: "Use the stock field instead. This field will be removed after 2020-07-31.") attributes: [SelectedAttribute!]! costPrice: Money margin: Int @@ -5179,10 +4069,7 @@ type ProductVariant implements Node & ObjectWithMetadata { } type ProductVariantBulkCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productVariants: [ProductVariant!]! bulkProductErrors: [BulkProductError!]! @@ -5199,28 +4086,19 @@ input ProductVariantBulkCreateInput { } type ProductVariantBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! productErrors: [ProductError!]! } type ProductVariantClearMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productVariant: ProductVariant } type ProductVariantClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productVariant: ProductVariant } @@ -5237,10 +4115,7 @@ type ProductVariantCountableEdge { } type ProductVariantCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productVariant: ProductVariant } @@ -5257,10 +4132,7 @@ input ProductVariantCreateInput { } type ProductVariantDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productVariant: ProductVariant } @@ -5275,28 +4147,19 @@ input ProductVariantInput { } type ProductVariantStocksCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productVariant: ProductVariant bulkStockErrors: [BulkStockError!]! } type ProductVariantStocksDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productVariant: ProductVariant stockErrors: [StockError!]! } type ProductVariantStocksUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productVariant: ProductVariant bulkStockErrors: [BulkStockError!]! } @@ -5309,10 +4172,7 @@ type ProductVariantTranslatableContent implements Node { } type ProductVariantTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! productVariant: ProductVariant } @@ -5324,322 +4184,93 @@ type ProductVariantTranslation implements Node { } type ProductVariantUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productVariant: ProductVariant } type ProductVariantUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productVariant: ProductVariant } type ProductVariantUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productErrors: [ProductError!]! productVariant: ProductVariant } type Query { webhook(id: ID!): Webhook - webhooks( - sortBy: WebhookSortingInput - filter: WebhookFilterInput - before: String - after: String - first: Int - last: Int - ): WebhookCountableConnection - @deprecated( - reason: "Use webhooks field on app(s) query instead. This field will be removed after 2020-07-31." - ) + webhooks(sortBy: WebhookSortingInput, filter: WebhookFilterInput, before: String, after: String, first: Int, last: Int): WebhookCountableConnection @deprecated(reason: "Use webhooks field on app(s) query instead. This field will be removed after 2020-07-31.") webhookEvents: [WebhookEvent] webhookSamplePayload(eventType: WebhookSampleEventTypeEnum!): JSONString warehouse(id: ID!): Warehouse - warehouses( - filter: WarehouseFilterInput - sortBy: WarehouseSortingInput - before: String - after: String - first: Int - last: Int - ): WarehouseCountableConnection - translations( - kind: TranslatableKinds! - before: String - after: String - first: Int - last: Int - ): TranslatableItemConnection + warehouses(filter: WarehouseFilterInput, sortBy: WarehouseSortingInput, before: String, after: String, first: Int, last: Int): WarehouseCountableConnection + translations(kind: TranslatableKinds!, before: String, after: String, first: Int, last: Int): TranslatableItemConnection translation(id: ID!, kind: TranslatableKinds!): TranslatableItem stock(id: ID!): Stock - stocks( - filter: StockFilterInput - before: String - after: String - first: Int - last: Int - ): StockCountableConnection + stocks(filter: StockFilterInput, before: String, after: String, first: Int, last: Int): StockCountableConnection shop: Shop! shippingZone(id: ID!): ShippingZone - shippingZones( - before: String - after: String - first: Int - last: Int - ): ShippingZoneCountableConnection + shippingZones(before: String, after: String, first: Int, last: Int): ShippingZoneCountableConnection digitalContent(id: ID!): DigitalContent - digitalContents( - before: String - after: String - first: Int - last: Int - ): DigitalContentCountableConnection - attributes( - filter: AttributeFilterInput - sortBy: AttributeSortingInput - before: String - after: String - first: Int - last: Int - ): AttributeCountableConnection + digitalContents(before: String, after: String, first: Int, last: Int): DigitalContentCountableConnection + attributes(filter: AttributeFilterInput, sortBy: AttributeSortingInput, before: String, after: String, first: Int, last: Int): AttributeCountableConnection attribute(id: ID!): Attribute - categories( - filter: CategoryFilterInput - sortBy: CategorySortingInput - level: Int - before: String - after: String - first: Int - last: Int - ): CategoryCountableConnection + categories(filter: CategoryFilterInput, sortBy: CategorySortingInput, level: Int, before: String, after: String, first: Int, last: Int): CategoryCountableConnection category(id: ID, slug: String): Category collection(id: ID, slug: String): Collection - collections( - filter: CollectionFilterInput - sortBy: CollectionSortingInput - before: String - after: String - first: Int - last: Int - ): CollectionCountableConnection + collections(filter: CollectionFilterInput, sortBy: CollectionSortingInput, before: String, after: String, first: Int, last: Int): CollectionCountableConnection product(id: ID, slug: String): Product - products( - filter: ProductFilterInput - sortBy: ProductOrder - stockAvailability: StockAvailability - before: String - after: String - first: Int - last: Int - ): ProductCountableConnection + products(filter: ProductFilterInput, sortBy: ProductOrder, stockAvailability: StockAvailability, before: String, after: String, first: Int, last: Int): ProductCountableConnection productType(id: ID!): ProductType - productTypes( - filter: ProductTypeFilterInput - sortBy: ProductTypeSortingInput - before: String - after: String - first: Int - last: Int - ): ProductTypeCountableConnection + productTypes(filter: ProductTypeFilterInput, sortBy: ProductTypeSortingInput, before: String, after: String, first: Int, last: Int): ProductTypeCountableConnection productVariant(id: ID!): ProductVariant - productVariants( - ids: [ID] - before: String - after: String - first: Int - last: Int - ): ProductVariantCountableConnection - reportProductSales( - period: ReportingPeriod! - before: String - after: String - first: Int - last: Int - ): ProductVariantCountableConnection + productVariants(ids: [ID], before: String, after: String, first: Int, last: Int): ProductVariantCountableConnection + reportProductSales(period: ReportingPeriod!, before: String, after: String, first: Int, last: Int): ProductVariantCountableConnection payment(id: ID!): Payment - payments( - before: String - after: String - first: Int - last: Int - ): PaymentCountableConnection + payments(before: String, after: String, first: Int, last: Int): PaymentCountableConnection page(id: ID, slug: String): Page - pages( - sortBy: PageSortingInput - filter: PageFilterInput - before: String - after: String - first: Int - last: Int - ): PageCountableConnection - homepageEvents( - before: String - after: String - first: Int - last: Int - ): OrderEventCountableConnection + pages(sortBy: PageSortingInput, filter: PageFilterInput, before: String, after: String, first: Int, last: Int): PageCountableConnection + homepageEvents(before: String, after: String, first: Int, last: Int): OrderEventCountableConnection order(id: ID!): Order - orders( - sortBy: OrderSortingInput - filter: OrderFilterInput - created: ReportingPeriod - status: OrderStatusFilter - before: String - after: String - first: Int - last: Int - ): OrderCountableConnection - draftOrders( - sortBy: OrderSortingInput - filter: OrderDraftFilterInput - created: ReportingPeriod - before: String - after: String - first: Int - last: Int - ): OrderCountableConnection + orders(sortBy: OrderSortingInput, filter: OrderFilterInput, created: ReportingPeriod, status: OrderStatusFilter, before: String, after: String, first: Int, last: Int): OrderCountableConnection + draftOrders(sortBy: OrderSortingInput, filter: OrderDraftFilterInput, created: ReportingPeriod, before: String, after: String, first: Int, last: Int): OrderCountableConnection ordersTotal(period: ReportingPeriod): TaxedMoney orderByToken(token: UUID!): Order menu(id: ID, name: String): Menu - menus( - sortBy: MenuSortingInput - filter: MenuFilterInput - before: String - after: String - first: Int - last: Int - ): MenuCountableConnection + menus(sortBy: MenuSortingInput, filter: MenuFilterInput, before: String, after: String, first: Int, last: Int): MenuCountableConnection menuItem(id: ID!): MenuItem - menuItems( - sortBy: MenuItemSortingInput - filter: MenuItemFilterInput - before: String - after: String - first: Int - last: Int - ): MenuItemCountableConnection + menuItems(sortBy: MenuItemSortingInput, filter: MenuItemFilterInput, before: String, after: String, first: Int, last: Int): MenuItemCountableConnection giftCard(id: ID!): GiftCard - giftCards( - before: String - after: String - first: Int - last: Int - ): GiftCardCountableConnection + giftCards(before: String, after: String, first: Int, last: Int): GiftCardCountableConnection plugin(id: ID!): Plugin - plugins( - filter: PluginFilterInput - sortBy: PluginSortingInput - before: String - after: String - first: Int - last: Int - ): PluginCountableConnection + plugins(filter: PluginFilterInput, sortBy: PluginSortingInput, before: String, after: String, first: Int, last: Int): PluginCountableConnection sale(id: ID!): Sale - sales( - filter: SaleFilterInput - sortBy: SaleSortingInput - query: String - before: String - after: String - first: Int - last: Int - ): SaleCountableConnection + sales(filter: SaleFilterInput, sortBy: SaleSortingInput, query: String, before: String, after: String, first: Int, last: Int): SaleCountableConnection voucher(id: ID!): Voucher - vouchers( - filter: VoucherFilterInput - sortBy: VoucherSortingInput - query: String - before: String - after: String - first: Int - last: Int - ): VoucherCountableConnection + vouchers(filter: VoucherFilterInput, sortBy: VoucherSortingInput, query: String, before: String, after: String, first: Int, last: Int): VoucherCountableConnection exportFile(id: ID!): ExportFile exportFiles(filter: ExportFileFilterInput, sortBy: ExportFileSortingInput, before: String, after: String, first: Int, last: Int): ExportFileCountableConnection taxTypes: [TaxType] checkout(token: UUID): Checkout - checkouts( - before: String - after: String - first: Int - last: Int - ): CheckoutCountableConnection + checkouts(before: String, after: String, first: Int, last: Int): CheckoutCountableConnection checkoutLine(id: ID): CheckoutLine - checkoutLines( - before: String - after: String - first: Int - last: Int - ): CheckoutLineCountableConnection + checkoutLines(before: String, after: String, first: Int, last: Int): CheckoutLineCountableConnection appsInstallations: [AppInstallation!]! - apps( - filter: AppFilterInput - sortBy: AppSortingInput - before: String - after: String - first: Int - last: Int - ): AppCountableConnection + apps(filter: AppFilterInput, sortBy: AppSortingInput, before: String, after: String, first: Int, last: Int): AppCountableConnection app(id: ID!): App - addressValidationRules( - countryCode: CountryCode! - countryArea: String - city: String - cityArea: String - ): AddressValidationData + addressValidationRules(countryCode: CountryCode!, countryArea: String, city: String, cityArea: String): AddressValidationData address(id: ID!): Address - customers( - filter: CustomerFilterInput - sortBy: UserSortingInput - before: String - after: String - first: Int - last: Int - ): UserCountableConnection - permissionGroups( - filter: PermissionGroupFilterInput - sortBy: PermissionGroupSortingInput - before: String - after: String - first: Int - last: Int - ): GroupCountableConnection + customers(filter: CustomerFilterInput, sortBy: UserSortingInput, before: String, after: String, first: Int, last: Int): UserCountableConnection + permissionGroups(filter: PermissionGroupFilterInput, sortBy: PermissionGroupSortingInput, before: String, after: String, first: Int, last: Int): GroupCountableConnection permissionGroup(id: ID!): Group me: User - staffUsers( - filter: StaffUserInput - sortBy: UserSortingInput - before: String - after: String - first: Int - last: Int - ): UserCountableConnection - serviceAccounts( - filter: ServiceAccountFilterInput - sortBy: ServiceAccountSortingInput - before: String - after: String - first: Int - last: Int - ): ServiceAccountCountableConnection - @deprecated( - reason: "Use the `apps` query instead. This field will be removed after 2020-07-31." - ) - serviceAccount(id: ID!): ServiceAccount - @deprecated( - reason: "Use the `app` query instead. This field will be removed after 2020-07-31." - ) + staffUsers(filter: StaffUserInput, sortBy: UserSortingInput, before: String, after: String, first: Int, last: Int): UserCountableConnection + serviceAccounts(filter: ServiceAccountFilterInput, sortBy: ServiceAccountSortingInput, before: String, after: String, first: Int, last: Int): ServiceAccountCountableConnection @deprecated(reason: "Use the `apps` query instead. This field will be removed after 2020-07-31.") + serviceAccount(id: ID!): ServiceAccount @deprecated(reason: "Use the `app` query instead. This field will be removed after 2020-07-31.") user(id: ID!): User _entities(representations: [_Any]): [_Entity] _service: _Service @@ -5651,10 +4282,7 @@ type ReducedRate { } type RefreshToken { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") token: String user: User accountErrors: [AccountError!]! @@ -5671,19 +4299,13 @@ enum ReportingPeriod { } type RequestEmailChange { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! } type RequestPasswordReset { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! } @@ -5694,41 +4316,20 @@ type Sale implements Node { value: Float! startDate: DateTime! endDate: DateTime - categories( - before: String - after: String - first: Int - last: Int - ): CategoryCountableConnection - collections( - before: String - after: String - first: Int - last: Int - ): CollectionCountableConnection - products( - before: String - after: String - first: Int - last: Int - ): ProductCountableConnection + categories(before: String, after: String, first: Int, last: Int): CategoryCountableConnection + collections(before: String, after: String, first: Int, last: Int): CollectionCountableConnection + products(before: String, after: String, first: Int, last: Int): ProductCountableConnection translation(languageCode: LanguageCodeEnum!): SaleTranslation } type SaleAddCatalogues { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") sale: Sale discountErrors: [DiscountError!]! } type SaleBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! discountErrors: [DiscountError!]! } @@ -5745,19 +4346,13 @@ type SaleCountableEdge { } type SaleCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") discountErrors: [DiscountError!]! sale: Sale } type SaleDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") discountErrors: [DiscountError!]! sale: Sale } @@ -5781,10 +4376,7 @@ input SaleInput { } type SaleRemoveCatalogues { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") sale: Sale discountErrors: [DiscountError!]! } @@ -5810,10 +4402,7 @@ type SaleTranslatableContent implements Node { } type SaleTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! sale: Sale } @@ -5830,10 +4419,7 @@ enum SaleType { } type SaleUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") discountErrors: [DiscountError!]! sale: Sale } @@ -5857,21 +4443,12 @@ type ServiceAccount implements Node & ObjectWithMetadata { tokens: [ServiceAccountToken] privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") } type ServiceAccountClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! serviceAccount: ServiceAccount } @@ -5888,20 +4465,14 @@ type ServiceAccountCountableEdge { } type ServiceAccountCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") authToken: String accountErrors: [AccountError!]! serviceAccount: ServiceAccount } type ServiceAccountDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! serviceAccount: ServiceAccount } @@ -5934,20 +4505,14 @@ type ServiceAccountToken implements Node { } type ServiceAccountTokenCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") authToken: String accountErrors: [AccountError!]! serviceAccountToken: ServiceAccountToken } type ServiceAccountTokenDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! serviceAccountToken: ServiceAccountToken } @@ -5958,28 +4523,19 @@ input ServiceAccountTokenInput { } type ServiceAccountUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! serviceAccount: ServiceAccount } type ServiceAccountUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! serviceAccount: ServiceAccount } type SetPassword { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") token: String refreshToken: String csrfToken: String @@ -6036,29 +4592,20 @@ enum ShippingMethodTypeEnum { } type ShippingPriceBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! shippingErrors: [ShippingError!]! } type ShippingPriceCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shippingZone: ShippingZone shippingErrors: [ShippingError!]! shippingMethod: ShippingMethod } type ShippingPriceDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shippingMethod: ShippingMethod shippingZone: ShippingZone shippingErrors: [ShippingError!]! @@ -6076,19 +4623,13 @@ input ShippingPriceInput { } type ShippingPriceTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! shippingMethod: ShippingMethod } type ShippingPriceUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shippingZone: ShippingZone shippingErrors: [ShippingError!]! shippingMethod: ShippingMethod @@ -6105,10 +4646,7 @@ type ShippingZone implements Node { } type ShippingZoneBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! shippingErrors: [ShippingError!]! } @@ -6125,10 +4663,7 @@ type ShippingZoneCountableEdge { } type ShippingZoneCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shippingErrors: [ShippingError!]! shippingZone: ShippingZone } @@ -6141,19 +4676,13 @@ input ShippingZoneCreateInput { } type ShippingZoneDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shippingErrors: [ShippingError!]! shippingZone: ShippingZone } type ShippingZoneUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shippingErrors: [ShippingError!]! shippingZone: ShippingZone } @@ -6200,19 +4729,13 @@ type Shop { } type ShopAddressUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shop: Shop shopErrors: [ShopError!]! } type ShopDomainUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shop: Shop shopErrors: [ShopError!]! } @@ -6234,10 +4757,7 @@ enum ShopErrorCode { } type ShopFetchTaxRates { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shop: Shop shopErrors: [ShopError!]! } @@ -6259,10 +4779,7 @@ input ShopSettingsInput { } type ShopSettingsTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shop: Shop translationErrors: [TranslationError!]! } @@ -6273,10 +4790,7 @@ input ShopSettingsTranslationInput { } type ShopSettingsUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shop: Shop shopErrors: [ShopError!]! } @@ -6294,19 +4808,13 @@ input SiteDomainInput { } type StaffBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! staffErrors: [StaffError!]! } type StaffCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") staffErrors: [StaffError!]! user: User } @@ -6322,10 +4830,7 @@ input StaffCreateInput { } type StaffDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") staffErrors: [StaffError!]! user: User } @@ -6352,19 +4857,13 @@ type StaffNotificationRecipient implements Node { } type StaffNotificationRecipientCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shopErrors: [ShopError!]! staffNotificationRecipient: StaffNotificationRecipient } type StaffNotificationRecipientDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shopErrors: [ShopError!]! staffNotificationRecipient: StaffNotificationRecipient } @@ -6376,19 +4875,13 @@ input StaffNotificationRecipientInput { } type StaffNotificationRecipientUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") shopErrors: [ShopError!]! staffNotificationRecipient: StaffNotificationRecipient } type StaffUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") staffErrors: [StaffError!]! user: User } @@ -6510,7 +5003,6 @@ type Transaction implements Node { kind: TransactionKind! isSuccess: Boolean! error: TransactionError - gatewayResponse: JSONString! amount: Money } @@ -6535,18 +5027,7 @@ enum TransactionKind { CONFIRM } -union TranslatableItem = - ProductTranslatableContent - | CollectionTranslatableContent - | CategoryTranslatableContent - | AttributeTranslatableContent - | AttributeValueTranslatableContent - | ProductVariantTranslatableContent - | PageTranslatableContent - | ShippingMethodTranslatableContent - | SaleTranslatableContent - | VoucherTranslatableContent - | MenuItemTranslatableContent +union TranslatableItem = ProductTranslatableContent | CollectionTranslatableContent | CategoryTranslatableContent | AttributeTranslatableContent | AttributeValueTranslatableContent | ProductVariantTranslatableContent | PageTranslatableContent | ShippingMethodTranslatableContent | SaleTranslatableContent | VoucherTranslatableContent | MenuItemTranslatableContent type TranslatableItemConnection { pageInfo: PageInfo! @@ -6601,19 +5082,13 @@ input UpdateInvoiceInput { } type UpdateMetadata { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") metadataErrors: [MetadataError!]! item: ObjectWithMetadata } type UpdatePrivateMetadata { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") metadataErrors: [MetadataError!]! item: ObjectWithMetadata } @@ -6634,32 +5109,13 @@ type User implements Node & ObjectWithMetadata { defaultBillingAddress: Address privateMetadata: [MetadataItem]! metadata: [MetadataItem]! - privateMeta: [MetaStore]! - @deprecated( - reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31." - ) - meta: [MetaStore]! - @deprecated( - reason: "Use the `metadata` field. This field will be removed after 2020-07-31." - ) + privateMeta: [MetaStore]! @deprecated(reason: "Use the `privetaMetadata` field. This field will be removed after 2020-07-31.") + meta: [MetaStore]! @deprecated(reason: "Use the `metadata` field. This field will be removed after 2020-07-31.") addresses: [Address] checkout: Checkout - giftCards( - before: String - after: String - first: Int - last: Int - ): GiftCardCountableConnection - orders( - before: String - after: String - first: Int - last: Int - ): OrderCountableConnection - permissions: [Permission] - @deprecated( - reason: "Will be removed in Saleor 2.11.Use the `userPermissions` instead." - ) + giftCards(before: String, after: String, first: Int, last: Int): GiftCardCountableConnection + orders(before: String, after: String, first: Int, last: Int): OrderCountableConnection + permissions: [Permission] @deprecated(reason: "Will be removed in Saleor 2.11.Use the `userPermissions` instead.") userPermissions: [UserPermission] permissionGroups: [Group] editableGroups: [Group] @@ -6669,46 +5125,31 @@ type User implements Node & ObjectWithMetadata { } type UserAvatarDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! } type UserAvatarUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User accountErrors: [AccountError!]! } type UserBulkSetActive { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! accountErrors: [AccountError!]! } type UserClearMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! user: User } type UserClearPrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! user: User } @@ -6754,19 +5195,13 @@ input UserSortingInput { } type UserUpdateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! user: User } type UserUpdatePrivateMeta { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") accountErrors: [AccountError!]! user: User } @@ -6778,20 +5213,14 @@ type VAT { } type VariantImageAssign { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productVariant: ProductVariant image: ProductImage productErrors: [ProductError!]! } type VariantImageUnassign { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") productVariant: ProductVariant image: ProductImage productErrors: [ProductError!]! @@ -6807,10 +5236,7 @@ type VariantPricingInfo { } type VerifyToken { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") user: User isValid: Boolean! payload: GenericScalar @@ -6832,42 +5258,21 @@ type Voucher implements Node { discountValue: Float! minSpent: Money minCheckoutItemsQuantity: Int - categories( - before: String - after: String - first: Int - last: Int - ): CategoryCountableConnection - collections( - before: String - after: String - first: Int - last: Int - ): CollectionCountableConnection - products( - before: String - after: String - first: Int - last: Int - ): ProductCountableConnection + categories(before: String, after: String, first: Int, last: Int): CategoryCountableConnection + collections(before: String, after: String, first: Int, last: Int): CollectionCountableConnection + products(before: String, after: String, first: Int, last: Int): ProductCountableConnection countries: [CountryDisplay] translation(languageCode: LanguageCodeEnum!): VoucherTranslation } type VoucherAddCatalogues { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") voucher: Voucher discountErrors: [DiscountError!]! } type VoucherBulkDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") count: Int! discountErrors: [DiscountError!]! } @@ -6884,19 +5289,13 @@ type VoucherCountableEdge { } type VoucherCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") discountErrors: [DiscountError!]! voucher: Voucher } type VoucherDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") discountErrors: [DiscountError!]! voucher: Voucher } @@ -6935,10 +5334,7 @@ input VoucherInput { } type VoucherRemoveCatalogues { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") voucher: Voucher discountErrors: [DiscountError!]! } @@ -6966,10 +5362,7 @@ type VoucherTranslatableContent implements Node { } type VoucherTranslate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") translationErrors: [TranslationError!]! voucher: Voucher } @@ -6987,10 +5380,7 @@ enum VoucherTypeEnum { } type VoucherUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") discountErrors: [DiscountError!]! voucher: Voucher } @@ -7000,12 +5390,7 @@ type Warehouse implements Node { name: String! slug: String! companyName: String! - shippingZones( - before: String - after: String - first: Int - last: Int - ): ShippingZoneCountableConnection! + shippingZones(before: String, after: String, first: Int, last: Int): ShippingZoneCountableConnection! address: Address! email: String! } @@ -7033,10 +5418,7 @@ type WarehouseCountableEdge { } type WarehouseCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") warehouseErrors: [WarehouseError!]! warehouse: Warehouse } @@ -7051,10 +5433,7 @@ input WarehouseCreateInput { } type WarehouseDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") warehouseErrors: [WarehouseError!]! warehouse: Warehouse } @@ -7080,19 +5459,13 @@ input WarehouseFilterInput { } type WarehouseShippingZoneAssign { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") warehouseErrors: [WarehouseError!]! warehouse: Warehouse } type WarehouseShippingZoneUnassign { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") warehouseErrors: [WarehouseError!]! warehouse: Warehouse } @@ -7107,10 +5480,7 @@ input WarehouseSortingInput { } type WarehouseUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") warehouseErrors: [WarehouseError!]! warehouse: Warehouse } @@ -7130,10 +5500,7 @@ type Webhook implements Node { secretKey: String id: ID! events: [WebhookEvent!]! - serviceAccount: ServiceAccount! - @deprecated( - reason: "Use the `app` field instead. This field will be removed after 2020-07-31." - ) + serviceAccount: ServiceAccount! @deprecated(reason: "Use the `app` field instead. This field will be removed after 2020-07-31.") app: App! } @@ -7149,10 +5516,7 @@ type WebhookCountableEdge { } type WebhookCreate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") webhookErrors: [WebhookError!]! webhook: Webhook } @@ -7168,10 +5532,7 @@ input WebhookCreateInput { } type WebhookDelete { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") webhookErrors: [WebhookError!]! webhook: Webhook } @@ -7208,6 +5569,8 @@ enum WebhookEventTypeEnum { CUSTOMER_CREATED PRODUCT_CREATED CHECKOUT_QUANTITY_CHANGED + CHECKOUT_CREATED + CHECKOUT_UPDATED FULFILLMENT_CREATED } @@ -7228,6 +5591,8 @@ enum WebhookSampleEventTypeEnum { CUSTOMER_CREATED PRODUCT_CREATED CHECKOUT_QUANTITY_CHANGED + CHECKOUT_CREATED + CHECKOUT_UPDATED FULFILLMENT_CREATED } @@ -7244,10 +5609,7 @@ input WebhookSortingInput { } type WebhookUpdate { - errors: [Error!]! - @deprecated( - reason: "Use typed errors with error codes. This field will be removed after 2020-07-31." - ) + errors: [Error!]! @deprecated(reason: "Use typed errors with error codes. This field will be removed after 2020-07-31.") webhookErrors: [WebhookError!]! webhook: Webhook } @@ -7263,7 +5625,7 @@ input WebhookUpdateInput { } type Weight { - unit: String! + unit: WeightUnitsEnum! value: Float! } @@ -7278,18 +5640,7 @@ enum WeightUnitsEnum { scalar _Any -union _Entity = - Address - | User - | Group - | ServiceAccount - | App - | ProductVariant - | Product - | ProductType - | Collection - | Category - | ProductImage +union _Entity = Address | User | Group | ServiceAccount | App | ProductVariant | Product | ProductType | Collection | Category | ProductImage type _Service { sdl: String diff --git a/src/apps/components/InstalledApps/InstalledApps.tsx b/src/apps/components/InstalledApps/InstalledApps.tsx index b84d620db..8c307cbf1 100644 --- a/src/apps/components/InstalledApps/InstalledApps.tsx +++ b/src/apps/components/InstalledApps/InstalledApps.tsx @@ -47,7 +47,7 @@ const InstalledApps: React.FC = ({ header={ diff --git a/src/attributes/views/AttributeList/filters.ts b/src/attributes/views/AttributeList/filters.ts index 74c89a557..ac8a3a961 100644 --- a/src/attributes/views/AttributeList/filters.ts +++ b/src/attributes/views/AttributeList/filters.ts @@ -17,7 +17,7 @@ import { AttributeListUrlQueryParams } from "../../urls"; -export const PRODUCT_FILTERS_KEY = "productFilters"; +export const ATTRIBUTE_FILTERS_KEY = "attributeFilters"; export function getFilterOpts( params: AttributeListUrlFilters @@ -130,7 +130,7 @@ export const { deleteFilterTab, getFilterTabs, saveFilterTab -} = createFilterTabUtils(PRODUCT_FILTERS_KEY); +} = createFilterTabUtils(ATTRIBUTE_FILTERS_KEY); export const { areFiltersApplied, getActiveFilters } = createFilterUtils< AttributeListUrlQueryParams, diff --git a/src/auth/errors.ts b/src/auth/errors.ts index 4ced5f7a0..092f745d2 100644 --- a/src/auth/errors.ts +++ b/src/auth/errors.ts @@ -8,7 +8,14 @@ export enum JWTError { } export function isJwtError(error: GraphQLError): boolean { - return !!findValueInEnum(error.extensions.exception.code, JWTError); + let jwtError: boolean; + try { + jwtError = !!findValueInEnum(error.extensions.exception.code, JWTError); + } catch (e) { + jwtError = false; + } + + return jwtError; } export function isTokenExpired(error: GraphQLError): boolean { diff --git a/src/categories/views/CategoryDetails.tsx b/src/categories/views/CategoryDetails.tsx index a6e74799a..bdd3c13e6 100644 --- a/src/categories/views/CategoryDetails.tsx +++ b/src/categories/views/CategoryDetails.tsx @@ -285,7 +285,7 @@ export const CategoryDetails: React.FC = ({ /> - + = ({ children }) => { const intl = useIntl(); const [appState, dispatchAppState] = useAppState(); const { location } = useRouter(); + const [isNavigatorVisible, setNavigatorVisibility] = React.useState(false); const menuStructure = createMenuStructure(intl); const configurationMenu = createConfigurationMenu(intl); @@ -356,170 +359,184 @@ const AppLayout: React.FC = ({ children }) => { }; return ( - - -
-
- setDrawerState(false)} - open={isDrawerOpened} - small={!isMenuSmall} - > -
+ + + +
+
+ setDrawerState(false)} + open={isDrawerOpened} + small={!isMenuSmall} > - -
-
- +
-
- - -
-
- {appState.loading ? ( - - ) : ( -
- )} -
-
- -
-
setDrawerState(!isDrawerOpened)} - > - - - - -
-
-
-
- -
- - ) - } - classes={{ - avatar: classes.avatar - }} - className={classes.userChip} - label={ - <> - {user.email} - - - } - onClick={() => setMenuState(!isMenuOpened)} - data-test="userMenu" + +
+ +
+
+ + +
+
+ {appState.loading ? ( + + ) : ( +
+ )} +
+
+ +
+
setDrawerState(!isDrawerOpened)} + > + + + + +
+
+
+
+ - - {({ TransitionProps, placement }) => ( - - - setMenuState(false)} - mouseEvent="onClick" - > - - - - - - - - - - - - )} - + setNavigatorVisibility(true)} + /> +
+ + ) + } + classes={{ + avatar: classes.avatar + }} + className={classes.userChip} + label={ + <> + {user.email} + + + } + onClick={() => setMenuState(!isMenuOpened)} + data-test="userMenu" + /> + + {({ TransitionProps, placement }) => ( + + + setMenuState(false)} + mouseEvent="onClick" + > + + + + + + + + + + + + )} + +
-
- + +
+
+ {appState.error + ? appState.error === "unhandled" && ( + + ) + : children} +
-
- {appState.error - ? appState.error === "unhandled" && ( - - ) - : children} -
+
-
-
- - + + + ); }; diff --git a/src/components/Checkbox/Checkbox.tsx b/src/components/Checkbox/Checkbox.tsx index 529aef513..772800f6b 100644 --- a/src/components/Checkbox/Checkbox.tsx +++ b/src/components/Checkbox/Checkbox.tsx @@ -1,136 +1,25 @@ -import ButtonBase from "@material-ui/core/ButtonBase"; -import { CheckboxProps as MuiCheckboxProps } from "@material-ui/core/Checkbox"; -import { makeStyles } from "@material-ui/core/styles"; -import { fade } from "@material-ui/core/styles/colorManipulator"; -import classNames from "classnames"; +import MuiCheckbox, { + CheckboxProps as MuiCheckboxProps +} from "@material-ui/core/Checkbox"; import React from "react"; export type CheckboxProps = Omit< MuiCheckboxProps, - | "checkedIcon" - | "color" - | "icon" - | "indeterminateIcon" - | "classes" - | "onChange" - | "onClick" + "checkedIcon" | "color" | "icon" | "indeterminateIcon" | "classes" | "onClick" > & { disableClickPropagation?: boolean; - onChange?: (event: React.ChangeEvent) => void; }; -const useStyles = makeStyles( - theme => ({ - box: { - "&$checked": { - "&:before": { - background: theme.palette.primary.main, - color: theme.palette.background.paper, - content: '"\\2713"', - fontWeight: "bold", - textAlign: "center" - }, - borderColor: theme.palette.primary.main - }, - "&$disabled": { - borderColor: theme.palette.grey[200] - }, - "&$indeterminate": { - "&:before": { - background: theme.palette.primary.main, - height: 2, - top: 5 - }, - borderColor: theme.palette.primary.main - }, - "&:before": { - background: "rgba(0, 0, 0, 0)", - content: '""', - height: 14, - left: -1, - position: "absolute", - top: -1, - transition: theme.transitions.duration.short + "ms", - width: 14 - }, - - WebkitAppearance: "none", - border: `1px solid ${theme.palette.action.active}`, - boxSizing: "border-box", - cursor: "pointer", - height: 14, - outline: "0", - position: "relative", - userSelect: "none", - width: 14 - }, - checked: {}, - disabled: {}, - indeterminate: {}, - root: { - "&:hover": { - background: fade(theme.palette.primary.main, 0.1) - }, - alignSelf: "start", - borderRadius: "100%", - cursor: "pointer", - display: "flex", - height: 30, - justifyContent: "center", - margin: "5px 9px", - width: 30 - } - }), - { name: "Checkbox" } -); const Checkbox: React.FC = props => { - const { - checked, - className, - - disabled, - disableClickPropagation, - indeterminate, - onChange, - value, - name, - ...rest - } = props; - const classes = useStyles(props); - - const inputRef = React.useRef(null); - const handleClick = React.useCallback( - disableClickPropagation - ? event => { - event.stopPropagation(); - inputRef.current.click(); - } - : () => inputRef.current.click(), - [] - ); + const { disableClickPropagation, ...rest } = props; return ( - - - + onClick={ + disableClickPropagation ? event => event.stopPropagation() : undefined + } + /> ); }; Checkbox.displayName = "Checkbox"; diff --git a/src/components/ControlledCheckbox.tsx b/src/components/ControlledCheckbox.tsx index ebace41f9..fd4d57b45 100644 --- a/src/components/ControlledCheckbox.tsx +++ b/src/components/ControlledCheckbox.tsx @@ -1,8 +1,7 @@ +import Checkbox from "@material-ui/core/Checkbox"; import FormControlLabel from "@material-ui/core/FormControlLabel"; import React from "react"; -import Checkbox from "./Checkbox"; - interface ControlledCheckboxProps { className?: string; name: string; @@ -27,7 +26,6 @@ export const ControlledCheckbox: React.FC = ({ checked={checked} disabled={disabled} name={name} - disableClickPropagation onChange={() => onChange({ target: { name, value: !checked } })} /> } diff --git a/src/components/Navigator/Navigator.tsx b/src/components/Navigator/Navigator.tsx index 07fc647b8..569eede26 100644 --- a/src/components/Navigator/Navigator.tsx +++ b/src/components/Navigator/Navigator.tsx @@ -60,8 +60,12 @@ const useStyles = makeStyles( } ); -const Navigator: React.FC = () => { - const [visible, setVisible] = React.useState(false); +export interface NavigatorProps { + visible: boolean; + setVisibility: (state: boolean) => void; +} + +const Navigator: React.FC = ({ visible, setVisibility }) => { const input = React.useRef(null); const [query, mode, change, actions] = useQuickSearch(visible, input); const intl = useIntl(); @@ -76,7 +80,7 @@ const Navigator: React.FC = () => { React.useEffect(() => { hotkeys(navigatorHotkey, event => { event.preventDefault(); - setVisible(!visible); + setVisibility(!visible); }); if (cmp(APP_VERSION, "2.1.0") !== 1 && !notifiedAboutNavigator) { @@ -110,7 +114,7 @@ const Navigator: React.FC = () => { setVisible(false)} + onClose={() => setVisibility(false)} >
@@ -122,7 +126,7 @@ const Navigator: React.FC = () => { onSelect={(item: QuickSearchAction) => { const shouldRemainVisible = item.onClick(); if (!shouldRemainVisible) { - setVisible(false); + setVisibility(false); } }} onInputValueChange={value => diff --git a/src/components/NavigatorButton/NavigatorButton.stories.tsx b/src/components/NavigatorButton/NavigatorButton.stories.tsx new file mode 100644 index 000000000..95e7f0881 --- /dev/null +++ b/src/components/NavigatorButton/NavigatorButton.stories.tsx @@ -0,0 +1,12 @@ +import CardDecorator from "@saleor/storybook/CardDecorator"; +import Decorator from "@saleor/storybook/Decorator"; +import { storiesOf } from "@storybook/react"; +import React from "react"; + +import NavigatorButton from "./NavigatorButton"; + +storiesOf("Generics / NavigatorButton", module) + .addDecorator(Decorator) + .addDecorator(CardDecorator) + .add("mac", () => ) + .add("other", () => ); diff --git a/src/components/NavigatorButton/NavigatorButton.tsx b/src/components/NavigatorButton/NavigatorButton.tsx new file mode 100644 index 000000000..d35b87668 --- /dev/null +++ b/src/components/NavigatorButton/NavigatorButton.tsx @@ -0,0 +1,153 @@ +import navigatorIcon from "@assets/images/navigator.svg"; +import Grow from "@material-ui/core/Grow"; +import IconButton, { IconButtonProps } from "@material-ui/core/IconButton"; +import Paper from "@material-ui/core/Paper"; +import Popper from "@material-ui/core/Popper"; +import makeStyles from "@material-ui/core/styles/makeStyles"; +import classNames from "classnames"; +import React from "react"; +import ReactSVG from "react-inlinesvg"; +import { FormattedMessage } from "react-intl"; + +const useStyles = makeStyles( + theme => { + const triangle = (color: string, width: number) => ({ + borderBottom: `${width}px solid ${color}`, + borderLeft: `${width}px solid transparent`, + borderRight: `${width}px solid transparent`, + height: 0, + width: 0 + }); + + return { + keyTile: { + "&:first-child": { + marginLeft: theme.spacing() + }, + alignItems: "center", + background: theme.palette.background.default, + borderRadius: 8, + display: "inline-flex", + height: 32, + justifyContent: "center", + marginLeft: theme.spacing(0.5), + padding: theme.spacing(), + width: 32 + }, + keyTileLabel: { + verticalAlign: "middle" + }, + paper: { + "&:after": { + ...triangle(theme.palette.background.paper, 7), + content: "''", + left: theme.spacing(2) + 2, + position: "absolute", + top: -theme.spacing() + 1 + }, + "&:before": { + ...triangle(theme.palette.divider, 8), + content: "''", + left: theme.spacing(2) + 1, + position: "absolute", + top: -theme.spacing() + }, + border: `1px solid ${theme.palette.divider}`, + borderRadius: 6, + marginTop: theme.spacing(2), + padding: theme.spacing(2), + position: "relative" + }, + + root: { + "& path": { + color: theme.palette.primary.main + }, + "&:not(:hover)": { + backgroundColor: theme.palette.background.paper + }, + border: `1px solid ${theme.palette.divider}`, + height: 40, + marginRight: theme.spacing(2), + width: 40 + } + }; + }, + { + name: "NavigatorButton" + } +); + +export interface NavigatorButtonProps extends IconButtonProps { + isMac: boolean; +} + +const NavigatorButton: React.FC = ({ + className, + isMac, + ...props +}) => { + const classes = useStyles({}); + const helperTimer = React.useRef(null); + const [helperVisibility, setHelperVisibility] = React.useState(false); + const anchor = React.useRef(); + + const setHelper = () => { + helperTimer.current = setTimeout(() => setHelperVisibility(true), 2 * 1000); + }; + + const clearHelper = () => { + if (helperTimer.current) { + clearTimeout(helperTimer.current); + helperTimer.current = null; + } + setHelperVisibility(false); + }; + + return ( + <> + + + + + {({ TransitionProps, placement }) => ( + + + +
+ + {isMac ? "⌘" : "Ctrl"} + +
+
+ K +
+
+
+ )} +
+ + ); +}; + +NavigatorButton.displayName = "NavigatorButton"; +export default NavigatorButton; diff --git a/src/components/TableHead/TableHead.tsx b/src/components/TableHead/TableHead.tsx index 1a1d39602..f382fa1c7 100644 --- a/src/components/TableHead/TableHead.tsx +++ b/src/components/TableHead/TableHead.tsx @@ -28,23 +28,6 @@ const useStyles = makeStyles( cell: { padding: 0 }, - checkboxPartialSelect: { - "& input": { - "&:before": { - background: [theme.palette.background.paper, "!important"] as any, - border: `solid 1px ${theme.palette.primary.main}`, - content: "''" - }, - background: theme.palette.background.paper - }, - "&:after": { - background: theme.palette.primary.main, - content: "''", - height: 2, - position: "absolute", - width: 6 - } - }, checkboxSelected: { backgroundColor: fade(theme.palette.primary.main, 0.05) }, @@ -113,10 +96,7 @@ const TableHead: React.FC = props => { })} > selected && selected > 0 - })} + indeterminate={items && items.length > selected && selected > 0} checked={selected === 0 ? false : true} disabled={disabled} onChange={() => toggleAll(items, selected)} diff --git a/src/discounts/views/SaleList/filters.ts b/src/discounts/views/SaleList/filters.ts index 3a1e6c88b..7e40dfba0 100644 --- a/src/discounts/views/SaleList/filters.ts +++ b/src/discounts/views/SaleList/filters.ts @@ -117,4 +117,7 @@ export const { export const { areFiltersApplied, getActiveFilters } = createFilterUtils< SaleListUrlQueryParams, SaleListUrlFilters ->(SaleListUrlFiltersEnum); +>({ + ...SaleListUrlFiltersEnum, + ...SaleListUrlFiltersWithMultipleValues +}); diff --git a/src/discounts/views/VoucherList/filters.ts b/src/discounts/views/VoucherList/filters.ts index 27570299a..ff3623fe0 100644 --- a/src/discounts/views/VoucherList/filters.ts +++ b/src/discounts/views/VoucherList/filters.ts @@ -149,4 +149,7 @@ export const { export const { areFiltersApplied, getActiveFilters } = createFilterUtils< VoucherListUrlQueryParams, VoucherListUrlFilters ->(VoucherListUrlFiltersEnum); +>({ + ...VoucherListUrlFiltersEnum, + ...VoucherListUrlFiltersWithMultipleValues +}); diff --git a/src/fragments/permissionGroups.ts b/src/fragments/permissionGroups.ts index d16a0afbe..e2ea84ec2 100644 --- a/src/fragments/permissionGroups.ts +++ b/src/fragments/permissionGroups.ts @@ -33,6 +33,9 @@ export const permissionGroupDetailsFragment = gql` } users { ...StaffMemberFragment + avatar(size: 48) { + url + } } } `; diff --git a/src/fragments/staff.ts b/src/fragments/staff.ts index 4262563c8..edc469c7e 100644 --- a/src/fragments/staff.ts +++ b/src/fragments/staff.ts @@ -7,9 +7,6 @@ export const staffMemberFragment = gql` firstName isActive lastName - avatar { - url - } } `; export const staffMemberDetailsFragment = gql` @@ -25,5 +22,8 @@ export const staffMemberDetailsFragment = gql` code name } + avatar(size: 120) { + url + } } `; diff --git a/src/fragments/types/Product.ts b/src/fragments/types/Product.ts index 2d37388eb..dc8c1e5b0 100644 --- a/src/fragments/types/Product.ts +++ b/src/fragments/types/Product.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { AttributeInputTypeEnum } from "./../../types/globalTypes"; +import { AttributeInputTypeEnum, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL fragment: Product @@ -170,7 +170,7 @@ export interface Product_variants { export interface Product_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/fragments/types/ProductTypeDetailsFragment.ts b/src/fragments/types/ProductTypeDetailsFragment.ts index 87cd9d547..ecefce57b 100644 --- a/src/fragments/types/ProductTypeDetailsFragment.ts +++ b/src/fragments/types/ProductTypeDetailsFragment.ts @@ -2,6 +2,8 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. +import { WeightUnitsEnum } from "./../../types/globalTypes"; + // ==================================================== // GraphQL fragment: ProductTypeDetailsFragment // ==================================================== @@ -34,7 +36,7 @@ export interface ProductTypeDetailsFragment_variantAttributes { export interface ProductTypeDetailsFragment_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/fragments/types/ProductVariant.ts b/src/fragments/types/ProductVariant.ts index 709b2600f..b2295f03c 100644 --- a/src/fragments/types/ProductVariant.ts +++ b/src/fragments/types/ProductVariant.ts @@ -2,6 +2,8 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. +import { WeightUnitsEnum } from "./../../types/globalTypes"; + // ==================================================== // GraphQL fragment: ProductVariant // ==================================================== @@ -105,7 +107,7 @@ export interface ProductVariant_stocks { export interface ProductVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/fragments/types/ShippingMethodFragment.ts b/src/fragments/types/ShippingMethodFragment.ts index 0c33ded59..fb3c79e9d 100644 --- a/src/fragments/types/ShippingMethodFragment.ts +++ b/src/fragments/types/ShippingMethodFragment.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ShippingMethodTypeEnum } from "./../../types/globalTypes"; +import { WeightUnitsEnum, ShippingMethodTypeEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL fragment: ShippingMethodFragment @@ -16,7 +16,7 @@ export interface ShippingMethodFragment_minimumOrderPrice { export interface ShippingMethodFragment_minimumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -28,7 +28,7 @@ export interface ShippingMethodFragment_maximumOrderPrice { export interface ShippingMethodFragment_maximumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/fragments/types/ShippingZoneDetailsFragment.ts b/src/fragments/types/ShippingZoneDetailsFragment.ts index 13bf1a398..c55177fa9 100644 --- a/src/fragments/types/ShippingZoneDetailsFragment.ts +++ b/src/fragments/types/ShippingZoneDetailsFragment.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ShippingMethodTypeEnum } from "./../../types/globalTypes"; +import { WeightUnitsEnum, ShippingMethodTypeEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL fragment: ShippingZoneDetailsFragment @@ -22,7 +22,7 @@ export interface ShippingZoneDetailsFragment_shippingMethods_minimumOrderPrice { export interface ShippingZoneDetailsFragment_shippingMethods_minimumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -34,7 +34,7 @@ export interface ShippingZoneDetailsFragment_shippingMethods_maximumOrderPrice { export interface ShippingZoneDetailsFragment_shippingMethods_maximumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/fragments/types/StaffMemberDetailsFragment.ts b/src/fragments/types/StaffMemberDetailsFragment.ts index a52f00126..22f80c5d8 100644 --- a/src/fragments/types/StaffMemberDetailsFragment.ts +++ b/src/fragments/types/StaffMemberDetailsFragment.ts @@ -8,11 +8,6 @@ import { PermissionEnum } from "./../../types/globalTypes"; // GraphQL fragment: StaffMemberDetailsFragment // ==================================================== -export interface StaffMemberDetailsFragment_avatar { - __typename: "Image"; - url: string; -} - export interface StaffMemberDetailsFragment_permissionGroups { __typename: "Group"; id: string; @@ -26,6 +21,11 @@ export interface StaffMemberDetailsFragment_userPermissions { name: string; } +export interface StaffMemberDetailsFragment_avatar { + __typename: "Image"; + url: string; +} + export interface StaffMemberDetailsFragment { __typename: "User"; id: string; @@ -33,7 +33,7 @@ export interface StaffMemberDetailsFragment { firstName: string; isActive: boolean; lastName: string; - avatar: StaffMemberDetailsFragment_avatar | null; permissionGroups: (StaffMemberDetailsFragment_permissionGroups | null)[] | null; userPermissions: (StaffMemberDetailsFragment_userPermissions | null)[] | null; + avatar: StaffMemberDetailsFragment_avatar | null; } diff --git a/src/fragments/types/StaffMemberFragment.ts b/src/fragments/types/StaffMemberFragment.ts index f5098fcdf..118b747c1 100644 --- a/src/fragments/types/StaffMemberFragment.ts +++ b/src/fragments/types/StaffMemberFragment.ts @@ -6,11 +6,6 @@ // GraphQL fragment: StaffMemberFragment // ==================================================== -export interface StaffMemberFragment_avatar { - __typename: "Image"; - url: string; -} - export interface StaffMemberFragment { __typename: "User"; id: string; @@ -18,5 +13,4 @@ export interface StaffMemberFragment { firstName: string; isActive: boolean; lastName: string; - avatar: StaffMemberFragment_avatar | null; } diff --git a/src/fragments/types/WeightFragment.ts b/src/fragments/types/WeightFragment.ts index 7984fb6f3..2a9708b2b 100644 --- a/src/fragments/types/WeightFragment.ts +++ b/src/fragments/types/WeightFragment.ts @@ -2,12 +2,14 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. +import { WeightUnitsEnum } from "./../../types/globalTypes"; + // ==================================================== // GraphQL fragment: WeightFragment // ==================================================== export interface WeightFragment { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/icons/Checkbox.tsx b/src/icons/Checkbox.tsx new file mode 100644 index 000000000..174c99378 --- /dev/null +++ b/src/icons/Checkbox.tsx @@ -0,0 +1,18 @@ +import createSvgIcon from "@material-ui/icons/utils/createSvgIcon"; +import React from "react"; + +const Checkbox = createSvgIcon( + <> + + , + "Checkbox" +); + +export default Checkbox; diff --git a/src/icons/CheckboxChecked.tsx b/src/icons/CheckboxChecked.tsx new file mode 100644 index 000000000..63170dac3 --- /dev/null +++ b/src/icons/CheckboxChecked.tsx @@ -0,0 +1,17 @@ +import createSvgIcon from "@material-ui/icons/utils/createSvgIcon"; +import React from "react"; + +const CheckboxChecked = createSvgIcon( + <> + + + , + "CheckboxChecked" +); + +export default CheckboxChecked; diff --git a/src/icons/CheckboxIndeterminate.tsx b/src/icons/CheckboxIndeterminate.tsx new file mode 100644 index 000000000..8079e9b24 --- /dev/null +++ b/src/icons/CheckboxIndeterminate.tsx @@ -0,0 +1,19 @@ +import createSvgIcon from "@material-ui/icons/utils/createSvgIcon"; +import React from "react"; + +const CheckboxIndeterminate = createSvgIcon( + <> + + + , + "CheckboxIndeterminate" +); + +export default CheckboxIndeterminate; diff --git a/src/index.tsx b/src/index.tsx index f684c326c..9317abeea 100644 --- a/src/index.tsx +++ b/src/index.tsx @@ -1,4 +1,3 @@ -import Navigator from "@saleor/components/Navigator"; import useAppState from "@saleor/hooks/useAppState"; import { defaultDataIdFromObject, InMemoryCache } from "apollo-cache-inmemory"; import { ApolloClient } from "apollo-client"; @@ -139,7 +138,6 @@ const Routes: React.FC = () => { {isAuthenticated && !tokenAuthLoading && !tokenVerifyLoading ? ( - dispatchAppState({ diff --git a/src/misc.ts b/src/misc.ts index 933fcc916..6ab1a53d5 100644 --- a/src/misc.ts +++ b/src/misc.ts @@ -306,10 +306,10 @@ export function createHref(url: string) { interface AnyEvent { stopPropagation: () => void; } -export function stopPropagation(cb: () => void) { +export function stopPropagation(cb: (event?: AnyEvent) => void) { return (event: AnyEvent) => { event.stopPropagation(); - cb(); + cb(event); }; } diff --git a/src/permissionGroups/components/PermissionGroupMemberList/PermissionGroupMemberList.tsx b/src/permissionGroups/components/PermissionGroupMemberList/PermissionGroupMemberList.tsx index fc1448a9a..ec51ca259 100644 --- a/src/permissionGroups/components/PermissionGroupMemberList/PermissionGroupMemberList.tsx +++ b/src/permissionGroups/components/PermissionGroupMemberList/PermissionGroupMemberList.tsx @@ -52,8 +52,8 @@ const useStyles = makeStyles( width: 47 }, avatarDefault: { - "& p": { - color: "#fff", + "& div": { + color: theme.palette.primary.contrastText, lineHeight: "47px" }, background: theme.palette.primary.main, diff --git a/src/productTypes/fixtures.ts b/src/productTypes/fixtures.ts index 126fcdb47..50d1ff5fe 100644 --- a/src/productTypes/fixtures.ts +++ b/src/productTypes/fixtures.ts @@ -3,7 +3,7 @@ import { SearchProductTypes_search_edges_node_productAttributes } from "@saleor/searches/types/SearchProductTypes"; -import { AttributeInputTypeEnum } from "../types/globalTypes"; +import { AttributeInputTypeEnum, WeightUnitsEnum } from "../types/globalTypes"; import { ProductTypeDetails_productType } from "./types/ProductTypeDetails"; import { ProductTypeList_productTypes_edges_node } from "./types/ProductTypeList"; @@ -601,7 +601,7 @@ export const productType: ProductTypeDetails_productType = { ], weight: { __typename: "Weight", - unit: "kg", + unit: WeightUnitsEnum.KG, value: 7.82 } }; diff --git a/src/productTypes/types/AssignAttribute.ts b/src/productTypes/types/AssignAttribute.ts index 2e9d3fb4a..580c40eb3 100644 --- a/src/productTypes/types/AssignAttribute.ts +++ b/src/productTypes/types/AssignAttribute.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { AttributeAssignInput } from "./../../types/globalTypes"; +import { AttributeAssignInput, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: AssignAttribute @@ -42,7 +42,7 @@ export interface AssignAttribute_attributeAssign_productType_variantAttributes { export interface AssignAttribute_attributeAssign_productType_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/productTypes/types/ProductTypeAttributeReorder.ts b/src/productTypes/types/ProductTypeAttributeReorder.ts index 6d4ca443d..e7153d47b 100644 --- a/src/productTypes/types/ProductTypeAttributeReorder.ts +++ b/src/productTypes/types/ProductTypeAttributeReorder.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ReorderInput, AttributeTypeEnum } from "./../../types/globalTypes"; +import { ReorderInput, AttributeTypeEnum, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: ProductTypeAttributeReorder @@ -42,7 +42,7 @@ export interface ProductTypeAttributeReorder_productTypeReorderAttributes_produc export interface ProductTypeAttributeReorder_productTypeReorderAttributes_productType_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/productTypes/types/ProductTypeCreate.ts b/src/productTypes/types/ProductTypeCreate.ts index 5993bbb02..f980a1087 100644 --- a/src/productTypes/types/ProductTypeCreate.ts +++ b/src/productTypes/types/ProductTypeCreate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ProductTypeInput } from "./../../types/globalTypes"; +import { ProductTypeInput, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: ProductTypeCreate @@ -42,7 +42,7 @@ export interface ProductTypeCreate_productTypeCreate_productType_variantAttribut export interface ProductTypeCreate_productTypeCreate_productType_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/productTypes/types/ProductTypeDetails.ts b/src/productTypes/types/ProductTypeDetails.ts index c403f627d..71ad2aa4f 100644 --- a/src/productTypes/types/ProductTypeDetails.ts +++ b/src/productTypes/types/ProductTypeDetails.ts @@ -36,7 +36,7 @@ export interface ProductTypeDetails_productType_variantAttributes { export interface ProductTypeDetails_productType_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/productTypes/types/ProductTypeUpdate.ts b/src/productTypes/types/ProductTypeUpdate.ts index 58c66afe2..566314d02 100644 --- a/src/productTypes/types/ProductTypeUpdate.ts +++ b/src/productTypes/types/ProductTypeUpdate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ProductTypeInput } from "./../../types/globalTypes"; +import { ProductTypeInput, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: ProductTypeUpdate @@ -42,7 +42,7 @@ export interface ProductTypeUpdate_productTypeUpdate_productType_variantAttribut export interface ProductTypeUpdate_productTypeUpdate_productType_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/productTypes/types/UnassignAttribute.ts b/src/productTypes/types/UnassignAttribute.ts index b042fc6e3..056ecd287 100644 --- a/src/productTypes/types/UnassignAttribute.ts +++ b/src/productTypes/types/UnassignAttribute.ts @@ -2,6 +2,8 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. +import { WeightUnitsEnum } from "./../../types/globalTypes"; + // ==================================================== // GraphQL mutation operation: UnassignAttribute // ==================================================== @@ -40,7 +42,7 @@ export interface UnassignAttribute_attributeUnassign_productType_variantAttribut export interface UnassignAttribute_attributeUnassign_productType_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/components/ProductExportDialog/ProductExportDialog.stories.tsx b/src/products/components/ProductExportDialog/ProductExportDialog.stories.tsx index 734452efd..f81aead66 100644 --- a/src/products/components/ProductExportDialog/ProductExportDialog.stories.tsx +++ b/src/products/components/ProductExportDialog/ProductExportDialog.stories.tsx @@ -3,6 +3,7 @@ import { ExportErrorCode, ExportProductsInput } from "@saleor/types/globalTypes"; +import { warehouseList } from "@saleor/warehouses/fixtures"; import { storiesOf } from "@storybook/react"; import React from "react"; @@ -30,7 +31,8 @@ const props: ProductExportDialogProps = { all: 100, filter: 32 }, - selectedProducts: 18 + selectedProducts: 18, + warehouses: warehouseList }; storiesOf("Views / Products / Export / Export settings", module) diff --git a/src/products/components/ProductExportDialog/ProductExportDialog.tsx b/src/products/components/ProductExportDialog/ProductExportDialog.tsx index 32a1d218b..5f9581eeb 100644 --- a/src/products/components/ProductExportDialog/ProductExportDialog.tsx +++ b/src/products/components/ProductExportDialog/ProductExportDialog.tsx @@ -8,11 +8,11 @@ import ConfirmButton, { ConfirmButtonTransitionState } from "@saleor/components/ConfirmButton"; import makeCreatorSteps, { Step } from "@saleor/components/CreatorSteps"; -import Form from "@saleor/components/Form"; import { MultiAutocompleteChoiceType } from "@saleor/components/MultiAutocompleteSelectField"; import { ExportErrorFragment } from "@saleor/fragments/types/ExportErrorFragment"; -import { FormChange } from "@saleor/hooks/useForm"; +import useForm, { FormChange } from "@saleor/hooks/useForm"; import useModalDialogErrors from "@saleor/hooks/useModalDialogErrors"; +import useModalDialogOpen from "@saleor/hooks/useModalDialogOpen"; import useWizard from "@saleor/hooks/useWizard"; import { buttonMessages } from "@saleor/intl"; import { SearchAttributes_search_edges_node } from "@saleor/searches/types/SearchAttributes"; @@ -25,11 +25,13 @@ import { import getExportErrorMessage from "@saleor/utils/errors/export"; import { toggle } from "@saleor/utils/lists"; import { mapNodeToChoice } from "@saleor/utils/maps"; +import { WarehouseList_warehouses_edges_node } from "@saleor/warehouses/types/WarehouseList"; import React from "react"; import { FormattedMessage, useIntl } from "react-intl"; import ProductExportDialogInfo, { - attributeNamePrefix + attributeNamePrefix, + warehouseNamePrefix } from "./ProductExportDialogInfo"; import ProductExportDialogSettings, { ProductQuantity @@ -64,7 +66,8 @@ function useSteps(): Array> { const initialForm: ExportProductsInput = { exportInfo: { attributes: [], - fields: [] + fields: [], + warehouses: [] }, fileType: FileTypesEnum.CSV, scope: ExportScope.ALL @@ -78,6 +81,7 @@ export interface ProductExportDialogProps extends DialogProps, FetchMoreProps { errors: ExportErrorFragment[]; productQuantity: ProductQuantity; selectedProducts: number; + warehouses: WarehouseList_warehouses_edges_node[]; onFetch: (query: string) => void; onSubmit: (data: ExportProductsInput) => void; } @@ -91,6 +95,7 @@ const ProductExportDialog: React.FC = ({ onSubmit, open, selectedProducts, + warehouses, ...fetchMoreProps }) => { const [step, { next, prev, set: setStep }] = useWizard( @@ -104,121 +109,153 @@ const ProductExportDialog: React.FC = ({ const [selectedAttributes, setSelectedAttributes] = React.useState< MultiAutocompleteChoiceType[] >([]); + const { change, data, reset, submit } = useForm(initialForm, onSubmit); + + useModalDialogOpen(open, { + onClose: () => { + reset(); + setStep(ProductExportStep.INFO); + } + }); const attributeChoices = mapNodeToChoice(attributes); + const warehouseChoices = mapNodeToChoice(warehouses); + + const handleAttributeSelect: FormChange = event => { + const id = event.target.name.substr(attributeNamePrefix.length); + + change({ + target: { + name: "exportInfo", + value: { + ...data.exportInfo, + attributes: toggle(id, data.exportInfo.attributes, (a, b) => a === b) + } + } + }); + + const choice = attributeChoices.find(choice => choice.value === id); + + setSelectedAttributes( + toggle(choice, selectedAttributes, (a, b) => a.value === b.value) + ); + }; + + const handleWarehouseSelect: FormChange = event => + change({ + target: { + name: "exportInfo", + value: { + ...data.exportInfo, + warehouses: toggle( + event.target.name.substr(warehouseNamePrefix.length), + data.exportInfo.warehouses, + (a, b) => a === b + ) + } + } + }); + + const handleToggleAllWarehouses: FormChange = () => + change({ + target: { + name: "exportInfo", + value: { + ...data.exportInfo, + warehouses: + data.exportInfo.warehouses.length === warehouses.length + ? [] + : warehouses.map(warehouse => warehouse.id) + } + } + }); return ( -
- {({ change, data }) => { - const handleAttributeSelect: FormChange = event => { - const id = event.target.name.substr(attributeNamePrefix.length); + <> + + + + + + {step === ProductExportStep.INFO && ( + + )} + {step === ProductExportStep.SETTINGS && ( + + )} + - change({ - target: { - name: "exportInfo", - value: { - ...data.exportInfo, - attributes: toggle( - id, - data.exportInfo.attributes, - (a, b) => a === b - ) - } - } - }); + {notFormErrors.length > 0 && ( + + {notFormErrors.map(err => ( + + {getExportErrorMessage(err, intl)} + + ))} + + )} - const choice = attributeChoices.find(choice => choice.value === id); - - setSelectedAttributes( - toggle(choice, selectedAttributes, (a, b) => a.value === b.value) - ); - }; - - return ( - <> - - - - - - {step === ProductExportStep.INFO && ( - - )} - {step === ProductExportStep.SETTINGS && ( - - )} - - - {notFormErrors.length > 0 && ( - - {notFormErrors.map(err => ( - - {getExportErrorMessage(err, intl)} - - ))} - - )} - - - {step === ProductExportStep.INFO && ( - - )} - {step === ProductExportStep.SETTINGS && ( - - )} - {step === ProductExportStep.INFO && ( - - )} - {step === ProductExportStep.SETTINGS && ( - - - - )} - - - ); - }} -
+ + {step === ProductExportStep.INFO && ( + + )} + {step === ProductExportStep.SETTINGS && ( + + )} + {step === ProductExportStep.INFO && ( + + )} + {step === ProductExportStep.SETTINGS && ( + + + + )} + +
); }; diff --git a/src/products/components/ProductExportDialog/ProductExportDialogInfo.tsx b/src/products/components/ProductExportDialog/ProductExportDialogInfo.tsx index 991137265..c1cae4bb8 100644 --- a/src/products/components/ProductExportDialog/ProductExportDialogInfo.tsx +++ b/src/products/components/ProductExportDialog/ProductExportDialogInfo.tsx @@ -1,15 +1,15 @@ import Button from "@material-ui/core/Button"; -import Checkbox from "@material-ui/core/Checkbox"; import CircularProgress from "@material-ui/core/CircularProgress"; import FormControlLabel from "@material-ui/core/FormControlLabel"; import makeStyles from "@material-ui/core/styles/makeStyles"; import TextField from "@material-ui/core/TextField"; import Typography from "@material-ui/core/Typography"; import Accordion, { AccordionProps } from "@saleor/components/Accordion"; +import Checkbox from "@saleor/components/Checkbox"; import Chip from "@saleor/components/Chip"; import Hr from "@saleor/components/Hr"; import { MultiAutocompleteChoiceType } from "@saleor/components/MultiAutocompleteSelectField"; -import { ChangeEvent } from "@saleor/hooks/useForm"; +import { ChangeEvent, FormChange } from "@saleor/hooks/useForm"; import useSearchQuery from "@saleor/hooks/useSearchQuery"; import { sectionNames } from "@saleor/intl"; import { FetchMoreProps } from "@saleor/types"; @@ -22,9 +22,18 @@ import React from "react"; import { useIntl } from "react-intl"; import { FormattedMessage } from "react-intl"; +import useProductExportFieldMessages from "./messages"; + export const attributeNamePrefix = "attribute-"; +export const warehouseNamePrefix = "warehouse-"; const maxChips = 4; +const inventoryFields = [ + ProductFieldEnum.PRODUCT_WEIGHT, + ProductFieldEnum.VARIANT_SKU, + ProductFieldEnum.VARIANT_WEIGHT +]; + const useStyles = makeStyles( theme => ({ accordion: { @@ -45,12 +54,23 @@ const useStyles = makeStyles( marginBottom: theme.spacing(3), marginTop: theme.spacing(3) }, + hrWarehouses: { + marginBottom: theme.spacing(3), + marginTop: theme.spacing(1) + }, label: { "&&": { overflow: "visible" }, + "&:first-of-type": { + paddingTop: 0 + }, + "&:not(:last-of-type)": { + borderBottom: `1px solid ${theme.palette.divider}` + }, justifyContent: "space-between", margin: theme.spacing(0), + padding: theme.spacing(1, 0), width: "100%" }, loadMoreContainer: { @@ -62,8 +82,14 @@ const useStyles = makeStyles( display: "inline-block", marginBottom: theme.spacing() }, + optionLabel: { + marginLeft: 0 + }, quickPeekContainer: { marginBottom: theme.spacing(-1) + }, + warehousesLabel: { + marginBottom: theme.spacing(2) } }), { @@ -80,12 +106,14 @@ const Option: React.FC<{ return ( @@ -104,66 +132,7 @@ const FieldAccordion: React.FC void; }> = ({ data, fields, onChange, onToggleAll, ...props }) => { const classes = useStyles({}); - const intl = useIntl(); - - const fieldNames: Record = { - [ProductFieldEnum.CATEGORY]: intl.formatMessage({ - defaultMessage: "Category", - description: "product field" - }), - [ProductFieldEnum.CHARGE_TAXES]: intl.formatMessage({ - defaultMessage: "Charge Taxes", - description: "product field" - }), - [ProductFieldEnum.COLLECTIONS]: intl.formatMessage({ - defaultMessage: "Collections", - description: "product field" - }), - [ProductFieldEnum.COST_PRICE]: intl.formatMessage({ - defaultMessage: "Cost Price", - description: "product field" - }), - [ProductFieldEnum.DESCRIPTION]: intl.formatMessage({ - defaultMessage: "Description", - description: "product field" - }), - [ProductFieldEnum.NAME]: intl.formatMessage({ - defaultMessage: "Name", - description: "product field" - }), - [ProductFieldEnum.PRODUCT_IMAGES]: intl.formatMessage({ - defaultMessage: "Product Images", - description: "product field" - }), - [ProductFieldEnum.PRODUCT_TYPE]: intl.formatMessage({ - defaultMessage: "Type", - description: "product field" - }), - [ProductFieldEnum.PRODUCT_WEIGHT]: intl.formatMessage({ - defaultMessage: "Weight", - description: "product field" - }), - [ProductFieldEnum.VARIANT_IMAGES]: intl.formatMessage({ - defaultMessage: "Variant Images", - description: "product field" - }), - [ProductFieldEnum.VARIANT_PRICE]: intl.formatMessage({ - defaultMessage: "Variant Price", - description: "product field" - }), - [ProductFieldEnum.VARIANT_SKU]: intl.formatMessage({ - defaultMessage: "SKU", - description: "product field" - }), - [ProductFieldEnum.VARIANT_WEIGHT]: intl.formatMessage({ - defaultMessage: "Variant Weight", - description: "product field" - }), - [ProductFieldEnum.VISIBLE]: intl.formatMessage({ - defaultMessage: "Visibility", - description: "product field" - }) - }; + const getFieldLabel = useProductExportFieldMessages(); const selectedAll = fields.every(field => data.exportInfo.fields.includes(field) @@ -181,7 +150,7 @@ const FieldAccordion: React.FC ( onChange({ target: { @@ -190,6 +159,7 @@ const FieldAccordion: React.FC ))} {selectedFields.length > maxChips && ( @@ -225,7 +195,7 @@ const FieldAccordion: React.FC - {fieldNames[field]} + {getFieldLabel(field)} ))} @@ -234,11 +204,14 @@ const FieldAccordion: React.FC void; - onChange: (event: ChangeEvent) => void; + onAttrtibuteSelect: FormChange; + onWarehouseSelect: FormChange; + onChange: FormChange; onFetch: (query: string) => void; + onSelectAllWarehouses: FormChange; } const ProductExportDialogInfo: React.FC = ({ @@ -247,14 +220,18 @@ const ProductExportDialogInfo: React.FC = ({ hasMore, selectedAttributes, loading, + warehouses, onAttrtibuteSelect, + onWarehouseSelect, onChange, onFetch, - onFetchMore + onFetchMore, + onSelectAllWarehouses }) => { const classes = useStyles({}); const intl = useIntl(); const [query, onQueryChange] = useSearchQuery(onFetch); + const getFieldLabel = useProductExportFieldMessages(); const handleFieldChange = (event: ChangeEvent) => onChange({ @@ -289,6 +266,12 @@ const ProductExportDialogInfo: React.FC = ({ } }); + const selectedInventoryFields = data.exportInfo.fields.filter(field => + inventoryFields.includes(field) + ); + const selectedAllInventoryFields = + selectedInventoryFields.length === inventoryFields.length; + return ( <> @@ -331,6 +314,7 @@ const ProductExportDialogInfo: React.FC = ({ } }) } + key={attribute.value} /> ))} {selectedAttributes.length > maxChips && ( @@ -408,22 +392,134 @@ const ProductExportDialogInfo: React.FC = ({ onToggleAll={handleToggleAllFields} data-test="financial" /> - 0 || + selectedInventoryFields.length > 0) && ( +
+ {selectedInventoryFields.slice(0, maxChips).map(field => ( + + onChange({ + target: { + name: field, + value: false + } + }) + } + /> + ))} + {data.exportInfo.warehouses + .slice(0, maxChips - selectedInventoryFields.length) + .map(warehouseId => ( + warehouse.value === warehouseId + ).label + } + onClose={() => + onWarehouseSelect({ + target: { + name: warehouseNamePrefix + warehouseId, + value: undefined + } + }) + } + /> + ))} + {data.exportInfo.warehouses.length + + selectedInventoryFields.length > + maxChips && ( + + + + )} +
+ ) + } data-test="inventory" - /> + > +
+ + {inventoryFields.map(field => ( + + ))} +
+
+ + + +
+ +
+
+ + + + {warehouses.map(warehouse => ( + + ))} + messages[field]; +} + +export default useProductExportFieldMessages; diff --git a/src/products/components/ProductUpdatePage/ProductUpdatePage.tsx b/src/products/components/ProductUpdatePage/ProductUpdatePage.tsx index 00cd8e1ce..f0efcfd24 100644 --- a/src/products/components/ProductUpdatePage/ProductUpdatePage.tsx +++ b/src/products/components/ProductUpdatePage/ProductUpdatePage.tsx @@ -167,23 +167,33 @@ export const ProductUpdatePage: React.FC = ({ const hasVariants = maybe(() => product.productType.hasVariants, false); const handleSubmit = (data: ProductUpdatePageFormData) => { - const dataStocks = stocks.map(stock => stock.id); - const variantStocks = product.variants[0].stocks.map( - stock => stock.warehouse.id - ); - const stockDiff = diff(variantStocks, dataStocks); + if (product.productType.hasVariants) { + onSubmit({ + ...data, + addStocks: [], + attributes, + removeStocks: [], + updateStocks: [] + }); + } else { + const dataStocks = stocks.map(stock => stock.id); + const variantStocks = product.variants[0]?.stocks.map( + stock => stock.warehouse.id + ); + const stockDiff = diff(variantStocks, dataStocks); - onSubmit({ - ...data, - addStocks: stocks.filter(stock => - stockDiff.added.some(addedStock => addedStock === stock.id) - ), - attributes, - removeStocks: stockDiff.removed, - updateStocks: stocks.filter( - stock => !stockDiff.added.some(addedStock => addedStock === stock.id) - ) - }); + onSubmit({ + ...data, + addStocks: stocks.filter(stock => + stockDiff.added.some(addedStock => addedStock === stock.id) + ), + attributes, + removeStocks: stockDiff.removed, + updateStocks: stocks.filter( + stock => !stockDiff.added.some(addedStock => addedStock === stock.id) + ) + }); + } }; return ( diff --git a/src/products/fixtures.ts b/src/products/fixtures.ts index 62026802c..688acd85e 100644 --- a/src/products/fixtures.ts +++ b/src/products/fixtures.ts @@ -1,5 +1,8 @@ import { ProductVariant } from "@saleor/fragments/types/ProductVariant"; -import { AttributeInputTypeEnum } from "@saleor/types/globalTypes"; +import { + AttributeInputTypeEnum, + WeightUnitsEnum +} from "@saleor/types/globalTypes"; import { warehouseList } from "@saleor/warehouses/fixtures"; import { content } from "../storybook/stories/components/RichTextEditor"; @@ -281,7 +284,7 @@ export const product: ( trackInventory: true, weight: { __typename: "Weight", - unit: "kg", + unit: WeightUnitsEnum.KG, value: 3 } }, @@ -316,14 +319,14 @@ export const product: ( trackInventory: false, weight: { __typename: "Weight", - unit: "kg", + unit: WeightUnitsEnum.KG, value: 4 } } ], weight: { __typename: "Weight", - unit: "kg", + unit: WeightUnitsEnum.KG, value: 5 } }); @@ -1672,7 +1675,7 @@ export const variant = (placeholderImage: string): ProductVariant => ({ trackInventory: true, weight: { __typename: "Weight", - unit: "kg", + unit: WeightUnitsEnum.KG, value: 6 } }); diff --git a/src/products/index.tsx b/src/products/index.tsx index 12c1382d4..46b4df70d 100644 --- a/src/products/index.tsx +++ b/src/products/index.tsx @@ -52,7 +52,10 @@ const ProductUpdate: React.FC> = ({ match }) => { return ( ); }; diff --git a/src/products/types/ProductCreate.ts b/src/products/types/ProductCreate.ts index 44ebccfc7..bdf72cced 100644 --- a/src/products/types/ProductCreate.ts +++ b/src/products/types/ProductCreate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { AttributeValueInput, SeoInput, StockInput, ProductErrorCode, AttributeInputTypeEnum } from "./../../types/globalTypes"; +import { AttributeValueInput, SeoInput, StockInput, ProductErrorCode, AttributeInputTypeEnum, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: ProductCreate @@ -176,7 +176,7 @@ export interface ProductCreate_productCreate_product_variants { export interface ProductCreate_productCreate_product_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/types/ProductDetails.ts b/src/products/types/ProductDetails.ts index 936925a36..c5292b43f 100644 --- a/src/products/types/ProductDetails.ts +++ b/src/products/types/ProductDetails.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { AttributeInputTypeEnum } from "./../../types/globalTypes"; +import { AttributeInputTypeEnum, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL query operation: ProductDetails @@ -170,7 +170,7 @@ export interface ProductDetails_product_variants { export interface ProductDetails_product_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/types/ProductImageCreate.ts b/src/products/types/ProductImageCreate.ts index a816e820b..b9b79f8ba 100644 --- a/src/products/types/ProductImageCreate.ts +++ b/src/products/types/ProductImageCreate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ProductErrorCode, AttributeInputTypeEnum } from "./../../types/globalTypes"; +import { ProductErrorCode, AttributeInputTypeEnum, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: ProductImageCreate @@ -176,7 +176,7 @@ export interface ProductImageCreate_productImageCreate_product_variants { export interface ProductImageCreate_productImageCreate_product_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/types/ProductImageUpdate.ts b/src/products/types/ProductImageUpdate.ts index 0c8a40dd7..a207ae2b1 100644 --- a/src/products/types/ProductImageUpdate.ts +++ b/src/products/types/ProductImageUpdate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ProductErrorCode, AttributeInputTypeEnum } from "./../../types/globalTypes"; +import { ProductErrorCode, AttributeInputTypeEnum, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: ProductImageUpdate @@ -176,7 +176,7 @@ export interface ProductImageUpdate_productImageUpdate_product_variants { export interface ProductImageUpdate_productImageUpdate_product_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/types/ProductUpdate.ts b/src/products/types/ProductUpdate.ts index 6a1192164..96c52679a 100644 --- a/src/products/types/ProductUpdate.ts +++ b/src/products/types/ProductUpdate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { AttributeValueInput, SeoInput, ProductErrorCode, AttributeInputTypeEnum } from "./../../types/globalTypes"; +import { AttributeValueInput, SeoInput, ProductErrorCode, AttributeInputTypeEnum, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: ProductUpdate @@ -176,7 +176,7 @@ export interface ProductUpdate_productUpdate_product_variants { export interface ProductUpdate_productUpdate_product_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/types/ProductVariantDetails.ts b/src/products/types/ProductVariantDetails.ts index 7ee7eda80..fa14f8aaa 100644 --- a/src/products/types/ProductVariantDetails.ts +++ b/src/products/types/ProductVariantDetails.ts @@ -2,6 +2,8 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. +import { WeightUnitsEnum } from "./../../types/globalTypes"; + // ==================================================== // GraphQL query operation: ProductVariantDetails // ==================================================== @@ -105,7 +107,7 @@ export interface ProductVariantDetails_productVariant_stocks { export interface ProductVariantDetails_productVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/types/SimpleProductUpdate.ts b/src/products/types/SimpleProductUpdate.ts index 8851d67e3..ec0f06ad3 100644 --- a/src/products/types/SimpleProductUpdate.ts +++ b/src/products/types/SimpleProductUpdate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { AttributeValueInput, ProductVariantInput, SeoInput, StockInput, ProductErrorCode, AttributeInputTypeEnum, StockErrorCode } from "./../../types/globalTypes"; +import { AttributeValueInput, ProductVariantInput, SeoInput, StockInput, ProductErrorCode, AttributeInputTypeEnum, WeightUnitsEnum, StockErrorCode } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: SimpleProductUpdate @@ -176,7 +176,7 @@ export interface SimpleProductUpdate_productUpdate_product_variants { export interface SimpleProductUpdate_productUpdate_product_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -314,7 +314,7 @@ export interface SimpleProductUpdate_productVariantUpdate_productVariant_stocks export interface SimpleProductUpdate_productVariantUpdate_productVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -445,7 +445,7 @@ export interface SimpleProductUpdate_productVariantStocksCreate_productVariant_s export interface SimpleProductUpdate_productVariantStocksCreate_productVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -575,7 +575,7 @@ export interface SimpleProductUpdate_productVariantStocksDelete_productVariant_s export interface SimpleProductUpdate_productVariantStocksDelete_productVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -706,7 +706,7 @@ export interface SimpleProductUpdate_productVariantStocksUpdate_productVariant_s export interface SimpleProductUpdate_productVariantStocksUpdate_productVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/types/VariantCreate.ts b/src/products/types/VariantCreate.ts index f9bd6a80a..e469ba5d0 100644 --- a/src/products/types/VariantCreate.ts +++ b/src/products/types/VariantCreate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ProductVariantCreateInput, ProductErrorCode } from "./../../types/globalTypes"; +import { ProductVariantCreateInput, ProductErrorCode, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: VariantCreate @@ -113,7 +113,7 @@ export interface VariantCreate_productVariantCreate_productVariant_stocks { export interface VariantCreate_productVariantCreate_productVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/types/VariantImageAssign.ts b/src/products/types/VariantImageAssign.ts index 33e8ba952..b6d39774e 100644 --- a/src/products/types/VariantImageAssign.ts +++ b/src/products/types/VariantImageAssign.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ProductErrorCode } from "./../../types/globalTypes"; +import { ProductErrorCode, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: VariantImageAssign @@ -113,7 +113,7 @@ export interface VariantImageAssign_variantImageAssign_productVariant_stocks { export interface VariantImageAssign_variantImageAssign_productVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/types/VariantImageUnassign.ts b/src/products/types/VariantImageUnassign.ts index 8a4b21ced..acc83d810 100644 --- a/src/products/types/VariantImageUnassign.ts +++ b/src/products/types/VariantImageUnassign.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ProductErrorCode } from "./../../types/globalTypes"; +import { ProductErrorCode, WeightUnitsEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: VariantImageUnassign @@ -113,7 +113,7 @@ export interface VariantImageUnassign_variantImageUnassign_productVariant_stocks export interface VariantImageUnassign_variantImageUnassign_productVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/types/VariantUpdate.ts b/src/products/types/VariantUpdate.ts index 107c0a3c2..4858e750a 100644 --- a/src/products/types/VariantUpdate.ts +++ b/src/products/types/VariantUpdate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { StockInput, AttributeValueInput, ProductErrorCode, StockErrorCode } from "./../../types/globalTypes"; +import { StockInput, AttributeValueInput, ProductErrorCode, WeightUnitsEnum, StockErrorCode } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: VariantUpdate @@ -113,7 +113,7 @@ export interface VariantUpdate_productVariantUpdate_productVariant_stocks { export interface VariantUpdate_productVariantUpdate_productVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -244,7 +244,7 @@ export interface VariantUpdate_productVariantStocksUpdate_productVariant_stocks export interface VariantUpdate_productVariantStocksUpdate_productVariant_weight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/products/views/ProductList/ProductList.tsx b/src/products/views/ProductList/ProductList.tsx index 8e9089ed3..0f55ed6c0 100644 --- a/src/products/views/ProductList/ProductList.tsx +++ b/src/products/views/ProductList/ProductList.tsx @@ -39,6 +39,7 @@ import { ListViews } from "@saleor/types"; import createDialogActionHandlers from "@saleor/utils/handlers/dialogActionHandlers"; import createFilterHandlers from "@saleor/utils/handlers/filterHandlers"; import { getSortUrlVariables } from "@saleor/utils/sort"; +import { useWarehouseList } from "@saleor/warehouses/queries"; import React from "react"; import { FormattedMessage, useIntl } from "react-intl"; @@ -124,6 +125,11 @@ export const ProductList: React.FC = ({ params }) => { first: 10 } }); + const warehouses = useWarehouseList({ + variables: { + first: 100 + } + }); React.useEffect( () => @@ -551,6 +557,11 @@ export const ProductList: React.FC = ({ params }) => { filter: data?.products.totalCount }} selectedProducts={listElements.length} + warehouses={ + warehouses.data?.warehouses.edges.map( + edge => edge.node + ) || [] + } onClose={closeModal} onSubmit={data => exportProducts({ diff --git a/src/products/views/ProductList/filters.ts b/src/products/views/ProductList/filters.ts index cc7c7f7ec..44f6701d6 100644 --- a/src/products/views/ProductList/filters.ts +++ b/src/products/views/ProductList/filters.ts @@ -41,6 +41,7 @@ import { } from "../../../utils/filters"; import { ProductListUrlFilters, + ProductListUrlFiltersAsDictWithMultipleValues, ProductListUrlFiltersEnum, ProductListUrlFiltersWithMultipleValues, ProductListUrlQueryParams @@ -295,4 +296,8 @@ export const { export const { areFiltersApplied, getActiveFilters } = createFilterUtils< ProductListUrlQueryParams, ProductListUrlFilters ->(ProductListUrlFiltersEnum); +>({ + ...ProductListUrlFiltersEnum, + ...ProductListUrlFiltersWithMultipleValues, + ...ProductListUrlFiltersAsDictWithMultipleValues +}); diff --git a/src/shipping/fixtures.ts b/src/shipping/fixtures.ts index 123831135..209d6c32b 100644 --- a/src/shipping/fixtures.ts +++ b/src/shipping/fixtures.ts @@ -1,7 +1,7 @@ import { ShippingZoneDetailsFragment } from "@saleor/fragments/types/ShippingZoneDetailsFragment"; import { ShippingZoneFragment } from "@saleor/fragments/types/ShippingZoneFragment"; -import { ShippingMethodTypeEnum } from "../types/globalTypes"; +import { ShippingMethodTypeEnum, WeightUnitsEnum } from "../types/globalTypes"; export const shippingZones: ShippingZoneFragment[] = [ { @@ -1554,7 +1554,7 @@ export const shippingZone: ShippingZoneDetailsFragment = { maximumOrderPrice: null, maximumOrderWeight: { __typename: "Weight", - unit: "kg", + unit: WeightUnitsEnum.KG, value: 80 }, minimumOrderPrice: { @@ -1564,7 +1564,7 @@ export const shippingZone: ShippingZoneDetailsFragment = { }, minimumOrderWeight: { __typename: "Weight", - unit: "kg", + unit: WeightUnitsEnum.KG, value: 0 }, name: "DB Schenker", @@ -1587,7 +1587,7 @@ export const shippingZone: ShippingZoneDetailsFragment = { }, minimumOrderWeight: { __typename: "Weight", - unit: "kg", + unit: WeightUnitsEnum.KG, value: 0 }, name: "Registred priority", @@ -1610,7 +1610,7 @@ export const shippingZone: ShippingZoneDetailsFragment = { }, minimumOrderWeight: { __typename: "Weight", - unit: "kg", + unit: WeightUnitsEnum.KG, value: 0 }, @@ -1634,7 +1634,7 @@ export const shippingZone: ShippingZoneDetailsFragment = { }, minimumOrderWeight: { __typename: "Weight", - unit: "kg", + unit: WeightUnitsEnum.KG, value: 0 }, name: "DHL", diff --git a/src/shipping/types/CreateShippingRate.ts b/src/shipping/types/CreateShippingRate.ts index 7a29f3395..b1a8d9b95 100644 --- a/src/shipping/types/CreateShippingRate.ts +++ b/src/shipping/types/CreateShippingRate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ShippingPriceInput, ShippingErrorCode, ShippingMethodTypeEnum } from "./../../types/globalTypes"; +import { ShippingPriceInput, ShippingErrorCode, WeightUnitsEnum, ShippingMethodTypeEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: CreateShippingRate @@ -28,7 +28,7 @@ export interface CreateShippingRate_shippingPriceCreate_shippingZone_shippingMet export interface CreateShippingRate_shippingPriceCreate_shippingZone_shippingMethods_minimumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -40,7 +40,7 @@ export interface CreateShippingRate_shippingPriceCreate_shippingZone_shippingMet export interface CreateShippingRate_shippingPriceCreate_shippingZone_shippingMethods_maximumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/shipping/types/DeleteShippingRate.ts b/src/shipping/types/DeleteShippingRate.ts index d3fafa9b6..c5d02a026 100644 --- a/src/shipping/types/DeleteShippingRate.ts +++ b/src/shipping/types/DeleteShippingRate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ShippingErrorCode, ShippingMethodTypeEnum } from "./../../types/globalTypes"; +import { ShippingErrorCode, WeightUnitsEnum, ShippingMethodTypeEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: DeleteShippingRate @@ -28,7 +28,7 @@ export interface DeleteShippingRate_shippingPriceDelete_shippingZone_shippingMet export interface DeleteShippingRate_shippingPriceDelete_shippingZone_shippingMethods_minimumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -40,7 +40,7 @@ export interface DeleteShippingRate_shippingPriceDelete_shippingZone_shippingMet export interface DeleteShippingRate_shippingPriceDelete_shippingZone_shippingMethods_maximumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/shipping/types/ShippingZone.ts b/src/shipping/types/ShippingZone.ts index 091776cd3..bfde35cbb 100644 --- a/src/shipping/types/ShippingZone.ts +++ b/src/shipping/types/ShippingZone.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ShippingMethodTypeEnum } from "./../../types/globalTypes"; +import { WeightUnitsEnum, ShippingMethodTypeEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL query operation: ShippingZone @@ -22,7 +22,7 @@ export interface ShippingZone_shippingZone_shippingMethods_minimumOrderPrice { export interface ShippingZone_shippingZone_shippingMethods_minimumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -34,7 +34,7 @@ export interface ShippingZone_shippingZone_shippingMethods_maximumOrderPrice { export interface ShippingZone_shippingZone_shippingMethods_maximumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/shipping/types/UpdateShippingRate.ts b/src/shipping/types/UpdateShippingRate.ts index 88aa63cb4..880203eef 100644 --- a/src/shipping/types/UpdateShippingRate.ts +++ b/src/shipping/types/UpdateShippingRate.ts @@ -2,7 +2,7 @@ /* eslint-disable */ // This file was automatically generated and should not be edited. -import { ShippingPriceInput, ShippingErrorCode, ShippingMethodTypeEnum } from "./../../types/globalTypes"; +import { ShippingPriceInput, ShippingErrorCode, WeightUnitsEnum, ShippingMethodTypeEnum } from "./../../types/globalTypes"; // ==================================================== // GraphQL mutation operation: UpdateShippingRate @@ -22,7 +22,7 @@ export interface UpdateShippingRate_shippingPriceUpdate_shippingMethod_minimumOr export interface UpdateShippingRate_shippingPriceUpdate_shippingMethod_minimumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } @@ -34,7 +34,7 @@ export interface UpdateShippingRate_shippingPriceUpdate_shippingMethod_maximumOr export interface UpdateShippingRate_shippingPriceUpdate_shippingMethod_maximumOrderWeight { __typename: "Weight"; - unit: string; + unit: WeightUnitsEnum; value: number; } diff --git a/src/staff/components/StaffList/StaffList.tsx b/src/staff/components/StaffList/StaffList.tsx index e00898098..2f60804de 100644 --- a/src/staff/components/StaffList/StaffList.tsx +++ b/src/staff/components/StaffList/StaffList.tsx @@ -38,8 +38,8 @@ const useStyles = makeStyles( width: 47 }, avatarDefault: { - "& p": { - color: "#fff", + "& div": { + color: theme.palette.primary.contrastText, lineHeight: "47px" }, background: theme.palette.primary.main, diff --git a/src/staff/components/StaffProperties/StaffProperties.tsx b/src/staff/components/StaffProperties/StaffProperties.tsx index 1fa153f4d..1a2b10f63 100644 --- a/src/staff/components/StaffProperties/StaffProperties.tsx +++ b/src/staff/components/StaffProperties/StaffProperties.tsx @@ -35,7 +35,7 @@ const useStyles = makeStyles( width: 120 }, avatarDefault: { - "& p": { + "& div": { color: "#fff", fontSize: 35, fontWeight: "bold", diff --git a/src/staff/queries.ts b/src/staff/queries.ts index b8a86103c..4c2c6ef0e 100644 --- a/src/staff/queries.ts +++ b/src/staff/queries.ts @@ -34,6 +34,9 @@ const staffList = gql` cursor node { ...StaffMemberFragment + avatar(size: 48) { + url + } } } pageInfo { diff --git a/src/staff/types/StaffMemberAdd.ts b/src/staff/types/StaffMemberAdd.ts index d42e80dcf..d5b176cff 100644 --- a/src/staff/types/StaffMemberAdd.ts +++ b/src/staff/types/StaffMemberAdd.ts @@ -14,11 +14,6 @@ export interface StaffMemberAdd_staffCreate_errors { field: string | null; } -export interface StaffMemberAdd_staffCreate_user_avatar { - __typename: "Image"; - url: string; -} - export interface StaffMemberAdd_staffCreate_user_permissionGroups { __typename: "Group"; id: string; @@ -32,6 +27,11 @@ export interface StaffMemberAdd_staffCreate_user_userPermissions { name: string; } +export interface StaffMemberAdd_staffCreate_user_avatar { + __typename: "Image"; + url: string; +} + export interface StaffMemberAdd_staffCreate_user { __typename: "User"; id: string; @@ -39,9 +39,9 @@ export interface StaffMemberAdd_staffCreate_user { firstName: string; isActive: boolean; lastName: string; - avatar: StaffMemberAdd_staffCreate_user_avatar | null; permissionGroups: (StaffMemberAdd_staffCreate_user_permissionGroups | null)[] | null; userPermissions: (StaffMemberAdd_staffCreate_user_userPermissions | null)[] | null; + avatar: StaffMemberAdd_staffCreate_user_avatar | null; } export interface StaffMemberAdd_staffCreate { diff --git a/src/staff/types/StaffMemberDetails.ts b/src/staff/types/StaffMemberDetails.ts index 1935e7461..2ec999c1a 100644 --- a/src/staff/types/StaffMemberDetails.ts +++ b/src/staff/types/StaffMemberDetails.ts @@ -8,11 +8,6 @@ import { PermissionEnum } from "./../../types/globalTypes"; // GraphQL query operation: StaffMemberDetails // ==================================================== -export interface StaffMemberDetails_user_avatar { - __typename: "Image"; - url: string; -} - export interface StaffMemberDetails_user_permissionGroups { __typename: "Group"; id: string; @@ -26,6 +21,11 @@ export interface StaffMemberDetails_user_userPermissions { name: string; } +export interface StaffMemberDetails_user_avatar { + __typename: "Image"; + url: string; +} + export interface StaffMemberDetails_user { __typename: "User"; id: string; @@ -33,9 +33,9 @@ export interface StaffMemberDetails_user { firstName: string; isActive: boolean; lastName: string; - avatar: StaffMemberDetails_user_avatar | null; permissionGroups: (StaffMemberDetails_user_permissionGroups | null)[] | null; userPermissions: (StaffMemberDetails_user_userPermissions | null)[] | null; + avatar: StaffMemberDetails_user_avatar | null; } export interface StaffMemberDetails { diff --git a/src/staff/types/StaffMemberUpdate.ts b/src/staff/types/StaffMemberUpdate.ts index b7ce4c317..abf093d50 100644 --- a/src/staff/types/StaffMemberUpdate.ts +++ b/src/staff/types/StaffMemberUpdate.ts @@ -14,11 +14,6 @@ export interface StaffMemberUpdate_staffUpdate_errors { field: string | null; } -export interface StaffMemberUpdate_staffUpdate_user_avatar { - __typename: "Image"; - url: string; -} - export interface StaffMemberUpdate_staffUpdate_user_permissionGroups { __typename: "Group"; id: string; @@ -32,6 +27,11 @@ export interface StaffMemberUpdate_staffUpdate_user_userPermissions { name: string; } +export interface StaffMemberUpdate_staffUpdate_user_avatar { + __typename: "Image"; + url: string; +} + export interface StaffMemberUpdate_staffUpdate_user { __typename: "User"; id: string; @@ -39,9 +39,9 @@ export interface StaffMemberUpdate_staffUpdate_user { firstName: string; isActive: boolean; lastName: string; - avatar: StaffMemberUpdate_staffUpdate_user_avatar | null; permissionGroups: (StaffMemberUpdate_staffUpdate_user_permissionGroups | null)[] | null; userPermissions: (StaffMemberUpdate_staffUpdate_user_userPermissions | null)[] | null; + avatar: StaffMemberUpdate_staffUpdate_user_avatar | null; } export interface StaffMemberUpdate_staffUpdate { diff --git a/src/storybook/__snapshots__/Stories.test.ts.snap b/src/storybook/__snapshots__/Stories.test.ts.snap index 93ef683e4..085d7b826 100644 --- a/src/storybook/__snapshots__/Stories.test.ts.snap +++ b/src/storybook/__snapshots__/Stories.test.ts.snap @@ -1329,18 +1329,43 @@ exports[`Storyshots Generics / Checkbox checked 1`] = `
- + + + + +
@@ -1357,20 +1382,39 @@ exports[`Storyshots Generics / Checkbox disabled 1`] = `
- + + + + +
@@ -1388,18 +1432,37 @@ exports[`Storyshots Generics / Checkbox interactive 1`] = ` class="MuiCardContent-root-id" >
- + + + + +
@@ -1417,18 +1480,37 @@ exports[`Storyshots Generics / Checkbox unchecked 1`] = `
- + + + + +
@@ -1445,18 +1527,44 @@ exports[`Storyshots Generics / Checkbox undeterminate 1`] = `
- + + + + +
@@ -1899,17 +2007,42 @@ exports[`Storyshots Generics / Filter default 1`] = `
`; +exports[`Storyshots Generics / NavigatorButton mac 1`] = ` +
+
+
+ +
+
+
+`; + +exports[`Storyshots Generics / NavigatorButton other 1`] = ` +
+
+
+ +
+
+
+`; + exports[`Storyshots Generics / PageHeader with title 1`] = `
- Thirdparty Apps + Third-party Apps
- Thirdparty Apps + Third-party Apps
- Thirdparty Apps + Third-party Apps
- + + + + + @@ -12233,18 +13051,79 @@ exports[`Storyshots Views / Apps / Webhooks / Create webhook default 1`] = ` + + Checkout created + + +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+
- + + + + + @@ -125741,18 +135390,43 @@ Ctrl + K" @@ -125873,7 +135547,7 @@ Ctrl + K"
- kg + KG
- + + + + + @@ -127813,17 +137512,36 @@ Ctrl + K" class="MuiTableCell-root-id MuiTableCell-head-id MuiTableCell-paddingCheckbox-id" scope="col" > - + + + + + - + + + + + - + + + + + - + + + + + @@ -130594,17 +140369,36 @@ Ctrl + K" class="MuiTableCell-root-id MuiTableCell-head-id MuiTableCell-paddingCheckbox-id" scope="col" > - + + + + + - + + + + + - + + + + + - + + + + + @@ -132372,7 +142229,7 @@ Ctrl + K"
- kg + KG
- + + + + + @@ -133781,17 +143663,36 @@ exports[`Storyshots Views / Products / Product list default 1`] = ` class="MuiTableCell-root-id MuiTableCell-head-id MuiTableCell-paddingCheckbox-id" scope="col" > - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - kg + KG
- + + + + + @@ -140430,7 +151192,7 @@ exports[`Storyshots Views / Products / Product variant details when loaded data
- kg + KG
- + + + + + @@ -141257,20 +152044,39 @@ exports[`Storyshots Views / Products / Product variant details when loading data @@ -142425,7 +153231,7 @@ exports[`Storyshots Views / Shipping / Shipping zone details default 1`] = ` - 0 kg - 80 kg + 0 KG - 80 KG - from 0 kg + from 0 KG - 0 kg - 80 kg + 0 KG - 80 KG - from 0 kg + from 0 KG - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + - + + + + + @@ -149739,20 +160836,39 @@ exports[`Storyshots Views / Staff / Staff member details loading 1`] = ` @@ -151055,18 +162171,37 @@ exports[`Storyshots Views / Taxes / Country List default 1`] = ` @@ -151079,18 +162214,43 @@ exports[`Storyshots Views / Taxes / Country List default 1`] = ` @@ -151103,18 +162263,37 @@ exports[`Storyshots Views / Taxes / Country List default 1`] = ` @@ -151782,20 +162961,39 @@ exports[`Storyshots Views / Taxes / Country List loading 1`] = ` @@ -151808,20 +163006,39 @@ exports[`Storyshots Views / Taxes / Country List loading 1`] = ` @@ -151834,20 +163051,39 @@ exports[`Storyshots Views / Taxes / Country List loading 1`] = ` diff --git a/src/theme.ts b/src/theme.ts index bddcd3d94..7c1b87451 100644 --- a/src/theme.ts +++ b/src/theme.ts @@ -1,10 +1,15 @@ import Card from "@material-ui/core/Card"; +import Checkbox from "@material-ui/core/Checkbox"; import { createMuiTheme, Theme } from "@material-ui/core/styles"; import { darken, fade } from "@material-ui/core/styles/colorManipulator"; import TextField from "@material-ui/core/TextField"; import Typography from "@material-ui/core/Typography"; +import { createElement } from "react"; import { IThemeColors } from "./components/Theme/themes"; +import CheckboxIcon from "./icons/Checkbox"; +import CheckboxCheckedIcon from "./icons/CheckboxChecked"; +import CheckboxIndeterminateIcon from "./icons/CheckboxIndeterminate"; const createShadow = (pv, pb, ps, uv, ub, us, av, ab, as) => [ @@ -562,3 +567,10 @@ Card.defaultProps = { Typography.defaultProps = { component: "div" }; + +Checkbox.defaultProps = { + checkedIcon: createElement(CheckboxCheckedIcon), + color: "primary", + icon: createElement(CheckboxIcon), + indeterminateIcon: createElement(CheckboxIndeterminateIcon) +}; diff --git a/src/types/globalTypes.ts b/src/types/globalTypes.ts index a0a9b2207..d2949a01f 100644 --- a/src/types/globalTypes.ts +++ b/src/types/globalTypes.ts @@ -865,7 +865,9 @@ export enum WebhookErrorCode { export enum WebhookEventTypeEnum { ANY_EVENTS = "ANY_EVENTS", + CHECKOUT_CREATED = "CHECKOUT_CREATED", CHECKOUT_QUANTITY_CHANGED = "CHECKOUT_QUANTITY_CHANGED", + CHECKOUT_UPDATED = "CHECKOUT_UPDATED", CUSTOMER_CREATED = "CUSTOMER_CREATED", FULFILLMENT_CREATED = "FULFILLMENT_CREATED", INVOICE_DELETED = "INVOICE_DELETED", diff --git a/src/webhooks/components/WebhookEvents/WebhookEvents.tsx b/src/webhooks/components/WebhookEvents/WebhookEvents.tsx index 5db4eeabc..7bae16ebb 100644 --- a/src/webhooks/components/WebhookEvents/WebhookEvents.tsx +++ b/src/webhooks/components/WebhookEvents/WebhookEvents.tsx @@ -32,6 +32,14 @@ const WebhookEvents: React.FC = ({ defaultMessage: "All events", description: "event" }), + [WebhookEventTypeEnum.CHECKOUT_CREATED]: intl.formatMessage({ + defaultMessage: "Checkout created", + description: "event" + }), + [WebhookEventTypeEnum.CHECKOUT_UPDATED]: intl.formatMessage({ + defaultMessage: "Checkout updated", + description: "event" + }), [WebhookEventTypeEnum.CUSTOMER_CREATED]: intl.formatMessage({ defaultMessage: "Customer created", description: "event"