Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    ComboBoxItem validateOnExit

    Hi,

    I have a problem with ComboBoxItem in DynamicForm which has required="true" set in data source.

    When I choose a value from dropdown list then the comboBoxItem gets Invalid immediatelly. When I start editing a next field in a dynamic form then the combobox will become valid again.

    The trouble is the the combobox gets invalid by default and onExit it gets validated.

    I use latast nightbuild 2011-04-16 and firefox 3.6.

    Code:
    form.setValidateOnExit(true);
    
    
    systemRoleItem = new ComboBoxItem("roleId", i18nConstants.settingsTree_userManagement_addEditWindow_dynamicForm_systemRole());
    systemRoleItem.setWidth(300);
    systemRoleItem.setOptionDataSource(DataSource.get("rolesDS"));
    systemRoleItem.setValueField("roleId");
    systemRoleItem.setDisplayField("javaEnum");
    Code:
    <field name="roles" unknownType="true" type="cz.bcom.server.persistence.hibernate.Roles" hidden="true"></field>
    <field name="roleDisplayText" type="text" valueXPath="roles/javaEnum" hidden="true"></field>
    <field name="roleId" type="integer" required="true" foreignKey="rolesDS.roleId"  valueXPath="roles/roleId" displayField="roleDisplayText"></field>

    #2
    Hi,

    I'm sorry. This problem was caused by a wrong code on my side.

    best regards,
    Zdary

    Comment

    Working...
    X