Custom message
This commit is contained in:
parent
fdf83fd65d
commit
329fc53ac8
|
@ -170,10 +170,6 @@
|
||||||
relationshipPart1 = part1
|
relationshipPart1 = part1
|
||||||
relationshipPart2 = part2
|
relationshipPart2 = part2
|
||||||
}
|
}
|
||||||
} else if (editableColumn.type === FieldType.ATTACHMENT) {
|
|
||||||
editableColumn.constraints ??= { length: {} }
|
|
||||||
editableColumn.constraints.length ??= {}
|
|
||||||
editableColumn.constraints.length.maximum = 1
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -508,6 +504,8 @@
|
||||||
onMount(() => {
|
onMount(() => {
|
||||||
mounted = true
|
mounted = true
|
||||||
})
|
})
|
||||||
|
|
||||||
|
$: console.log({ editableColumn })
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<Layout noPadding gap="S">
|
<Layout noPadding gap="S">
|
||||||
|
@ -722,8 +720,11 @@
|
||||||
editableColumn.constraints ??= { length: {} }
|
editableColumn.constraints ??= { length: {} }
|
||||||
editableColumn.constraints.length ??= {}
|
editableColumn.constraints.length ??= {}
|
||||||
editableColumn.constraints.length.maximum = 1
|
editableColumn.constraints.length.maximum = 1
|
||||||
|
editableColumn.constraints.length.message =
|
||||||
|
"cannot contain multiple files"
|
||||||
} else {
|
} else {
|
||||||
delete editableColumn.constraints?.length?.maximum
|
delete editableColumn.constraints?.length?.maximum
|
||||||
|
delete editableColumn.constraints?.length?.message
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
thin
|
thin
|
||||||
|
|
Loading…
Reference in New Issue