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

alk updated VALIDATOR-207:
--------------------------

    Description: 
For validateRequired the following condition checks to see if the field is 
present.  It then sets the validity to false.

            if (!jcv_isFieldPresent(field)) {
                fields[i++] = oRequired[x][1];
                isValid=false;
            }

Supposedly validateRequired as well as all of the validate methods are not 
supposed to validate fields that are set as disabled.  This method seems to 
categorize disabled fields with those that are null or are undefined.

validateRequired should differentiate between the disabled fields and the not 
present fields.

Please refer to the Comments by alk

  was:
For validateRequired the following condition checks to see if the field is 
present.  It then sets the validity to false.

            if (!jcv_isFieldPresent(field)) {
                fields[i++] = oRequired[x][1];
                isValid=false;
            }

Supposedly validateRequired as well as all of the validate methods are not 
supposed to validate fields that are set as disabled.  This method seems to 
categorize disabled fields with those that are null or are undefined.

validateRequired should differentiate between the disabled fields and the not 
present fields.


> Disabled fields should not be checked by the validateRequired function.  
> Relevant to adding the check for field disabled in jcv_isFieldPresent.
> -----------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: VALIDATOR-207
>                 URL: https://issues.apache.org/jira/browse/VALIDATOR-207
>             Project: Commons Validator
>          Issue Type: Bug
>          Components: JavaScript
>    Affects Versions: 1.3.0 Release
>            Reporter: Joseph Breuer
>             Fix For: 1.4
>
>
> For validateRequired the following condition checks to see if the field is 
> present.  It then sets the validity to false.
>             if (!jcv_isFieldPresent(field)) {
>                 fields[i++] = oRequired[x][1];
>                 isValid=false;
>             }
> Supposedly validateRequired as well as all of the validate methods are not 
> supposed to validate fields that are set as disabled.  This method seems to 
> categorize disabled fields with those that are null or are undefined.
> validateRequired should differentiate between the disabled fields and the not 
> present fields.
> Please refer to the Comments by alk

-- 
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