From a199e4076433fb909b06662012454477687c5e5c Mon Sep 17 00:00:00 2001 From: Jan Szejko Date: Thu, 19 Jan 2017 13:34:32 +0100 Subject: [PATCH 1/1] add constance --- redakcja/settings/__init__.py | 8 ++++++++ redakcja/settings/common.py | 2 ++ requirements.txt | 1 + 3 files changed, 11 insertions(+) diff --git a/redakcja/settings/__init__.py b/redakcja/settings/__init__.py index 2d04c8dc..68a2c2f5 100644 --- a/redakcja/settings/__init__.py +++ b/redakcja/settings/__init__.py @@ -18,6 +18,14 @@ DATABASES = { } } +CONSTANCE_CONFIG = { + 'NOTIFY_EMAIL': ('zofia.radziwill@nowoczesnapolska.org.pl', + 'e-mail address for notifications about new organizations and published projects'), +} + +CONSTANCE_BACKEND = 'constance.backends.database.DatabaseBackend' + + LOGGING_CONFIG_FILE = os.path.join(PROJECT_ROOT, 'config', ('logging.cfg' if not DEBUG else 'logging.cfg.dev')) try: import logging diff --git a/redakcja/settings/common.py b/redakcja/settings/common.py index c32b6ad9..e2a0a2d9 100644 --- a/redakcja/settings/common.py +++ b/redakcja/settings/common.py @@ -126,6 +126,8 @@ INSTALLED_APPS = ( 'fileupload', 'pipeline', 'modeltranslation', + 'constance', + 'constance.backends.database', 'catalogue', # 'cover', diff --git a/requirements.txt b/requirements.txt index c3e61b2d..3941b77b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -24,6 +24,7 @@ django-forms-bootstrap jsonfield django-email-extras django-modeltranslation>=0.12,<0.13 +django-constance[database] celery>=3.1.12,<3.2 kombu>3.0,<3.1 -- 2.20.1