i use react-hook-form and react-table version8.
i have problem.
rows feeFlag data is [
“0”,
“0”,
“1”,
“1”,
“0”
]
“0” value possible change radiobutton no > yes > no > yes.
but, initial value “1” setting can’t change ‘no’
there is no reaction.
onchange event also does not work.
I have no idea what the problem is.
help.
<Controller
name={`medias.${selectedIndex}.feeFlag`}
control={control}
render={({ field }) => (
<RadioGroup
row
aria-label="media-feeFlag"
name="feeFlag"
value={field.value}
onChange={(event) => {
event.persist();
field.onChange(event.target.value);
}}
>
<FormControlLabel
value={MediaFeeFlagProps.YES.toString()}
control={<Radio />}
label="YES"
labelPlacement="end"
/>
<FormControlLabel
value={MediaFeeFlagProps.NO.toString()}
control={<Radio />}
label="NO"
labelPlacement="end"
/>
</RadioGroup>
)}
/>
1