1
0
mirror of https://github.com/django/django.git synced 2025-06-05 03:29:12 +00:00

[3.2.x] Fixed #32372 -- Made examples in related objects reference docs consistent.

Backport of 725c549ae7a34d83447201da7190f8d71c7fc2fc from master
This commit is contained in:
Jack Aitken 2021-01-21 21:04:39 -05:00 committed by Mariusz Felisiak
parent e45b944d69
commit 59c63c7f6b

View File

@ -14,12 +14,12 @@ Related objects reference
from django.db import models from django.db import models
class Reporter(models.Model): class Blog(models.Model):
# ... # ...
pass pass
class Article(models.Model): class Entry(models.Model):
reporter = models.ForeignKey(Reporter, on_delete=models.CASCADE) blog = models.ForeignKey(Blog, on_delete=models.CASCADE, null=True)
In the above example, the methods below will be available on In the above example, the methods below will be available on
the manager ``reporter.article_set``. the manager ``reporter.article_set``.