diff --git a/README.md b/README.md index 6abe0b44..7e0fa3c7 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,24 @@ Expomap project -### proj/local.py EXAMPLE +### proj/local.py PRODUCTION EXAMPLE +```python +# -*- coding: utf-8 -*- +from settings import * + +DEBUG = False + +INSTALLED_APPS += ( + 'raven.contrib.django.raven_compat', +) +RAVEN_CONFIG = { + 'dsn': 'http://474617c96350412d80735900c6717b9a:330285c9034947a181cbae8b52bb15d8@88.198.17.35:9000/3', + 'release': raven.fetch_git_sha(os.path.dirname(os.pardir)), +} +``` + + +### proj/local.py DEV EXAMPLE ```python # -*- coding: utf-8 -*- from settings import * diff --git a/apps/city/search_indexes_.py b/apps/city/search_indexes.py similarity index 100% rename from apps/city/search_indexes_.py rename to apps/city/search_indexes.py diff --git a/apps/company/search_indexes_.py b/apps/company/search_indexes.py similarity index 100% rename from apps/company/search_indexes_.py rename to apps/company/search_indexes.py diff --git a/apps/django_messages/admin.py b/apps/django_messages/admin.py index d0f7bd50..97bfdcaf 100644 --- a/apps/django_messages/admin.py +++ b/apps/django_messages/admin.py @@ -61,7 +61,7 @@ class MessageAdmin(admin.ModelAdmin): }), ) list_display = ('subject', 'sender', 'recipient', 'sent_at', 'read_at') - list_filter = ('sent_at', 'sender', 'recipient') + list_filter = ('sent_at',) search_fields = ('subject', 'body') raw_id_fields = ('sender', 'recipient', 'parent_msg') diff --git a/proj/settings.py b/proj/settings.py index b314c31c..54b9f09c 100644 --- a/proj/settings.py +++ b/proj/settings.py @@ -399,7 +399,6 @@ INSTALLED_APPS = ( 'south', 'rosetta', 'widget_tweaks', - 'raven.contrib.django.raven_compat', ) CRONJOBS = [ @@ -526,47 +525,7 @@ PERIODIC = { 9: _(u'Раз в 5 лет') } -# sentry -RAVEN_CONFIG = { - 'dsn': 'http://474617c96350412d80735900c6717b9a:330285c9034947a181cbae8b52bb15d8@88.198.17.35:9000/3', - 'release': raven.fetch_git_sha(os.path.dirname(os.pardir)), -} - try: from proj.local import * except ImportError, e: pass - -# logging -U_LOGFILE_SIZE = 1 * 1024 * 1024 -U_LOGFILE_COUNT = 2 -DEFAULT_LOGGER_NAME = 'django' -LOGGING = { - 'version': 1, - 'disable_existing_loggers': False, - 'formatters': { - 'verbose': { - 'format': '%(levelname)s %(asctime)s %(module)s %(process)d %(thread)d %(message)s \n' - }, - 'simple': { - 'format': '%(levelname)s %(message)s' - }, - }, - 'handlers': { - 'file': { - 'level': 'INFO', - 'filename': os.path.join(SITE_ROOT, 'logs/django.log'), - 'formatter': 'verbose', - 'class':'logging.handlers.RotatingFileHandler', - 'maxBytes': U_LOGFILE_SIZE, - 'backupCount': U_LOGFILE_COUNT, - }, - }, - 'loggers': { - 'django': { - 'handlers': ['file'], - 'propagate': True, - 'level': 'DEBUG', - }, - } -}