From 80f5a4d87a6068efe7c04bd9436f0293fbbb4db3 Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Mon, 10 Oct 2016 15:36:21 -0400 Subject: [PATCH] Doc'd the need to provide initial for formset submissions. --- docs/topics/forms/formsets.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/topics/forms/formsets.txt b/docs/topics/forms/formsets.txt index 3cae784dcc..f1419b6a92 100644 --- a/docs/topics/forms/formsets.txt +++ b/docs/topics/forms/formsets.txt @@ -80,6 +80,11 @@ There are now a total of three forms showing above. One for the initial data that was passed in and two extra forms. Also note that we are passing in a list of dictionaries as the initial data. +If you use an ``initial`` for displaying a formset, you should pass the same +``initial`` when processing that formset's submission so that the formset can +detect which forms were changed by the user. For example, you might have +something like: ``ArticleFormSet(request.POST, initial=[...])``. + .. seealso:: :ref:`Creating formsets from models with model formsets `.