From fcb1c082cbdf3a34004311077afca9eb122fdae0 Mon Sep 17 00:00:00 2001 From: Martin McKeaveney Date: Fri, 22 Jan 2021 12:22:28 +0000 Subject: [PATCH] simplify queries to only have one type under query verb --- .../components/integration/QueryViewer.svelte | 13 ++-- .../userInterface/TableViewSelect.svelte | 4 +- .../[selectedDatasource]/[query]/index.svelte | 1 - .../[selectedDatasource]/index.svelte | 1 - packages/server/src/api/routes/query.js | 1 - .../src/api/routes/tests/datasource.spec.js | 1 - .../server/src/api/routes/tests/query.spec.js | 1 - packages/server/src/integrations/airtable.js | 52 ++++++-------- packages/server/src/integrations/couchdb.js | 24 +++---- packages/server/src/integrations/dynamodb.js | 68 ++++++++---------- .../server/src/integrations/elasticsearch.js | 70 ++++++++----------- .../src/integrations/microsoftSqlServer.js | 8 +-- packages/server/src/integrations/mongodb.js | 8 +-- packages/server/src/integrations/postgres.js | 16 ++--- packages/server/src/integrations/s3.js | 12 ++-- 15 files changed, 110 insertions(+), 170 deletions(-) diff --git a/packages/builder/src/components/integration/QueryViewer.svelte b/packages/builder/src/components/integration/QueryViewer.svelte index b3d9b9ab6a..712657b0c3 100644 --- a/packages/builder/src/components/integration/QueryViewer.svelte +++ b/packages/builder/src/components/integration/QueryViewer.svelte @@ -63,7 +63,7 @@ $: config = $backendUiStore.integrations[datasourceType]?.query $: docsLink = $backendUiStore.integrations[datasourceType]?.docs - $: shouldShowQueryConfig = config && query.queryVerb && query.queryType + $: shouldShowQueryConfig = config && query.queryVerb function newField() { fields = [...fields, {}] @@ -140,12 +140,9 @@ {/each} - +
+ {config[query.queryVerb].type} +