diff options
| author | Gary Wilson Jr <gary.wilson@gmail.com> | 2007-08-05 05:14:46 +0000 |
|---|---|---|
| committer | Gary Wilson Jr <gary.wilson@gmail.com> | 2007-08-05 05:14:46 +0000 |
| commit | 212ee65be782240554749f25bbd3772240d56fff (patch) | |
| tree | 81ac3c9ae0c49d6ee1854b54fbc79a18069edc5f /tests/modeltests/m2m_multiple/models.py | |
| parent | 973f44aa4c953baf6bf56b8e5c474f5306452809 (diff) | |
Fixed #2101 -- Renamed `maxlength` argument to `max_length` for oldforms `FormField`s and db model `Field`s. This is fully backwards compatible at the moment since the legacy `maxlength` argument is still supported. Using `maxlength` will, however, issue a `PendingDeprecationWarning` when used.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5803 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'tests/modeltests/m2m_multiple/models.py')
| -rw-r--r-- | tests/modeltests/m2m_multiple/models.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/modeltests/m2m_multiple/models.py b/tests/modeltests/m2m_multiple/models.py index 78c35aafc2..26a0a2e798 100644 --- a/tests/modeltests/m2m_multiple/models.py +++ b/tests/modeltests/m2m_multiple/models.py @@ -10,7 +10,7 @@ Set ``related_name`` to designate what the reverse relationship is called. from django.db import models class Category(models.Model): - name = models.CharField(maxlength=20) + name = models.CharField(max_length=20) class Meta: ordering = ('name',) @@ -18,7 +18,7 @@ class Category(models.Model): return self.name class Article(models.Model): - headline = models.CharField(maxlength=50) + headline = models.CharField(max_length=50) pub_date = models.DateTimeField() primary_categories = models.ManyToManyField(Category, related_name='primary_article_set') secondary_categories = models.ManyToManyField(Category, related_name='secondary_article_set') |
