Transient variables are not captured properly on form submission
- by Kalpana
My User entity class have several member variables (e.g. String firstName) which are persisted and some transient variables (e.g. transient boolean selected) which are not. I have used the transient variable to capture a checkbox selection, but invariably the value never gets set and procesed properly until I set another bean value along with it.
i.e. If User has firstName (mapped to a text field) and selected (mapped to a checkbox)
If I just selected the value doesn't seem to be set on an update
If I had selected the checkbox and the firstName field, the "selected" value is captured properly
Can anyone tell me why this is happening?