From e25a9c937a340628854b4c0d13d20bc092553b86 Mon Sep 17 00:00:00 2001 From: Pierre Sassoulas Date: Sat, 17 Jul 2021 20:00:40 +0200 Subject: [PATCH] Fix auto-created primary key used when not defining a primary key --- settings.py | 2 ++ survey/settings.py | 2 ++ 2 files changed, 4 insertions(+) diff --git a/settings.py b/settings.py index 7286b15a..9a8fd8e4 100644 --- a/settings.py +++ b/settings.py @@ -121,6 +121,8 @@ "rosetta", ) +DEFAULT_AUTO_FIELD='django.db.models.AutoField' + LOCALE_PATHS = (os.path.join(ROOT, "survey", "locale"),) LANGUAGE_CODE = "en-us" LANGUAGES = ( diff --git a/survey/settings.py b/survey/settings.py index fb5e1a84..f1bf62d9 100644 --- a/survey/settings.py +++ b/survey/settings.py @@ -49,6 +49,8 @@ INSTALLED_APPS = ("survey", "bootstrapform") +DEFAULT_AUTO_FIELD='django.db.models.AutoField' + LOCALE_PATHS = (Path(ROOT, "survey", "locale"),) LANGUAGE_CODE = "en" LANGUAGES = (