1
0
Fork 0
mirror of synced 2024-08-17 02:51:55 +12:00

change naming of var

This commit is contained in:
Peter Clement 2022-02-08 15:00:16 +00:00
parent ca821f2a47
commit b91919e6d1
3 changed files with 9 additions and 5 deletions

View file

@ -122,7 +122,7 @@ const automationActions = store => ({
},
toggleFieldControl: value => {
store.update(state => {
state.selectedAutomation.automation.rowFieldControl = value
state.selectedAutomation.automation.rowControl = value
return state
})
},

View file

@ -3,7 +3,7 @@
import { ModalContent, Toggle } from "@budibase/bbui"
$: rowControl = $automationStore.selectedAutomation.automation.rowFieldControl
$: rowControl = $automationStore.selectedAutomation.automation.rowControl
async function toggleFieldControl(evt) {
await automationStore.actions.toggleFieldControl(evt.detail)
await automationStore.actions.save(

View file

@ -51,13 +51,17 @@
if (type === "number") {
return Number(value)
}
if (type === "options" || type === "link") {
if (type === "options") {
return [value]
}
if (type === "array") {
return value.split(",")
}
if (type === "link") {
return [value]
}
return value
}
@ -84,7 +88,7 @@
{#if !schema.autocolumn}
{#if schema.type !== "attachment"}
{#if $automationStore.selectedAutomation.automation.testData}
{#if $automationStore.selectedAutomation.automation.rowFieldControl}
{#if $automationStore.selectedAutomation.automation.rowControl}
<RowSelectorTypes
{field}
{schema}
@ -103,7 +107,7 @@
{bindings}
/>
{/if}
{:else if $automationStore.selectedAutomation.automation.rowFieldControl}
{:else if $automationStore.selectedAutomation.automation.rowControl}
<RowSelectorTypes {field} {schema} {bindings} {value} {onChange} />
{:else}
<DrawerBindableInput