From e8e5904b90d28bef0bc4f3c935dacc7cbf280560 Mon Sep 17 00:00:00 2001 From: ladeng07 <40017222+ladeng07@users.noreply.github.com> Date: Thu, 5 May 2022 22:47:03 +0800 Subject: [PATCH] gggg --- .idea/ITShowPlatform.iml | 4 +-- .idea/misc.xml | 4 +-- .idea/workspace.xml | 65 ++++++++++++++++++++++++-------------- ITShowPlatform/settings.py | 11 ++++--- 4 files changed, 51 insertions(+), 33 deletions(-) diff --git a/.idea/ITShowPlatform.iml b/.idea/ITShowPlatform.iml index 90cd6d8..ef0e183 100644 --- a/.idea/ITShowPlatform.iml +++ b/.idea/ITShowPlatform.iml @@ -16,10 +16,10 @@ - + - \ No newline at end of file + diff --git a/.idea/misc.xml b/.idea/misc.xml index 6649a8c..a11f6b5 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -3,5 +3,5 @@ - - \ No newline at end of file + + diff --git a/.idea/workspace.xml b/.idea/workspace.xml index fe3c390..2ae2d14 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -26,13 +26,17 @@ - + - - + + + + + + @@ -228,7 +240,7 @@ - @@ -247,13 +259,14 @@ - - + - + @@ -266,6 +279,10 @@ + + + + @@ -282,22 +299,22 @@ - + - - + + - - + + - - + + - + @@ -326,10 +343,10 @@ - + - + @@ -348,6 +365,6 @@ - + \ No newline at end of file diff --git a/ITShowPlatform/settings.py b/ITShowPlatform/settings.py index 48835e4..893c75a 100644 --- a/ITShowPlatform/settings.py +++ b/ITShowPlatform/settings.py @@ -17,11 +17,16 @@ import configparser # Build paths inside the project like this: BASE_DIR / 'subdir'. BASE_DIR = Path(__file__).resolve().parent.parent +conf = configparser.RawConfigParser() + +conf.read(str(BASE_DIR)+r"\ITShowPlatform\config.ini",encoding="utf-8") + + # Quick-start development settings - unsuitable for production # See https://docs.djangoproject.com/en/4.0/howto/deployment/checklist/ # SECURITY WARNING: keep the secret key used in production secret! -SECRET_KEY = 'django-insecure-0cn#v4ei2(^n+txyh4%3d5sllz6mknz#7t$!cq-d!ly*_rwvh2' +SECRET_KEY = conf.get("Django","SECRET_KEY") # SECURITY WARNING: don't run with debug turned on in production! DEBUG = True @@ -30,10 +35,6 @@ ALLOWED_HOSTS = ["*"] # Application definition -conf = configparser.ConfigParser() - -conf.read(str(BASE_DIR)+r"\ITShowPlatform\config.ini",encoding="utf-8") - INSTALLED_APPS = [