formclass= argument will get optional in Django 1.8

This commit is contained in:
Raphael Michel
2015-02-18 22:07:08 +01:00
parent 1e7d839731
commit e266b0438c

View File

@@ -492,7 +492,7 @@ class QuotaEditorMixin:
def items(self) -> "List[Item]":
return list(self.request.event.items.all().prefetch_related("properties", "variations"))
def get_form(self, form_class):
def get_form(self, form_class=QuotaForm):
if not hasattr(self, '_form'):
kwargs = self.get_form_kwargs()
kwargs['items'] = self.items