mirror of
https://github.com/django/django.git
synced 2025-08-04 10:59:45 +00:00
Removed unnecessary code-block directives.
This commit is contained in:
parent
fa02120d36
commit
9d6551204e
32 changed files with 161 additions and 308 deletions
|
@ -554,9 +554,7 @@ Using a formset in views and templates
|
|||
|
||||
Using a formset inside a view is as easy as using a regular ``Form`` class.
|
||||
The only thing you will want to be aware of is making sure to use the
|
||||
management form inside the template. Let's look at a sample view:
|
||||
|
||||
.. code-block:: python
|
||||
management form inside the template. Let's look at a sample view::
|
||||
|
||||
from django.forms.formsets import formset_factory
|
||||
from django.shortcuts import render_to_response
|
||||
|
@ -633,9 +631,7 @@ You are able to use more than one formset in a view if you like. Formsets
|
|||
borrow much of its behavior from forms. With that said you are able to use
|
||||
``prefix`` to prefix formset form field names with a given value to allow
|
||||
more than one formset to be sent to a view without name clashing. Lets take
|
||||
a look at how this might be accomplished:
|
||||
|
||||
.. code-block:: python
|
||||
a look at how this might be accomplished::
|
||||
|
||||
from django.forms.formsets import formset_factory
|
||||
from django.shortcuts import render_to_response
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue