File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change 1818from pathlib import Path
1919from urllib .parse import urlparse
2020import django .conf .locale
21+ from django .contrib .messages import constants as messages # NOQA
2122from django .utils .translation import gettext_lazy as _
2223from django .utils .crypto import get_random_string
2324from kombu import Queue
@@ -899,7 +900,13 @@ def instance_name(request):
899900CSP_DEFAULT_SRC = ("'self'" , "'unsafe-eval'" )
900901SECURE_PROXY_SSL_HEADER = ("HTTP_X_FORWARDED_PROTO" , "https" )
901902
902- MESSAGE_STORAGE = "django.contrib.messages.storage.session.SessionStorage"
903+ MESSAGE_TAGS = {
904+ messages .INFO : 'alert-info' ,
905+ messages .ERROR : 'alert-danger' ,
906+ messages .WARNING : 'alert-warning' ,
907+ messages .SUCCESS : 'alert-success' ,
908+ }
909+ MESSAGE_STORAGE = 'django.contrib.messages.storage.session.SessionStorage'
903910
904911# Template configuration
905912template_loaders = (
You can’t perform that action at this time.
0 commit comments