Okay. All that you need to do is create a new Validator inheriting from DefaultValidator that will do what you want. You validation code will go in doAssertValidity().
If the call to group.isAllValid() works, then just get the object and map to to the group. You will not have to get the field and the validator objects. I know of no problems with Intake redisplaying the data. If you run into this, please let me know. > -----Original Message----- > From: Marc Lustig [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, January 15, 2003 4:57 PM > To: Turbine Users List > Subject: AW: Intake question: how to add custum rule functions ? > > > > Out of curiousity, what sort of rules are you wanting to add > > dynamically? > > For now what I need is to look up in another table if the > data entered into the field exists or not. If it exists, I > need the PK of that corresponding row to set in the > object/property that is mapped to the field. (I suspect that > will not work using group.setProperties(myBO), but I guess I > can set it explicitly afterwards.) > > If the field doesn't exist, the validation should fail and > the page redisplayed with all the values that were previously > entered. Btw, is that working with current Intake? I read on > the list that Intakte won't redisplay the data properly. > > Not quite sure what you mean with "dynamically". I need the > same rule everytime I validate using this Group. Not sure > what is dynamic about that... > > > Marc > > > -- > To unsubscribe, e-mail: > <mailto:turbine-user-> [EMAIL PROTECTED]> > For > additional commands, > e-mail: <mailto:[EMAIL PROTECTED]> > > -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
