tapestry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Geoff Callender (JIRA)" <j...@apache.org>
Subject [jira] Created: (TAP5-812) The documentation shows doing validation in onSuccess()
Date Tue, 11 Aug 2009 23:20:14 GMT
The documentation shows doing validation in onSuccess()
-------------------------------------------------------

                 Key: TAP5-812
                 URL: https://issues.apache.org/jira/browse/TAP5-812
             Project: Tapestry 5
          Issue Type: Bug
          Components: documentation
    Affects Versions: 5.1.0.5
            Reporter: Geoff Callender


The example in http://tapestry.apache.org/tapestry5/guide/validation.html has to be fixed
inline with TAPESTRY-1972 .

Instead of this...

    String onSuccess()
    {
        if (!authenticator.isValid(userName, password))
        {
            form.recordError(passwordField, "Invalid user name or password.");
            return null;
        }

        return "PostLogin";
    }

...it should be...

   String onValidateForm()
   {
       if (!authenticator.isValid(userName, password))
       {
           form.recordError(passwordField, "Invalid user name or password.");
       }
   }

   String onSuccess()
   {
       return "PostLogin";
   }


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


Mime
View raw message