Ticket #4384: new_form.diff
File new_form.diff, 620 bytes (added by , 17 years ago) |
---|
-
django/newforms/forms.py
12 12 from widgets import TextInput, Textarea 13 13 from util import flatatt, ErrorDict, ErrorList, ValidationError 14 14 15 __all__ = ('BaseForm', 'Form' )15 __all__ = ('BaseForm', 'Form', 'new_form') 16 16 17 17 NON_FIELD_ERRORS = '__all__' 18 18 … … 319 319 return self.html_name 320 320 return '' 321 321 auto_id = property(_auto_id) 322 323 def new_form(klass=Form): 324 return type('New%s' % klass.__name__, (klass,), {})