On Thursday 01 June 2006 08:38, favo wrote: > > However, you can override the 'validate' method on a model, and you > > might be able to use that to do what you want (you will probably > > want a validate method that looks like this: > > > > class Category(models.Model): > > ## fields etc here > > def validate(self): > > error_dict = super(Category, self).validate() > > # Do your validation here, adding to 'error_dict' > > # and then: > > return error_dict > > How could these happen? > I see some code in change_stage, it will only call > errors = manipulator.get_validation_errors(new_data) > No one run the validate method of model?
Oh yeah, I was forgetting how this worked. There was discussion at one point about moving validation to the model, but I can't remember how far it progressed. Obviously not as far as getting the manipulators to work that way. Luke -- "Trouble: Luck can't last a lifetime, unless you die young." (despair.com) Luke Plant || L.Plant.98 (at) cantab.net || http://lukeplant.me.uk/ --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users -~----------~----~----~----~------~----~------~--~---