mirror of
https://github.com/django/django.git
synced 2025-10-28 08:06:09 +00:00
Fixed #35393 -- Added excluded pk as a hidden field to the inline admin.
This commit is contained in:
committed by
Sarah Boyce
parent
c7fc9f20b4
commit
2995aeab56
@@ -3,6 +3,7 @@ Testing of admin inline formsets.
|
||||
"""
|
||||
|
||||
import random
|
||||
import uuid
|
||||
|
||||
from django.contrib.contenttypes.fields import GenericForeignKey
|
||||
from django.contrib.contenttypes.models import ContentType
|
||||
@@ -399,3 +400,13 @@ class BothVerboseNameProfile(Profile):
|
||||
class Meta:
|
||||
verbose_name = "Model with both - name"
|
||||
verbose_name_plural = "Model with both - plural name"
|
||||
|
||||
|
||||
class UUIDParent(models.Model):
|
||||
pass
|
||||
|
||||
|
||||
class UUIDChild(models.Model):
|
||||
id = models.UUIDField(default=uuid.uuid4, primary_key=True)
|
||||
title = models.CharField(max_length=128)
|
||||
parent = models.ForeignKey(UUIDParent, on_delete=models.CASCADE)
|
||||
|
||||
Reference in New Issue
Block a user