mirror of
https://github.com/django/django.git
synced 2025-08-03 02:23:12 +00:00
Forms in model formsets and inline formsets can now be deleted even if they don't validate. Related to #9587.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10283 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
98f5f68463
commit
15becf23a9
6 changed files with 191 additions and 15 deletions
|
@ -13,6 +13,19 @@ class Child(models.Model):
|
|||
school = models.ForeignKey(School)
|
||||
name = models.CharField(max_length=100)
|
||||
|
||||
class Poet(models.Model):
|
||||
name = models.CharField(max_length=100)
|
||||
|
||||
def __unicode__(self):
|
||||
return self.name
|
||||
|
||||
class Poem(models.Model):
|
||||
poet = models.ForeignKey(Poet)
|
||||
name = models.CharField(max_length=100)
|
||||
|
||||
def __unicode__(self):
|
||||
return self.name
|
||||
|
||||
__test__ = {'API_TESTS': """
|
||||
|
||||
>>> from django.forms.models import inlineformset_factory
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue