summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2013-09-06 16:01:29 -0400
committerTim Graham <timograham@gmail.com>2013-09-06 16:01:29 -0400
commitdb3de528071ac66903f82c2fe5b34db4a5281f5b (patch)
treef084956ed64111aa289cdd18a04ee3c70784ce63 /docs
parentdf462cf7604578c2afd43b988b7ea1fe5e727896 (diff)
Fixed #20646 -- Clarified the use of AbstractBaseUser.REQUIRED_FIELDS
Thanks craigbruce.
Diffstat (limited to 'docs')
-rw-r--r--docs/topics/auth/customizing.txt16
1 files changed, 9 insertions, 7 deletions
diff --git a/docs/topics/auth/customizing.txt b/docs/topics/auth/customizing.txt
index 746e92e637..bb44f091fe 100644
--- a/docs/topics/auth/customizing.txt
+++ b/docs/topics/auth/customizing.txt
@@ -470,13 +470,15 @@ password resets. You must then provide some key implementation details:
.. attribute:: REQUIRED_FIELDS
- A list of the field names that *must* be provided when creating a user
- via the :djadmin:`createsuperuser` management command. The user will be
- prompted to supply a value for each of these fields. It should include
- any field for which :attr:`~django.db.models.Field.blank` is ``False``
- or undefined, but may include additional fields you want prompted for
- when a user is created interactively. However, it will not work for
- :class:`~django.db.models.ForeignKey` fields.
+ A list of the field names that will be prompted for when creating a
+ user via the :djadmin:`createsuperuser` management command. The user
+ will be prompted to supply a value for each of these fields. It must
+ include any field for which :attr:`~django.db.models.Field.blank` is
+ ``False`` or undefined and may include additional fields you want
+ prompted for when a user is created interactively. However, it will not
+ work for :class:`~django.db.models.ForeignKey` fields.
+ ``REQUIRED_FIELDS`` has no effect in other parts of Django, like
+ creating a user in the admin.
For example, here is the partial definition for a ``User`` model that
defines two required fields - a date of birth and height::