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 /django/db/backends/postgresql/creation.py | |
parent | 973f44aa4c953baf6bf56b8e5c474f5306452809 (diff) | |
download | django-212ee65be782240554749f25bbd3772240d56fff.tar.gz |
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 'django/db/backends/postgresql/creation.py')
-rw-r--r-- | django/db/backends/postgresql/creation.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/django/db/backends/postgresql/creation.py b/django/db/backends/postgresql/creation.py index fde094de7f..ceffea19e6 100644 --- a/django/db/backends/postgresql/creation.py +++ b/django/db/backends/postgresql/creation.py @@ -5,8 +5,8 @@ DATA_TYPES = { 'AutoField': 'serial', 'BooleanField': 'boolean', - 'CharField': 'varchar(%(maxlength)s)', - 'CommaSeparatedIntegerField': 'varchar(%(maxlength)s)', + 'CharField': 'varchar(%(max_length)s)', + 'CommaSeparatedIntegerField': 'varchar(%(max_length)s)', 'DateField': 'date', 'DateTimeField': 'timestamp with time zone', 'DecimalField': 'numeric(%(max_digits)s, %(decimal_places)s)', @@ -21,7 +21,7 @@ DATA_TYPES = { 'PhoneNumberField': 'varchar(20)', 'PositiveIntegerField': 'integer CHECK ("%(column)s" >= 0)', 'PositiveSmallIntegerField': 'smallint CHECK ("%(column)s" >= 0)', - 'SlugField': 'varchar(%(maxlength)s)', + 'SlugField': 'varchar(%(max_length)s)', 'SmallIntegerField': 'smallint', 'TextField': 'text', 'TimeField': 'time', |