fix(frontend): Read current radio value out of prop formOptions
This commit is contained in:
@@ -16,10 +16,9 @@ const emit = defineEmits<{
|
||||
|
||||
// Our "label" is the "value" of the radio button
|
||||
const items = computed(() => props.formOptions.map((option) => ({ label: option.label, value: option.label })))
|
||||
const currentSelectedValue = ref(undefined)
|
||||
|
||||
const modelValue = computed({
|
||||
get: () => currentSelectedValue.value,
|
||||
get: () => props.formOptions.find((option) => option.value === 'true')?.label,
|
||||
set: (val) => {
|
||||
if (val) {
|
||||
const updatedModelValue = [...props.formOptions]
|
||||
|
||||
Reference in New Issue
Block a user