Fixed #23656 -- Made FormMixin.get_form's form_class argument optional.

Thanks Tim Graham for the review.
This commit is contained in:
Simon Charette 2014-10-14 14:56:39 -04:00
parent 19242c675f
commit f2ddc439b1
6 changed files with 93 additions and 11 deletions

View file

@ -49,10 +49,15 @@ FormMixin
Retrieve the form class to instantiate. By default
:attr:`.form_class`.
.. method:: get_form(form_class)
.. method:: get_form(form_class=None)
Instantiate an instance of ``form_class`` using
:meth:`~django.views.generic.edit.FormMixin.get_form_kwargs`.
If ``form_class`` isn't provided :meth:`get_form_class` will be used.
.. versionchanged:: 1.8
The ``form_class`` argument is not required anymore.
.. method:: get_form_kwargs()