From 800deaf0c7ebc5d2450510791eda39f89c7b4df8 Mon Sep 17 00:00:00 2001 From: Gil Gardosh Date: Thu, 10 Nov 2022 18:32:57 +0200 Subject: [PATCH] Green Invoice minor fixes (#90) * Some minor fixes --- ...er-toolkit_green-invoice-graphql-61-dependencies.md | 4 ++-- ...er-toolkit_green-invoice-graphql-80-dependencies.md | 10 ++++++---- ...er-toolkit_green-invoice-graphql-89-dependencies.md | 10 ++++++---- ...ounter-toolkit_hashavshevet-mesh-80-dependencies.md | 10 ++++++---- ...ounter-toolkit_hashavshevet-mesh-89-dependencies.md | 10 ++++++---- ...nter-toolkit_israeli-vat-scraper-80-dependencies.md | 8 +++++--- ...kit_modern-israeli-bank-scrapers-80-dependencies.md | 10 ++++++---- ...kit_modern-israeli-bank-scrapers-89-dependencies.md | 6 ++++-- .../@accounter-toolkit_payper-mesh-61-dependencies.md | 4 ++-- .../@accounter-toolkit_payper-mesh-80-dependencies.md | 10 ++++++---- .../@accounter-toolkit_payper-mesh-89-dependencies.md | 10 ++++++---- .changeset/sharp-moles-repair.md | 5 +++++ packages/green-invoice-graphql/.meshrc.yaml | 5 ++++- packages/green-invoice-graphql/dev-tests/e2e.ts | 5 ++--- .../src/json-schemas/greenInvoice.json | 2 +- 15 files changed, 67 insertions(+), 42 deletions(-) create mode 100644 .changeset/sharp-moles-repair.md diff --git a/.changeset/@accounter-toolkit_green-invoice-graphql-61-dependencies.md b/.changeset/@accounter-toolkit_green-invoice-graphql-61-dependencies.md index 550d01cb..8379fbd9 100644 --- a/.changeset/@accounter-toolkit_green-invoice-graphql-61-dependencies.md +++ b/.changeset/@accounter-toolkit_green-invoice-graphql-61-dependencies.md @@ -1,8 +1,8 @@ --- -"@accounter-toolkit/green-invoice-graphql": patch +'@accounter-toolkit/green-invoice-graphql': patch --- -dependencies updates: +dependencies updates: - Updated dependency [`@graphql-mesh/cli@0.78.12` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.78.12) (from `0.78.10`, in `dependencies`) - Updated dependency [`@graphql-mesh/json-schema@0.35.11` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.11) (from `0.35.10`, in `dependencies`) diff --git a/.changeset/@accounter-toolkit_green-invoice-graphql-80-dependencies.md b/.changeset/@accounter-toolkit_green-invoice-graphql-80-dependencies.md index 4c815ec9..c5ff8cf3 100644 --- a/.changeset/@accounter-toolkit_green-invoice-graphql-80-dependencies.md +++ b/.changeset/@accounter-toolkit_green-invoice-graphql-80-dependencies.md @@ -1,7 +1,9 @@ --- -"@accounter-toolkit/green-invoice-graphql": patch +'@accounter-toolkit/green-invoice-graphql': patch --- + dependencies updates: - - Updated dependency [`@graphql-mesh/cli@0.78.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.78.33) (from `0.78.25`, in `dependencies`) - - Updated dependency [`@graphql-mesh/json-schema@0.35.25` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.25) (from `0.35.19`, in `dependencies`) - - Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.101` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.101) (from `0.12.95`, in `dependencies`) + +- Updated dependency [`@graphql-mesh/cli@0.78.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.78.33) (from `0.78.25`, in `dependencies`) +- Updated dependency [`@graphql-mesh/json-schema@0.35.25` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.25) (from `0.35.19`, in `dependencies`) +- Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.101` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.101) (from `0.12.95`, in `dependencies`) diff --git a/.changeset/@accounter-toolkit_green-invoice-graphql-89-dependencies.md b/.changeset/@accounter-toolkit_green-invoice-graphql-89-dependencies.md index 2143d86c..3c8f350f 100644 --- a/.changeset/@accounter-toolkit_green-invoice-graphql-89-dependencies.md +++ b/.changeset/@accounter-toolkit_green-invoice-graphql-89-dependencies.md @@ -1,7 +1,9 @@ --- -"@accounter-toolkit/green-invoice-graphql": patch +'@accounter-toolkit/green-invoice-graphql': patch --- + dependencies updates: - - Updated dependency [`@graphql-mesh/cli@0.79.3` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.79.3) (from `0.78.33`, in `dependencies`) - - Updated dependency [`@graphql-mesh/json-schema@0.35.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.33) (from `0.35.25`, in `dependencies`) - - Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.108` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.108) (from `0.12.101`, in `dependencies`) + +- Updated dependency [`@graphql-mesh/cli@0.79.3` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.79.3) (from `0.78.33`, in `dependencies`) +- Updated dependency [`@graphql-mesh/json-schema@0.35.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.33) (from `0.35.25`, in `dependencies`) +- Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.108` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.108) (from `0.12.101`, in `dependencies`) diff --git a/.changeset/@accounter-toolkit_hashavshevet-mesh-80-dependencies.md b/.changeset/@accounter-toolkit_hashavshevet-mesh-80-dependencies.md index 2f0025ad..87f7f1fb 100644 --- a/.changeset/@accounter-toolkit_hashavshevet-mesh-80-dependencies.md +++ b/.changeset/@accounter-toolkit_hashavshevet-mesh-80-dependencies.md @@ -1,7 +1,9 @@ --- -"@accounter-toolkit/hashavshevet-mesh": patch +'@accounter-toolkit/hashavshevet-mesh': patch --- + dependencies updates: - - Updated dependency [`@graphql-mesh/cli@0.78.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.78.33) (from `0.78.25`, in `dependencies`) - - Updated dependency [`@graphql-mesh/json-schema@0.35.25` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.25) (from `0.35.19`, in `dependencies`) - - Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.101` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.101) (from `0.12.95`, in `dependencies`) + +- Updated dependency [`@graphql-mesh/cli@0.78.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.78.33) (from `0.78.25`, in `dependencies`) +- Updated dependency [`@graphql-mesh/json-schema@0.35.25` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.25) (from `0.35.19`, in `dependencies`) +- Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.101` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.101) (from `0.12.95`, in `dependencies`) diff --git a/.changeset/@accounter-toolkit_hashavshevet-mesh-89-dependencies.md b/.changeset/@accounter-toolkit_hashavshevet-mesh-89-dependencies.md index 4248abc1..13d45fde 100644 --- a/.changeset/@accounter-toolkit_hashavshevet-mesh-89-dependencies.md +++ b/.changeset/@accounter-toolkit_hashavshevet-mesh-89-dependencies.md @@ -1,7 +1,9 @@ --- -"@accounter-toolkit/hashavshevet-mesh": patch +'@accounter-toolkit/hashavshevet-mesh': patch --- + dependencies updates: - - Updated dependency [`@graphql-mesh/cli@0.79.3` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.79.3) (from `0.78.33`, in `dependencies`) - - Updated dependency [`@graphql-mesh/json-schema@0.35.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.33) (from `0.35.25`, in `dependencies`) - - Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.108` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.108) (from `0.12.101`, in `dependencies`) + +- Updated dependency [`@graphql-mesh/cli@0.79.3` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.79.3) (from `0.78.33`, in `dependencies`) +- Updated dependency [`@graphql-mesh/json-schema@0.35.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.33) (from `0.35.25`, in `dependencies`) +- Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.108` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.108) (from `0.12.101`, in `dependencies`) diff --git a/.changeset/@accounter-toolkit_israeli-vat-scraper-80-dependencies.md b/.changeset/@accounter-toolkit_israeli-vat-scraper-80-dependencies.md index 293ca5ca..5b06196a 100644 --- a/.changeset/@accounter-toolkit_israeli-vat-scraper-80-dependencies.md +++ b/.changeset/@accounter-toolkit_israeli-vat-scraper-80-dependencies.md @@ -1,6 +1,8 @@ --- -"@accounter-toolkit/israeli-vat-scraper": patch +'@accounter-toolkit/israeli-vat-scraper': patch --- + dependencies updates: - - Updated dependency [`dotenv@16.0.3` ↗︎](https://www.npmjs.com/package/dotenv/v/16.0.3) (from `16.0.2`, in `dependencies`) - - Updated dependency [`puppeteer@18.2.1` ↗︎](https://www.npmjs.com/package/puppeteer/v/18.2.1) (from `16.2.0`, in `dependencies`) + +- Updated dependency [`dotenv@16.0.3` ↗︎](https://www.npmjs.com/package/dotenv/v/16.0.3) (from `16.0.2`, in `dependencies`) +- Updated dependency [`puppeteer@18.2.1` ↗︎](https://www.npmjs.com/package/puppeteer/v/18.2.1) (from `16.2.0`, in `dependencies`) diff --git a/.changeset/@accounter-toolkit_modern-israeli-bank-scrapers-80-dependencies.md b/.changeset/@accounter-toolkit_modern-israeli-bank-scrapers-80-dependencies.md index 8d81a8c7..31a4c9d3 100644 --- a/.changeset/@accounter-toolkit_modern-israeli-bank-scrapers-80-dependencies.md +++ b/.changeset/@accounter-toolkit_modern-israeli-bank-scrapers-80-dependencies.md @@ -1,7 +1,9 @@ --- -"@accounter-toolkit/modern-israeli-bank-scrapers": patch +'@accounter-toolkit/modern-israeli-bank-scrapers': patch --- + dependencies updates: - - Updated dependency [`inquirer@9.1.3` ↗︎](https://www.npmjs.com/package/inquirer/v/9.1.3) (from `9.1.2`, in `dependencies`) - - Updated dependency [`puppeteer@18.2.1` ↗︎](https://www.npmjs.com/package/puppeteer/v/18.2.1) (from `17.1.3`, in `dependencies`) - - Updated dependency [`uuid@9.0.0` ↗︎](https://www.npmjs.com/package/uuid/v/9.0.0) (from `8.3.2`, in `dependencies`) + +- Updated dependency [`inquirer@9.1.3` ↗︎](https://www.npmjs.com/package/inquirer/v/9.1.3) (from `9.1.2`, in `dependencies`) +- Updated dependency [`puppeteer@18.2.1` ↗︎](https://www.npmjs.com/package/puppeteer/v/18.2.1) (from `17.1.3`, in `dependencies`) +- Updated dependency [`uuid@9.0.0` ↗︎](https://www.npmjs.com/package/uuid/v/9.0.0) (from `8.3.2`, in `dependencies`) diff --git a/.changeset/@accounter-toolkit_modern-israeli-bank-scrapers-89-dependencies.md b/.changeset/@accounter-toolkit_modern-israeli-bank-scrapers-89-dependencies.md index a07222a9..12bd4967 100644 --- a/.changeset/@accounter-toolkit_modern-israeli-bank-scrapers-89-dependencies.md +++ b/.changeset/@accounter-toolkit_modern-israeli-bank-scrapers-89-dependencies.md @@ -1,5 +1,7 @@ --- -"@accounter-toolkit/modern-israeli-bank-scrapers": patch +'@accounter-toolkit/modern-israeli-bank-scrapers': patch --- + dependencies updates: - - Updated dependency [`inquirer@9.1.4` ↗︎](https://www.npmjs.com/package/inquirer/v/9.1.4) (from `9.1.3`, in `dependencies`) + +- Updated dependency [`inquirer@9.1.4` ↗︎](https://www.npmjs.com/package/inquirer/v/9.1.4) (from `9.1.3`, in `dependencies`) diff --git a/.changeset/@accounter-toolkit_payper-mesh-61-dependencies.md b/.changeset/@accounter-toolkit_payper-mesh-61-dependencies.md index b75794da..bc585b3b 100644 --- a/.changeset/@accounter-toolkit_payper-mesh-61-dependencies.md +++ b/.changeset/@accounter-toolkit_payper-mesh-61-dependencies.md @@ -1,8 +1,8 @@ --- -"@accounter-toolkit/payper-mesh": patch +'@accounter-toolkit/payper-mesh': patch --- -dependencies updates: +dependencies updates: - Updated dependency [`@graphql-mesh/cli@0.78.12` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.78.12) (from `0.78.10`, in `dependencies`) - Updated dependency [`@graphql-mesh/json-schema@0.35.11` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.11) (from `0.35.10`, in `dependencies`) diff --git a/.changeset/@accounter-toolkit_payper-mesh-80-dependencies.md b/.changeset/@accounter-toolkit_payper-mesh-80-dependencies.md index e49a58ae..56174376 100644 --- a/.changeset/@accounter-toolkit_payper-mesh-80-dependencies.md +++ b/.changeset/@accounter-toolkit_payper-mesh-80-dependencies.md @@ -1,7 +1,9 @@ --- -"@accounter-toolkit/payper-mesh": patch +'@accounter-toolkit/payper-mesh': patch --- + dependencies updates: - - Updated dependency [`@graphql-mesh/cli@0.78.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.78.33) (from `0.78.25`, in `dependencies`) - - Updated dependency [`@graphql-mesh/json-schema@0.35.25` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.25) (from `0.35.19`, in `dependencies`) - - Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.101` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.101) (from `0.12.95`, in `dependencies`) + +- Updated dependency [`@graphql-mesh/cli@0.78.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.78.33) (from `0.78.25`, in `dependencies`) +- Updated dependency [`@graphql-mesh/json-schema@0.35.25` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.25) (from `0.35.19`, in `dependencies`) +- Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.101` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.101) (from `0.12.95`, in `dependencies`) diff --git a/.changeset/@accounter-toolkit_payper-mesh-89-dependencies.md b/.changeset/@accounter-toolkit_payper-mesh-89-dependencies.md index 2e61badf..01ff7926 100644 --- a/.changeset/@accounter-toolkit_payper-mesh-89-dependencies.md +++ b/.changeset/@accounter-toolkit_payper-mesh-89-dependencies.md @@ -1,7 +1,9 @@ --- -"@accounter-toolkit/payper-mesh": patch +'@accounter-toolkit/payper-mesh': patch --- + dependencies updates: - - Updated dependency [`@graphql-mesh/cli@0.79.3` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.79.3) (from `0.78.33`, in `dependencies`) - - Updated dependency [`@graphql-mesh/json-schema@0.35.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.33) (from `0.35.25`, in `dependencies`) - - Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.108` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.108) (from `0.12.101`, in `dependencies`) + +- Updated dependency [`@graphql-mesh/cli@0.79.3` ↗︎](https://www.npmjs.com/package/@graphql-mesh/cli/v/0.79.3) (from `0.78.33`, in `dependencies`) +- Updated dependency [`@graphql-mesh/json-schema@0.35.33` ↗︎](https://www.npmjs.com/package/@graphql-mesh/json-schema/v/0.35.33) (from `0.35.25`, in `dependencies`) +- Updated dependency [`@graphql-mesh/transform-resolvers-composition@0.12.108` ↗︎](https://www.npmjs.com/package/@graphql-mesh/transform-resolvers-composition/v/0.12.108) (from `0.12.101`, in `dependencies`) diff --git a/.changeset/sharp-moles-repair.md b/.changeset/sharp-moles-repair.md new file mode 100644 index 00000000..f85829ce --- /dev/null +++ b/.changeset/sharp-moles-repair.md @@ -0,0 +1,5 @@ +--- +'@accounter-toolkit/green-invoice-graphql': patch +--- + +Minor schema fixes diff --git a/packages/green-invoice-graphql/.meshrc.yaml b/packages/green-invoice-graphql/.meshrc.yaml index 8911ede0..a5654d31 100644 --- a/packages/green-invoice-graphql/.meshrc.yaml +++ b/packages/green-invoice-graphql/.meshrc.yaml @@ -18,7 +18,10 @@ sources: field: getExpense path: /expenses/{args.id} method: GET - requestSchema: ./src/json-schemas/greenInvoice.json#/definitions/getExpenseRequest + argTypeMap: + id: + type: string + nullable: false responseSchema: ./src/json-schemas/greenInvoice.json#/definitions/getExpenseResponse - type: Query diff --git a/packages/green-invoice-graphql/dev-tests/e2e.ts b/packages/green-invoice-graphql/dev-tests/e2e.ts index d424c277..e8432d16 100644 --- a/packages/green-invoice-graphql/dev-tests/e2e.ts +++ b/packages/green-invoice-graphql/dev-tests/e2e.ts @@ -2,7 +2,7 @@ import { config } from 'dotenv'; import fs from 'fs'; import { lookup } from 'mime-types'; -import { init } from '../src'; +import { init } from '../src/index.js'; config(); @@ -12,7 +12,7 @@ const base64Encode = (path: string) => { const getBase64Prefix = (path: string) => { const mimeType = lookup(path); - return mimeType ? `data:${lookup(path)};base64,` : ''; + return mimeType ? `data:${mimeType};base64,` : ''; }; const testRun = async () => { @@ -34,7 +34,6 @@ const testRun = async () => { /* get expense by id */ const data2 = await app.sdk.getExpense_query({ id: 'dbfb61b2-579c-42d0-b1ba-a3637e20eb6c', - input: { id: 'dbfb61b2-579c-42d0-b1ba-a3637e20eb6c' }, }); console.log(data2); diff --git a/packages/green-invoice-graphql/src/json-schemas/greenInvoice.json b/packages/green-invoice-graphql/src/json-schemas/greenInvoice.json index 5c80ba7f..4abf9953 100644 --- a/packages/green-invoice-graphql/src/json-schemas/greenInvoice.json +++ b/packages/green-invoice-graphql/src/json-schemas/greenInvoice.json @@ -702,7 +702,7 @@ "enum": [20, 305, 320, 330, 400, 405] }, "number": { - "type": "string", + "type": ["string", "null"], "description": "Number of the expense" }, "description": {