-
Notifications
You must be signed in to change notification settings - Fork 246
/
UPGRADING
70 lines (48 loc) · 1.63 KB
/
UPGRADING
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
========================================
Upgrading django-messages 0.4.x to 0.5.x
========================================
To Upgrade from django-messages 0.4.x to django-messages 0.5.x the following
changes might be neccessary in your project.
Settings
--------
To avoid name clashes with the new django.contrib.messages app (new in Django 1.2)
the django-messages python module was renamed from ``messages`` to ``django_messages``.
This makes a change of the INSTALLED_APPS setting neccessary:
Old::
INSTALLED_APPS = (
...
'messages',
...
)
New::
INSTALLED_APPS = (
...
'django_messages',
...
)
If you are using the ``inbox`` context processor, the TEMPLATE_CONTEXT_PROCESSORS
setting also needs to be changed:
Old::
TEMPLATE_CONTEXT_PROCESSORS = (
...
'messages.context_processors.inbox',
...
)
New::
TEMPLATE_CONTEXT_PROCESSORS = (
...
'django_messages.context_processors.inbox',
...
)
Templates
---------
To keep the convention that a reuseable app should keep its templates in a
folder with the name of the app, all templates where moved from the folder
``messages`` to the folder ``django_messages``. That means if you provided
your own templates for django-messages, you should also move the directory from
``messages`` to ``django_messages``. Example::
mv myproject/templates/messages myproject/templates/django_messages
Database
--------
Depending on the Database used this process may differ but you have to
rename the existing table ``messages_message`` to ``django_messages_message``.