I have a datasourcefield which is an enum, and in the form i never want a "empty" field in the dropdown, even if it is coming as null from the server.
It works if i set it through the java method
, but if i set it in XML like this
the setting is not applied. What am i missing here? Pointers appreciated.
It works if i set it through the java method
Code:
theItem.setAllowEmptyValue(false);
Code:
<field name="theItem" type="enum" allowEmptyValue="false" required="true" defaultValue="0">
Comment