-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hi currently I use databinding annotation for binding data to various controls. I have a very large form so I want all the control values to get saved only when user clicks on save button. I use save-when property to databinding so that I can stop intermediate server calls for each control.
All controls except radio button behaving properly the way I want. For radio buttons things are not working the same way.
I have the following code:
<radiogroup id="gender"
selectedIndex="@{person.gender, save-when='btnNext.onClick', converter='com.bodyfs.ui.util.GenderToRadiogroup' }">
<radio label="M" />
<radio label="F" />
</radiogroup>
I have my model which stores the gender value as java enum. So I written a custom converter at the radiogroup level to convert the selected value to corresponding enum.
The problem is when ever I click on radio button a server call occurring to set the radio button value. I have bunch of radio buttons on my form and I don't want to send server request for clicking on each individual radio button. I want to submit all the form data together when user clicks on a button.
Why databinding save-when is not applying to radido button where as that applies properly to all other controls?
Any ideas?
-kesav
Could you post this to ZK bugs and upload runnable working sample codes? Thanks.
Asked: 2010-01-13 01:51:14 +0800
Seen: 589 times
Last updated: Jan 17 '10