From 7ce00430745ae348751d59d1ff80e5cd97122f26 Mon Sep 17 00:00:00 2001 From: Peter Clement Date: Thu, 19 May 2022 15:58:56 +0100 Subject: [PATCH 1/4] ensure binding / value selection in automation persists --- .../automation/AutomationBuilder/FlowChart/FlowItem.svelte | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/builder/src/components/automation/AutomationBuilder/FlowChart/FlowItem.svelte b/packages/builder/src/components/automation/AutomationBuilder/FlowChart/FlowItem.svelte index 532e0ff068..7b33cc191b 100644 --- a/packages/builder/src/components/automation/AutomationBuilder/FlowChart/FlowItem.svelte +++ b/packages/builder/src/components/automation/AutomationBuilder/FlowChart/FlowItem.svelte @@ -28,7 +28,6 @@ let blockComplete let showLooping = false - $: rowControl = $automationStore.selectedAutomation.automation.rowControl $: showBindingPicker = block.stepId === "CREATE_ROW" || block.stepId === "UPDATE_ROW" @@ -256,7 +255,7 @@ on:change={toggleFieldControl} defaultValue="Use values" autoWidth - value={rowControl ? "Use bindings" : "Use values"} + value={block.rowControl ? "Use bindings" : "Use values"} options={["Use values", "Use bindings"]} placeholder={null} /> From 21456bb3cb0b819ae2ad1d69cdc33469dfd2488e Mon Sep 17 00:00:00 2001 From: Peter Clement Date: Thu, 19 May 2022 16:02:34 +0100 Subject: [PATCH 2/4] inform user that row selection only works with sql / internal --- packages/client/manifest.json | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/client/manifest.json b/packages/client/manifest.json index 4190d7f076..16490cace4 100644 --- a/packages/client/manifest.json +++ b/packages/client/manifest.json @@ -3007,6 +3007,7 @@ "illegalChildren": ["section"], "hasChildren": true, "showEmptyState": false, + "info": "Row selection is only compatible with internal or SQL tables", "settings": [ { "type": "dataProvider", @@ -3295,6 +3296,7 @@ { "section": true, "name": "Table", + "info": "Row selection is only compatible with internal or SQL tables", "settings": [ { "type": "number", From 1ffa48ced6e3a3ab29372297354dea18af917f44 Mon Sep 17 00:00:00 2001 From: Peter Clement Date: Thu, 19 May 2022 16:38:16 +0100 Subject: [PATCH 3/4] parse max iterations value correctly --- packages/server/src/threads/automation.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/server/src/threads/automation.js b/packages/server/src/threads/automation.js index 4ca490affd..7c5c96fc39 100644 --- a/packages/server/src/threads/automation.js +++ b/packages/server/src/threads/automation.js @@ -219,7 +219,7 @@ class Orchestrator { } if ( index === parseInt(env.AUTOMATION_MAX_ITERATIONS) || - index === loopStep.inputs.iterations + index === parseInt(loopStep.inputs.iterations) ) { this.updateContextAndOutput(loopStepNumber, step, tempOutput, { status: AutomationErrors.MAX_ITERATIONS, From 0455abc400ca8bdddaad01ffb286cb2b300d6050 Mon Sep 17 00:00:00 2001 From: Peter Clement Date: Tue, 24 May 2022 09:47:28 +0100 Subject: [PATCH 4/4] disable row selection within client table --- packages/client/src/components/app/table/Table.svelte | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/client/src/components/app/table/Table.svelte b/packages/client/src/components/app/table/Table.svelte index e8dcd30929..9346b3ca59 100644 --- a/packages/client/src/components/app/table/Table.svelte +++ b/packages/client/src/components/app/table/Table.svelte @@ -39,6 +39,8 @@ dataProvider?.id, ActionTypes.SetDataProviderSorting ) + $: table = dataProvider?.datasource?.type === "table" + $: { rowSelectionStore.actions.updateSelection( $component.id, @@ -142,7 +144,7 @@ {quiet} {compact} {customRenderers} - allowSelectRows={!!allowSelectRows} + allowSelectRows={allowSelectRows && table} bind:selectedRows allowEditRows={false} allowEditColumns={false}