It is probably hard/impossible to cover all the cases. s:errors outside of s:form would not be covered.
Plain JSP-input tags - hm, I guess one uses them only if you use 3-rd party GUI input tags, normally one should stick to Stripes input tags for repopulation and all the bells and whistles. The majority of cases I have seen are applications when s:errors is nested inside s:form and only Stripes input tags are used inside it (+ possibly some in-house GUI input widget tagfiles with Stripes input tags inside). When it is not possible to determine the error message order (the other mentioned cases), it cannot be any worse the current "scattered" behavior. The other option might be to provide some sort of a 'displayWeight' attribute to the @Validate annotation and displayWeight param to the getContext().getValidationErrors().add method for use in @ValidationMethod methods. This would cover the s:errors outside and inside of s:form cases. The case with plain JSP input tags cannot be probably easily covered. Just ideas, I have not really studied the validation API thoroughly. Jan > -----Puvodni zprava----- > Od: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] za > uzivatele Oscar Westra van Holthe - Kind > Odeslano: Friday, August 08, 2008 09:01 > Komu: Stripes Users List > Predmet: Re: [Stripes-users] Error Ordering > > > On 08-08-2008 at 08:54, Jan Moravec wrote: > > Maybe there is some reason why the following would not work, but ... > > > > The s:errors tag occurs inside the s:form tag and as such it had > > access to the parent form tag and its children tags such as > s:inputs > > etc. Then it is easy to iterate the form's children tags > and sort the > > errors collection according to the order of the children > s:input etc. > > tags. Would not this work? > > Were it not for the fact that the errors tag can occur > outside the form tag. And that input tags need not be > Stripes/JSP input tags (but plain HTML), and thus may be > invisible to a JSP tag. > > > Oscar > > -- > ,-_ Anything in parenthesis can (not) be ignored. > /() ) > (__ ( > =/ () > > -------------------------------------------------------------- > ----------- > This SF.Net email is sponsored by the Moblin Your Move > Developer's challenge Build the coolest Linux based > applications with Moblin SDK & win great prizes Grand prize > is a trip for two to an Open Source event anywhere in the > world http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Stripes-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/stripes-users ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Stripes-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/stripes-users
