fix: short text booking questions does not save we we click add (#17778)

This commit is contained in:
Anik Dhabal Babu authored and GitHub committed 2024-11-21 22:46:44 +00:00
1 parent b0bf87f3ed
commit 7ab8fdbcb4
1 file changed
+4 -1
@@ -459,7 +459,10 @@ function FieldEditDialog({
}) {
const { t } = useLocale();
const fieldForm = useForm<RhfFormField>({
defaultValues: dialog.data || {},
defaultValues: {
type: "text",
...dialog.data,
},
resolver: zodResolver(fieldSchema),
});
const formFieldType = fieldForm.getValues("type");