Filter out invalid fields from fieldconfiguration (we don't allow formula and nested JSON fields in forms)

This commit is contained in:
Andrew Kingston 2023-08-31 08:50:36 +01:00
parent 471a5838a3
commit 8c889b873c
1 changed files with 6 additions and 1 deletions

View File

@ -99,6 +99,9 @@
}
const type = getComponentForField(instance.field, schema)
if (!type) {
return null
}
instance._component = `@budibase/standard-components/${type}`
const pseudoComponentInstance = store.actions.components.createInstance(
@ -116,7 +119,9 @@
}
$: if (sanitisedFields) {
fieldList = [...sanitisedFields, ...unconfigured].map(buildSudoInstance)
fieldList = [...sanitisedFields, ...unconfigured]
.map(buildSudoInstance)
.filter(x => x != null)
}
const processItemUpdate = e => {