File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,20 @@ Configuring Django's contrib apps
55Generally, Django's contribs app work out of the box, but here are some
66required adjustments.
77
8+ Apps with models
9+ ================
10+
11+ Each contrib app that has models that use :class: `~django.db.models.AutoField `
12+ (:mod: `~django.contrib.admin `, :mod: `~django.contrib.auth `,
13+ :mod: `~django.contrib.contenttypes `, :mod: `~django.contrib.flatpages `,
14+ :mod: `~django.contrib.redirects `, and :mod: `~django.contrib.sites `) must:
15+
16+ #. Be configured with an ``AppConfig `` that specifies
17+ ``default_auto_field = "django_mongodb_backend.fields.ObjectIdAutoField" ``.
18+ See :ref: `specifying the-default-pk-field `.
19+ #. Have migrations that use :class: `.ObjectIdAutoField `. See
20+ :ref: `configuring-migrations `.
21+
822``contrib.sites ``
923=================
1024
Original file line number Diff line number Diff line change @@ -53,6 +53,8 @@ Each app reference in the :setting:`INSTALLED_APPS` setting must point to the
5353corresponding ``AppConfig ``. For example, instead of ``'django.contrib.admin' ``,
5454the template uses ``'<project_name>.apps.MongoAdminConfig' ``.
5555
56+ .. _configuring-migrations :
57+
5658Configuring migrations
5759======================
5860
You can’t perform that action at this time.
0 commit comments