1
0
mirror of https://github.com/django/django.git synced 2025-10-24 22:26:08 +00:00

newforms: Changed Form to use auto_id by default

git-svn-id: http://code.djangoproject.com/svn/django/trunk@4192 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Adrian Holovaty
2006-12-11 02:38:18 +00:00
parent 5c8d789efe
commit 05588b3797
2 changed files with 93 additions and 93 deletions

View File

@@ -36,7 +36,7 @@ class Form(StrAndUnicode):
"A collection of Fields, plus their associated data."
__metaclass__ = DeclarativeFieldsMetaclass
def __init__(self, data=None, auto_id=False): # TODO: prefix stuff
def __init__(self, data=None, auto_id='id_%s'): # TODO: prefix stuff
self.ignore_errors = data is None
self.data = data or {}
self.auto_id = auto_id