[ 
https://issues.apache.org/struts/browse/WW-2256?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jeromy Evans resolved WW-2256.
------------------------------

       Resolution: Fixed
    Fix Version/s:     (was: 2.1.4)
                   2.1.1

Issue confirmed.

The attached patches weren't sufficient as they did not work where a child 
element of the form was not contained by a table row and because the input 
inserted by dojo contained a blank id and that was not matched by the function 
clearing labels based on the errorFor labels.  

Unfortunately I also have to raise the following two issues:
1. WW-2521 client-side validation doesn't work if the control doesn't have a 
label

2.WW-2522  autocompleter cannot be used within a css_xhtml form with clientside 
validation
     The validation script for the css_xhtml theme searches for the containing 
divs but the autocompeter is contained in tables (based on xhtml theme)

I've committed the fix based on the patches but with additional error 
detection. Thanks Benjamin.


> Validation broken on autocompleters
> -----------------------------------
>
>                 Key: WW-2256
>                 URL: https://issues.apache.org/struts/browse/WW-2256
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Plugin - Mechanism, Plugin - Tags
>    Affects Versions: 2.0.9, 2.1.0
>         Environment: Issue identified on Windows XP using Firefox
>            Reporter: Benjamin McCann
>            Assignee: Jeromy Evans
>            Priority: Critical
>             Fix For: 2.1.1
>
>         Attachments: allFieldsFilledOnSubmit.png, siteEmptyOnSubmit.png, 
> validation.js.patch, validation.js.patch, validation.js.patch
>
>
> I have an autocompleter named "site":
> <s:url id="siteList" action="AutocompleteField" method="selectSite" 
> namespace="/general" />
> <sx:autocompleter label="Site" value="%{system.site}"
>       forceValidOption="true"
>       cssStyle="width:132px; height:18px; border:1px solid #7B9EBD"
>       name="site" required="true" href="%{siteList}"
>       loadOnTextChange="true" showDownArrow="false" dropdownWidth="300"
>       searchType="substring" />
> It has the following validator:
> <field name="site">
>     <field-validator type="requiredstring">
>         <message>Field is required</message>
>     </field-validator>
> </field>
> When I submit my .jsp without site filled in I get the message: "TypeError: 
> row.cells has no properties"
> When I submit my .jsp with site filled in I get message that the field is 
> required and all the other fields are blanked out.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to