summaryrefslogtreecommitdiff
path: root/docs/ref
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2013-10-02 12:12:53 -0400
committerTim Graham <timograham@gmail.com>2013-10-02 12:12:53 -0400
commit75bb6ba96660e2a06e18d99120c05db2bb9fa9cc (patch)
treedf52d4b0266d6c2803f7b90b6e07f43b678ec848 /docs/ref
parente1b77238171cc96f4451a06fb4682e2378896238 (diff)
Fixed #10913 -- Documented how related_name affects QuerySet filtering
Thanks neithere for the suggestion.
Diffstat (limited to 'docs/ref')
-rw-r--r--docs/ref/models/fields.txt9
1 files changed, 5 insertions, 4 deletions
diff --git a/docs/ref/models/fields.txt b/docs/ref/models/fields.txt
index 248c630437..bcadf4d27a 100644
--- a/docs/ref/models/fields.txt
+++ b/docs/ref/models/fields.txt
@@ -1078,10 +1078,11 @@ define the details of how the relation works.
.. attribute:: ForeignKey.related_name
The name to use for the relation from the related object back to this one.
- See the :ref:`related objects documentation <backwards-related-objects>` for
- a full explanation and example. Note that you must set this value
- when defining relations on :ref:`abstract models
- <abstract-base-classes>`; and when you do so
+ It's also the default value for :attr:`related_query_name` (the name to use
+ for the reverse filter name from the target model). See the :ref:`related
+ objects documentation <backwards-related-objects>` for a full explanation
+ and example. Note that you must set this value when defining relations on
+ :ref:`abstract models <abstract-base-classes>`; and when you do so
:ref:`some special syntax <abstract-related-name>` is available.
If you'd prefer Django not to create a backwards relation, set