You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "Howard M. Lewis Ship (JIRA)" <ta...@jakarta.apache.org> on 2005/09/30 19:56:51 UTC

[jira] Assigned: (TAPESTRY-622) ValidationDelegate: easy way to add anussociated error

     [ http://issues.apache.org/jira/browse/TAPESTRY-622?page=all ]

Howard M. Lewis Ship reassigned TAPESTRY-622:
---------------------------------------------

    Assign To: Howard M. Lewis Ship

> ValidationDelegate: easy way to add anussociated error
> ------------------------------------------------------
>
>          Key: TAPESTRY-622
>          URL: http://issues.apache.org/jira/browse/TAPESTRY-622
>      Project: Tapestry
>         Type: Improvement
>   Components: Framework
>     Versions: 4.0
>     Reporter: Alexander Kundirenko
>     Assignee: Howard M. Lewis Ship

>
> Is there an easy way to add unassociated error to ValidationDelegate?
> For example - I have save() listener on my form:
> public void save() {
>     
>     //make some non-trivial validation
>     if(!validateObject()) {
>         getDelegate().record("Error message", null);
>     }    
>      
>     if( getDelegate().getHasErrors()) {
>          return;
>     }
>     
>     //do smth
>      ....
> }
> Actually  recorder message IS NOT unassoociated, it associated with last Field.
> because:
>   public void record(IRender errorRenderer, ValidationConstraint constraint)
>     {
>         FieldTracking tracking = findCurrentTracking(); //LAST FORM FIELD IS RETURNED
>         ...      
>     }
> To make it unassociated I have to call ValidationDelegate.clear() and record my error after that.
> In this case it becomes really  unassociated but  all other erros are lost.
> Could you add easy and intuitively obvious way to add unassociated trackings, like:
>     void recordUnassociated(String errorMessage);
> ?
> Thank you

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-dev-help@jakarta.apache.org