That's a good question. Thinking out loud Maybe set the session.addError and pass it a keyPath and value and then in the appendToResponse do some magic?
or brute force a bunch of class methods to check for the existence of the keypath? James On Feb 11, 2013, at 2:14 PM, Johnny Miller <[email protected]> wrote: > Hi, > > I was wondering if anyone has an example of how to do the following: > > Using this method... > > public void validationFailedWithException(Throwable exception, Object value, > String keyPath) { > super.validationFailedWithException(exception, value, keyPath); > session().addError(exception.getMessage()); > } > > I would like to put exception.getMessage in a mutable dictionary with keypath > as the key. Easy enough. Then I'd like to print out the error messages on > the page. Easy enough. Then I'd like to add a css class name to the > input(s) that failed validation (without using D2w)?? I imagine that's where > keypath would come in handy but I'm not sure how to connect the key path to > the input? > > Thanks in advance, > > Johnny > > > On Feb 11, 2013, at 8:21 AM, James Cicenia <[email protected]> wrote: > >> Should probably just be named "Validation." All the EOF stuff threw me off >> for a while. >> >> http://wiki.wocommunity.org/display/documentation/EOF-Using+EOF-Validation >> >> >> _______________________________________________ >> Do not post admin requests to the list. They will be ignored. >> Webobjects-dev mailing list ([email protected]) >> Help/Unsubscribe/Update your Subscription: >> https://lists.apple.com/mailman/options/webobjects-dev/jlmiller%40kahalawai.com >> >> This email sent to [email protected] > > _______________________________________________ > Do not post admin requests to the list. They will be ignored. > Webobjects-dev mailing list ([email protected]) > Help/Unsubscribe/Update your Subscription: > https://lists.apple.com/mailman/options/webobjects-dev/james%40jimijon.com > > This email sent to [email protected] James Cicenia Founder / CEO Direct: (773) 398-4649 Mail: [email protected]
_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list ([email protected]) Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [email protected]
