Fixed #2508 -- Added back support for custom edit_inline classes. Thanks,

jkocherhans.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@3801 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Malcolm Tredinnick 2006-09-23 10:02:16 +00:00
parent bd4c22be0b
commit e8b572b912
1 changed files with 3 additions and 1 deletions

View File

@ -160,8 +160,10 @@ class EditInlineNode(template.Node):
context.push()
if relation.field.rel.edit_inline == models.TABULAR:
bound_related_object_class = TabularBoundRelatedObject
else:
elif relation.field.rel.edit_inline == models.STACKED:
bound_related_object_class = StackedBoundRelatedObject
else:
bound_related_object_class = relation.field.rel.edit_inline
original = context.get('original', None)
bound_related_object = relation.bind(context['form'], original, bound_related_object_class)
context['bound_related_object'] = bound_related_object