fix(entry-form): clear disabilityType when disability is 'no'
Reset the disabilityType field when disability is set to 'no' to maintain data consistency
This commit is contained in:
@@ -91,6 +91,15 @@ watch(
|
|||||||
immediate: true,
|
immediate: true,
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
|
||||||
|
watch(
|
||||||
|
() => values.disability,
|
||||||
|
(newValue) => {
|
||||||
|
if (newValue === 'no') {
|
||||||
|
setFieldValue('disabilityType', undefined)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
)
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
|||||||
Reference in New Issue
Block a user