mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Fixed #18468 -- Added support for comments on columns and tables.
Thanks Jared Chung, Tom Carrick, David Smith, Nick Pope, and Mariusz Felisiak for reviews. Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com> Co-authored-by: Nick Pope <nick@nickpope.me.uk>
This commit is contained in:
committed by
Mariusz Felisiak
parent
68ef274bc5
commit
78f163a4fb
@@ -102,3 +102,11 @@ class UniqueConstraintConditionModel(models.Model):
|
||||
condition=models.Q(color__isnull=True),
|
||||
),
|
||||
]
|
||||
|
||||
|
||||
class DbCommentModel(models.Model):
|
||||
name = models.CharField(max_length=15, db_comment="'Name' column comment")
|
||||
|
||||
class Meta:
|
||||
db_table_comment = "Custom table comment"
|
||||
required_db_features = {"supports_comments"}
|
||||
|
||||
Reference in New Issue
Block a user