Fixed #12700 - Take read-only fields into account when rendering the empty form for dynamic inlines.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12368 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Jannis Leidel 2010-02-01 14:13:47 +00:00
parent be90eadfb9
commit f70a0882a3
1 changed files with 2 additions and 2 deletions

View File

@ -196,9 +196,9 @@ class InlineAdminFormSet(object):
yield InlineAdminForm(self.formset, form, self.fieldsets,
self.opts.prepopulated_fields, None, self.readonly_fields,
model_admin=self.model_admin)
yield InlineAdminForm(self.formset, self.formset.empty_form,
self.fieldsets, self.opts.prepopulated_fields, None)
self.fieldsets, self.opts.prepopulated_fields, None,
self.readonly_fields, model_admin=self.model_admin)
def fields(self):
fk = getattr(self.formset, "fk", None)