def isRequired(self, field_data, all_data): if not field_data: raise validators.ValidationError("please fill in data.")
isRequired.always_test = True Am 11.09.2006 um 16:44 schrieb [EMAIL PROTECTED]: > > Hi all, > > I have a custom manipulator like this : > > ... > forms.TextField > (field_name="username",length=30,maxlength=30,is_required=True,validat > or_list=[validators.isAlphaNumeric]) > ... > > does anyone know how I can define a specific error message for > "is_required" function, without changing the code in forms.py? > > I do want to have e.g. "please fill in data" instead of the standard > message: "this field is required" > It even would not work if I write a new validator like > > ... > def isNotEmpty(self, field_data, all_data): > if field_data == "": > raise validators.ValidationError("please fill in data") > ... > > how can I manage this? > > Greetz > Qingsong > > > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---