summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2019-11-04 11:57:53 +0100
committerMariusz Felisiak <felisiak.mariusz@gmail.com>2019-11-05 08:40:38 +0100
commita7f90d9c02f5ed6f6dc1621ef10b9db1f042600b (patch)
treead6db9631a57b06f9a22e2a4d8c1cf5877227d3f
parent24a0ce187a1a337fb7e4686d0c8902dcffa9cec4 (diff)
[2.2.x] Refs #30947 -- Changed tuples to lists in model Meta options examples in docs.
Follow up to 97d3321e89c8d4434927bdbc308db1ccffa99d3b. Backport of e5cacb1f47cb3a2943bbc7685a630c84503b0d1b from master
-rw-r--r--docs/topics/db/examples/many_to_many.txt4
-rw-r--r--docs/topics/db/examples/many_to_one.txt2
2 files changed, 3 insertions, 3 deletions
diff --git a/docs/topics/db/examples/many_to_many.txt b/docs/topics/db/examples/many_to_many.txt
index 922dc977a4..752abe9f72 100644
--- a/docs/topics/db/examples/many_to_many.txt
+++ b/docs/topics/db/examples/many_to_many.txt
@@ -18,7 +18,7 @@ objects, and a ``Publication`` has multiple ``Article`` objects:
title = models.CharField(max_length=30)
class Meta:
- ordering = ('title',)
+ ordering = ['title']
def __str__(self):
return self.title
@@ -28,7 +28,7 @@ objects, and a ``Publication`` has multiple ``Article`` objects:
publications = models.ManyToManyField(Publication)
class Meta:
- ordering = ('headline',)
+ ordering = ['headline']
def __str__(self):
return self.headline
diff --git a/docs/topics/db/examples/many_to_one.txt b/docs/topics/db/examples/many_to_one.txt
index 8a77d89d6d..6c07b5a45d 100644
--- a/docs/topics/db/examples/many_to_one.txt
+++ b/docs/topics/db/examples/many_to_one.txt
@@ -23,7 +23,7 @@ To define a many-to-one relationship, use :class:`~django.db.models.ForeignKey`:
return self.headline
class Meta:
- ordering = ('headline',)
+ ordering = ['headline']
What follows are examples of operations that can be performed using the Python
API facilities.