Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

[1.5.X] Fixed #19402 - Clarified purpose of CustomUser.REQUIRED_FIELDS

Thanks pydanny for the report and ptone for the patch.

Backport of 24a2bcb from master
  • Loading branch information...
commit 1702be89c86d1b1a01efb16fa7836335ad709184 1 parent d1e87eb
Tim Graham authored February 23, 2013

Showing 1 changed file with 10 additions and 3 deletions. Show diff stats Hide diff stats

  1. 13  docs/topics/auth/customizing.txt
13  docs/topics/auth/customizing.txt
@@ -501,9 +501,16 @@ password resets. You must then provide some key implementation details:
501 501
 
502 502
     .. attribute:: REQUIRED_FIELDS
503 503
 
504  
-        A list of the field names that *must* be provided when creating
505  
-        a user. For example, here is the partial definition for a User model
506  
-        that defines two required fields - a date of birth and height::
  504
+        A list of the field names that *must* be provided when creating a user
  505
+        via the :djadmin:`createsuperuser` management command. The user will be
  506
+        prompted to supply a value for each of these fields. It should include
  507
+        any field for which :attr:`~django.db.models.Field.blank` is ``False``
  508
+        or undefined, but may include additional fields you want prompted for
  509
+        when a user is created interactively. However, it will not work for
  510
+        :class:`~django.db.models.ForeignKey` fields.
  511
+
  512
+        For example, here is the partial definition for a ``User`` model that
  513
+        defines two required fields - a date of birth and height::
507 514
 
508 515
             class MyUser(AbstractBaseUser):
509 516
                 ...

0 notes on commit 1702be8

Please sign in to comment.
Something went wrong with that request. Please try again.