diff options
| author | Jacob Kaplan-Moss <jacob@jacobian.org> | 2009-04-02 00:01:15 +0000 |
|---|---|---|
| committer | Jacob Kaplan-Moss <jacob@jacobian.org> | 2009-04-02 00:01:15 +0000 |
| commit | 8f7aa84def3c13dd706aae1f5bfbcdb54b0696ee (patch) | |
| tree | 22de54063a57b0f50511bbc7d10c10415aac0ef3 /django/forms/models.py | |
| parent | 64e82fb648ebdd7c98fa5f1cffb1e21f1918cf4d (diff) | |
Fixed #9651: fixed save_as with inline forms. Thanks, kmike and Mnewman.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10353 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django/forms/models.py')
| -rw-r--r-- | django/forms/models.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/django/forms/models.py b/django/forms/models.py index d50a4705e8..7ca1ab5f73 100644 --- a/django/forms/models.py +++ b/django/forms/models.py @@ -530,6 +530,9 @@ class BaseInlineFormSet(BaseModelFormSet): # Remove the primary key from the form's data, we are only # creating new instances form.data[form.add_prefix(self._pk_field.name)] = None + + # Remove the foreign key from the form's data + form.data[form.add_prefix(self.fk.name)] = None return form #@classmethod |
