fix: add fallback and capture_vars defaultValues

This commit is contained in:
yassinedorbozgithub 2024-11-27 06:40:49 +01:00
parent fd1e23127e
commit 3871464486

View File

@ -82,9 +82,15 @@ const BlockDialog: FC<BlockDialogProps> = ({
limit: 2, limit: 2,
}, },
assignTo: block?.options?.assignTo, assignTo: block?.options?.assignTo,
fallback: block?.options?.fallback || {
active: true,
message: [],
max_attempts: 1,
},
}, },
assign_labels: block?.assign_labels || [], assign_labels: block?.assign_labels || [],
message: block?.message || [""], message: block?.message || [""],
capture_vars: block?.capture_vars || [],
} as IBlockAttributes; } as IBlockAttributes;
const methods = useForm<IBlockAttributes>({ const methods = useForm<IBlockAttributes>({
defaultValues: DEFAULT_VALUES, defaultValues: DEFAULT_VALUES,