1
0
mirror of https://github.com/django/django.git synced 2025-07-04 09:49:12 +00:00

[5.2.x] Fixed #36449 -- Fixed field types in example model using ForeignObject.

Backport of 59427547692b433bef3640a96cc0f6601f57532f from main.
This commit is contained in:
Jacob Walls 2025-06-08 10:16:22 -04:00 committed by Sarah Boyce
parent aec11dbb4c
commit 6f99c8856d

View File

@ -113,8 +113,8 @@ To work around this limitation, ``ForeignObject`` can be used as an
alternative::
class Foo(models.Model):
item_order_id = models.IntegerField()
item_product_id = models.CharField(max_length=20)
item_order_id = models.CharField(max_length=20)
item_product_id = models.IntegerField()
item = models.ForeignObject(
OrderLineItem,
on_delete=models.CASCADE,