You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There appears to be a bug in ZK Framework 10.0.0-jakarta with the radio or radiogroup component. And it appears to be present in 9.6.0.2 as well.
When you place two or more radio components in a radiogroup, and set the first component to either checked="true" or selected="true", when you view the form, the radio button does not appear to be checked.
If you wire it to a pojo, and query it, it will say the button is checked or selected. It doesn't matter whether you use checked or selected. Neither seems to work properly.
Even if you setChecked("true") or setSelected("true") programatically, it will not display as if it is checked / selected.
But if you set the second radio component to checked or selected, it will show properly.
I suspect it has something to do with the radiogroup index property.
A workaround to this is to create an invisible radio as the first item of the radiogroup. And it does not even need to be wired, as long as it is set to that same radiogroup.
In the example below, I put both checked="true" and selected="true" in it, but it works fine this way with just one of them, and it does not matter which one we use.
Example:
<radiogroup id="testRadiogroup" />
<vlayout>
<radio id="radioInvisible" label="Invisible. This is necessary for the default radio button to show selected." radiogroup="testRadiogroup" visible="false" />
<radio id="radio1" label="Radio 1." radiogroup="testRadiogroup" checked="true" selected="true" />
<radio id="radio2" label="Radio 2." radiogroup="testRadiogroup"/>
</vlayout>
If this is not the correct place to file a bug report for this, please direct me to the proper place.
The text was updated successfully, but these errors were encountered:
There appears to be a bug in ZK Framework 10.0.0-jakarta with the radio or radiogroup component. And it appears to be present in 9.6.0.2 as well.
When you place two or more radio components in a radiogroup, and set the first component to either checked="true" or selected="true", when you view the form, the radio button does not appear to be checked.
If you wire it to a pojo, and query it, it will say the button is checked or selected. It doesn't matter whether you use checked or selected. Neither seems to work properly.
Even if you setChecked("true") or setSelected("true") programatically, it will not display as if it is checked / selected.
But if you set the second radio component to checked or selected, it will show properly.
I suspect it has something to do with the radiogroup index property.
A workaround to this is to create an invisible radio as the first item of the radiogroup. And it does not even need to be wired, as long as it is set to that same radiogroup.
In the example below, I put both checked="true" and selected="true" in it, but it works fine this way with just one of them, and it does not matter which one we use.
Example:
If this is not the correct place to file a bug report for this, please direct me to the proper place.
The text was updated successfully, but these errors were encountered: