Permalink
Browse files

Merge branch 'release/2.3rc2'

  • Loading branch information...
2 parents 686ed2f + 56e5867 commit b9bbddb9c56162bccd0254b145710a106767ad18 @beniwohli beniwohli committed Jun 20, 2012
Showing with 5,008 additions and 2,593 deletions.
  1. +5 −2 .gitignore
  2. +16 −0 .travis.yml
  3. +18 −0 AUTHORS
  4. +19 −1 CHANGELOG.txt
  5. +1 −1 cms/__init__.py
  6. +9 −4 cms/admin/change_list.py
  7. +1 −1 cms/admin/forms.py
  8. +91 −41 cms/admin/pageadmin.py
  9. +30 −8 cms/admin/permissionadmin.py
  10. +2 −1 cms/admin/placeholderadmin.py
  11. +5 −26 cms/appresolver.py
  12. +5 −1 cms/conf/__init__.py
  13. +3 −2 cms/conf/patch.py
  14. +7 −4 cms/forms/utils.py
  15. +2 −1 cms/forms/widgets.py
  16. BIN cms/locale/it/LC_MESSAGES/django.mo
  17. +2 −2 cms/locale/it/LC_MESSAGES/django.po
  18. +167 −47 cms/menu.py
  19. +8 −5 cms/middleware/multilingual.py
  20. +15 −5 cms/models/managers.py
  21. +23 −13 cms/models/pagemodel.py
  22. +7 −4 cms/models/placeholdermodel.py
  23. +6 −2 cms/models/pluginmodel.py
  24. +6 −8 cms/plugin_rendering.py
  25. +5 −0 cms/plugins/file/migrations/0005_publisher2.py
  26. +2 −2 cms/plugins/file/templates/cms/plugins/file.html
  27. +5 −0 cms/plugins/flash/migrations/0005_publisher2.py
  28. +5 −0 cms/plugins/googlemap/migrations/0006_publisher2.py
  29. +1 −1 cms/plugins/inherit/models.py
  30. +5 −0 cms/plugins/link/migrations/0007_publisher2.py
  31. +5 −0 cms/plugins/picture/migrations/0007_publisher2.py
  32. +5 −0 cms/plugins/snippet/migrations/0004_publisher2.py
  33. +5 −0 cms/plugins/teaser/migrations/0002_publisher2.py
  34. +5 −0 cms/plugins/text/migrations/0005_publisher2.py
  35. +1 −0 cms/plugins/text/templates/cms/plugins/text_plugin_change_form.html
  36. +7 −7 cms/plugins/text/templates/cms/plugins/widgets/tinymce.html
  37. +2 −0 cms/plugins/text/templates/cms/plugins/widgets/wymeditor.html
  38. +1 −0 cms/plugins/twitter/templates/cms/plugins/twitter_recent_entries.html
  39. +1 −1 cms/plugins/video/templates/cms/plugins/video.html
  40. +9 −6 cms/signals.py
  41. +15 −0 cms/static/cms/css/pages.css
  42. +5 −1 cms/static/cms/css/plugins/cms.placeholders.css
  43. +2 −2 cms/static/cms/css/plugins/cms.toolbar.css
  44. +0 −851 cms/static/cms/css/toolbar.css
  45. +125 −126 cms/static/cms/js/change_form.js
  46. +138 −121 cms/static/cms/js/change_list.js
  47. +59 −1 cms/static/cms/js/csrf.js
  48. +9 −10 cms/static/cms/js/placeholder_editor_registry.js
  49. +186 −181 cms/static/cms/js/plugin_editor.js
  50. +15 −22 cms/static/cms/js/plugins/cms.base.js
  51. +10 −18 cms/static/cms/js/plugins/cms.placeholders.js
  52. +15 −0 cms/static/cms/js/plugins/cms.setup.js
  53. +14 −13 cms/static/cms/js/plugins/cms.toolbar.js
  54. +5 −7 cms/static/cms/js/tinymce.placeholdereditor.js
  55. +21 −22 cms/static/cms/js/wymeditor.placeholdereditor.js
  56. +5 −5 cms/templates/admin/cms/page/change_form.html
  57. +5 −4 cms/templates/admin/cms/page/change_list.html
  58. +11 −0 cms/templates/admin/cms/page/lazy_child_menu.html
  59. +8 −0 cms/templates/admin/cms/page/lazy_menu.html
  60. +9 −3 cms/templates/admin/cms/page/menu.html
  61. +26 −30 cms/templates/admin/cms/page/menu_item.html
  62. +7 −6 cms/templates/admin/cms/page/plugin_change_form.html
  63. +2 −2 cms/templates/admin/cms/page/plugin_forms_history.html
  64. +12 −5 cms/templates/admin/cms/page/plugin_forms_ok.html
  65. +2 −2 cms/templates/admin/cms/page/widgets/plugin_editor.html
  66. +1 −1 cms/templates/cms/new.html
  67. +2 −4 cms/templates/cms/toolbar/placeholder.html
  68. +5 −7 cms/templates/cms/toolbar/placeholder_wrapper.html
  69. +22 −13 cms/templates/cms/toolbar/toolbar.html
  70. +60 −3 cms/templatetags/cms_admin.py
  71. +34 −0 cms/templatetags/cms_js_tags.py
  72. +24 −20 cms/templatetags/cms_tags.py
  73. +0 −15 cms/templatetags/js.py
  74. +190 −0 cms/test_utils/cli.py
  75. +22 −0 cms/test_utils/compat.py
  76. +1 −1 cms/test_utils/fixtures/fakemlng.py
  77. 0 {tests → cms/test_utils}/project/__init__.py
  78. 0 {tests → cms/test_utils}/project/cms_urls_for_apphook_tests.py
  79. 0 {tests → cms/test_utils}/project/fakemlng/__init__.py
  80. 0 {tests → cms/test_utils}/project/fakemlng/fixtures/fakemlng.json
  81. 0 {tests → cms/test_utils}/project/fakemlng/models.py
  82. 0 {tests → cms/test_utils}/project/fileapp/__init__.py
  83. 0 {tests → cms/test_utils}/project/fileapp/models.py
  84. 0 {tests → cms/test_utils}/project/models.py
  85. 0 {tests → cms/test_utils}/project/noadmin_urls.py
  86. 0 {tests → cms/test_utils}/project/nonroot_urls.py
  87. 0 {tests → cms/test_utils}/project/placeholderapp/__init__.py
  88. +3 −2 {tests → cms/test_utils}/project/placeholderapp/admin.py
  89. 0 {tests → cms/test_utils}/project/placeholderapp/models.py
  90. +1 −1 {tests → cms/test_utils}/project/placeholderapp/views.py
  91. 0 {tests → cms/test_utils}/project/pluginapp/__init__.py
  92. 0 {tests → cms/test_utils}/project/pluginapp/models.py
  93. 0 {tests → cms/test_utils}/project/pluginapp/plugins/__init__.py
  94. 0 {tests → cms/test_utils}/project/pluginapp/plugins/manytomany_rel/__init__.py
  95. +2 −2 {tests → cms/test_utils}/project/pluginapp/plugins/manytomany_rel/cms_plugins.py
  96. +1 −1 {tests → cms/test_utils}/project/pluginapp/plugins/manytomany_rel/models.py
  97. 0 {tests → cms/test_utils}/project/sampleapp/__init__.py
  98. +1 −1 {tests → cms/test_utils}/project/sampleapp/admin.py
  99. +2 −2 {tests → cms/test_utils}/project/sampleapp/cms_app.py
  100. BIN {tests → cms/test_utils}/project/sampleapp/media/sampleapp/img/gift.jpg
  101. +1 −2 {tests → cms/test_utils}/project/sampleapp/menu.py
  102. 0 {tests → cms/test_utils}/project/sampleapp/models.py
  103. 0 {tests → cms/test_utils}/project/sampleapp/templates/sampleapp/category_view.html
  104. 0 {tests → cms/test_utils}/project/sampleapp/templates/sampleapp/home.html
  105. +1 −1 {tests → cms/test_utils}/project/sampleapp/urls.py
  106. +1 −1 {tests → cms/test_utils}/project/sampleapp/views.py
  107. 0 {tests → cms/test_utils}/project/second_cms_urls_for_apphook_tests.py
  108. +1 −1 {tests → cms/test_utils}/project/second_urls_for_apphook_tests.py
  109. 0 {tests → cms/test_utils}/project/templates/404.html
  110. 0 {tests → cms/test_utils}/project/templates/add_placeholder.html
  111. 0 {tests → cms/test_utils}/project/templates/base.html
  112. 0 {tests → cms/test_utils}/project/templates/col_three.html
  113. 0 {tests → cms/test_utils}/project/templates/col_two.html
  114. 0 {tests → cms/test_utils}/project/templates/extra_context.html
  115. 0 {tests → cms/test_utils}/project/templates/fail.html
  116. 0 {tests → cms/test_utils}/project/templates/menu/breadcrumb.html
  117. 0 {tests → cms/test_utils}/project/templates/menu/language_chooser.html
  118. 0 {tests → cms/test_utils}/project/templates/menu/menu.html
  119. 0 {tests → cms/test_utils}/project/templates/menu/sub_menu.html
  120. 0 {tests → cms/test_utils}/project/templates/menu/test_language_chooser.html
  121. 0 {tests → cms/test_utils}/project/templates/nav_playground.html
  122. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/base.html
  123. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/child.html
  124. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/nested_super_level1.html
  125. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/nested_super_level2.html
  126. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/nested_super_level3.html
  127. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/nested_super_level4.html
  128. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/outside.html
  129. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/outside_base.html
  130. +1 −0 cms/test_utils/project/templates/placeholder_tests/outside_nested.html
  131. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/test_eleven.html
  132. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/test_five.html
  133. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/test_four.html
  134. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/test_one.html
  135. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/test_seven.html
  136. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/test_six.html
  137. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/test_three.html
  138. 0 {tests → cms/test_utils}/project/templates/placeholder_tests/test_two.html
  139. 0 {tests → cms/test_utils}/project/templates/placeholderapp.html
  140. 0 {tests → cms/test_utils}/project/templates/sidebar_submenu.html
  141. 0 {tests → cms/test_utils}/project/templates/sidebar_submenu_root.html
  142. +1 −0 cms/test_utils/project/templates/subdir/template.html
  143. 0 {tests → cms/test_utils}/project/templates/unicode_placeholder.html
  144. +2 −2 {tests → cms/test_utils}/project/urls.py
  145. +1 −1 {tests → cms/test_utils}/project/urls_for_apphook_tests.py
  146. +51 −0 cms/test_utils/runners.py
  147. +9 −8 cms/test_utils/testcases.py
  148. +26 −0 cms/test_utils/tmpdir.py
  149. +7 −0 cms/test_utils/util/urls.py
  150. +4 −1 cms/tests/__init__.py
  151. +108 −7 cms/tests/admin.py
  152. +19 −6 cms/tests/apphooks.py
  153. +13 −1 cms/tests/docs.py
  154. +3 −0 cms/tests/forms.py
  155. +4 −5 cms/tests/management.py
  156. +318 −110 cms/tests/menu.py
  157. +596 −0 cms/tests/menu_page_viewperm.py
  158. +524 −0 cms/tests/menu_page_viewperm_staff.py
  159. +3 −2 cms/tests/middleware.py
  160. +505 −0 cms/tests/nested_plugins.py
  161. +1 −1 cms/tests/nonroot.py
  162. +98 −5 cms/tests/page.py
  163. +65 −12 cms/tests/permmod.py
  164. +11 −6 cms/tests/placeholder.py
  165. +108 −3 cms/tests/plugins.py
  166. +26 −0 cms/tests/rendering.py
  167. +12 −10 cms/tests/reversion_tests.py
  168. +10 −3 cms/tests/settings.py
  169. +45 −17 cms/tests/templatetags.py
  170. +19 −3 cms/tests/views.py
  171. +1 −1 cms/utils/__init__.py
  172. +5 −2 cms/utils/admin.py
  173. +14 −5 cms/utils/helpers.py
  174. +2 −3 cms/utils/mail.py
  175. +2 −3 cms/utils/moderator.py
  176. +10 −6 cms/utils/page.py
  177. +5 −2 cms/utils/page_resolver.py
  178. +5 −5 cms/utils/permissions.py
  179. +20 −12 cms/utils/plugins.py
  180. +6 −3 cms/utils/reversion_hacks.py
  181. +9 −2 cms/views.py
  182. +13 −1 docs/advanced/i18n.rst
  183. +6 −3 docs/advanced/templatetags.rst
  184. +5 −0 docs/concepts/introduction.rst
  185. +121 −0 docs/concepts/menu_system.rst
  186. +104 −0 docs/concepts/multiple_languages.rst
  187. +1 −4 docs/contribution.rst
  188. +1 −1 docs/extending_cms/extending_examples.rst
  189. +1 −1 docs/extending_cms/placeholders.rst
  190. +20 −0 docs/faq/common_issues.rst
  191. +16 −6 docs/getting_started/configuration.rst
  192. +4 −4 docs/getting_started/installation.rst
  193. +20 −10 docs/getting_started/plugin_reference.rst
  194. +8 −1 docs/getting_started/tutorial.rst
  195. +14 −0 docs/index.rst
  196. +130 −0 docs/upgrade/2.1.rst
  197. +15 −5 docs/upgrade/2.2.rst
  198. +87 −0 docs/upgrade/2.3.rst
  199. +20 −1 docs/upgrade/index.rst
  200. +2 −2 menus/menu_pool.py
  201. +14 −3 menus/models.py
  202. +24 −0 runshell.py
  203. +49 −0 runtests.py
  204. +0 −121 runtests.sh
  205. +57 −0 runtestserver.py
  206. +14 −5 setup.py
  207. +0 −10 tests/.coveragerc
  208. +0 −121 tests/bootstrap.py
  209. +0 −41 tests/buildout.cfg
  210. +0 −9 tests/django-12.cfg
  211. +0 −9 tests/django-124.cfg
  212. +0 −8 tests/django-13.cfg
  213. +0 −16 tests/django-trunk.cfg
  214. +0 −16 tests/project/manage.py
  215. +0 −224 tests/project/settings.py
  216. +0 −18 tests/project/testrunner.py
View
@@ -1,4 +1,5 @@
*.pyc
+!.travis.yml
*.swp
*.lock
*.pid
@@ -7,7 +8,8 @@ cms/django
*.svn
.*
*.xml
-cms.sqlite
+/*env*/
+*.sqlite
cms/media/cms_page_media/
cms/docs/build
example/run
@@ -20,7 +22,8 @@ dist
.project
.pydevproject
.settings
-*.egg-info
+/*.egg-info/
+/*.egg/
develop-eggs
downloads
eggs
View
@@ -0,0 +1,16 @@
+language: python
+python:
+ - "2.6"
+ - "2.7"
+env:
+ - DJANGO="django>=1.3,<1.4"
+ - DJANGO="django>=1.4,<1.5"
+install:
+ - pip install -q $DJANGO django-mptt==0.5.1 django-reversion==1.6 django-classy-tags==0.3.4.1 django-sekizai==0.6.1 html5lib==0.95 jinja2==2.6 PIL==1.1.7 pygments==1.5 south==0.7.5 sphinx==1.1.3 argparse
+script:
+ python runtests.py
+notifications:
+ email: false
+ irc:
+ - "irc.freenode.org#django-cms"
+ - "irc.freenode.org#django-cms-sprint"
View
18 AUTHORS
@@ -1,14 +1,20 @@
Current or previous core committers:
* Angelo Dini
+* Beni Wohlwend
* Chris Glass
+* Daniele Procida
* Eric Robitaille
* Jonas Obrist
* Patrick Lauber
* Peter Ciciman
* Stefan Foulis
* Øyvind Saltvik
+Current and previous core designers:
+
+* Christian Bertschy
+
Contributors (in alphabetical order):
* A. Bram Neijt
@@ -19,6 +25,10 @@ Contributors (in alphabetical order):
* Adrián Ribao
* Alberto Paro
* Alessandro Ronchi
+* Aleš Kocjančič
+* Alvin Mites
+* Andrew Cassidy
+* Andrew Schoen
* angular_circle
* Antoni Aloy López
* Arne Gellhaus
@@ -31,6 +41,7 @@ Contributors (in alphabetical order):
* Bernd Zeimetz
* beshrkayali
* Bob Karreman
+* Bouke Haarsma
* brightwhitefox
* Chanita Siridechkun
* Charpentier Johan
@@ -39,6 +50,7 @@ Contributors (in alphabetical order):
* Chris Hughes
* Chris Wesseling
* Christof Hagedorn
+* Conrado Bührer
* Daniele Procida
* DaNmarner
* Darryl Woods
@@ -56,6 +68,7 @@ Contributors (in alphabetical order):
* fcurella
* Filip Kazimierczak
* Frank Bieniek
+* Gabriel Hurley
* GaretJax
* George Marshall
* Gerard Świderski
@@ -80,10 +93,12 @@ Contributors (in alphabetical order):
* Jonathan Stoppani
* jordanjambazov
* Jorge Vargas (elpargo)
+* Joseph Bergantine
* kar1m
* Keryn Knight
* Kim Blomqvist
* kochin
+* Kristian Øllegaard
* Krzysztof Bandurski
* kunitoki
* Lars Smit
@@ -105,6 +120,7 @@ Contributors (in alphabetical order):
* Martin Kosír
* martinkosir
* mathijs
+* Matt Chisholm
* Maxim Bodyansky
* Maxime Haineault
* mbouchar
@@ -119,6 +135,7 @@ Contributors (in alphabetical order):
* neoprolog
* Orne Brocaar
* padelt
+* Paolo
* Patrick Toal
* Paul van der Linden
* pbgc
@@ -133,6 +150,7 @@ Contributors (in alphabetical order):
* pigletto
* Piotr Kilczuk
* poweredbypenguins
+* Rebecca Breu
* Remco Wendt
* Restless Being
* Robert Pogorzelski
View
@@ -56,10 +56,28 @@
- Fixed a XSS issue in Text Plugins
-==== 2.2.0 (In Development) ====
+==== 2.2.0 (2011-09-10) ====
- Replaced the old plugin media framework with django-sekizai. (This changed some plugin templates which might cause problems with your CSS styling).
- Made django-mptt a proper dependency
- Removed support for django-dbgettext
- Google Maps Plugin now defaults to use HTTPS.
- Google Maps Plugin now uses the version 3 of their API, no longer requiring an API Key.
+
+
+==== 2.3.0 (in development) ====
+
+- Compatibility with Django 1.3.1 and 1.4 (1.2 support dropped)
+- Lazy admin page tree loading
+- Toolbar JS isolation
+- Destructive plugin actions fixed (cancel button, moving plugins)
+- Refactored tests
+- Fixed or clause of placeholder tag
+- Fixed double escaping of icon sources for inline plugins
+- Fixed order of PageSelectWidget
+- Fixed invalid HTML generated by file plugin
+- Fixed migration order of plugins
+- Fixed internationalized strings in JS not being escaped
+- django-reversion dependency upgraded to 1.6
+- django-sekizai dependency upgraded to 0.6.1 or higher
+- django-mptt dependency upgraded to 0.5.1 or higher
View
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
-__version__ = '2.2'
+__version__ = '2.3rc2'
# patch settings
try:
View
@@ -8,7 +8,7 @@
from django.contrib.admin.views.main import ChangeList, ALL_VAR, IS_POPUP_VAR, \
ORDER_TYPE_VAR, ORDER_VAR, SEARCH_VAR
from django.contrib.sites.models import Site
-
+import django
COPY_VAR = "copy"
@@ -54,9 +54,9 @@ class CMSChangeList(ChangeList):
real_queryset = False
def __init__(self, request, *args, **kwargs):
- super(CMSChangeList, self).__init__(request, *args, **kwargs)
from cms.utils.plugins import current_site
self._current_site = current_site(request)
+ super(CMSChangeList, self).__init__(request, *args, **kwargs)
try:
self.query_set = self.get_query_set(request)
except:
@@ -70,7 +70,10 @@ def __init__(self, request, *args, **kwargs):
def get_query_set(self, request=None):
if COPY_VAR in self.params:
del self.params[COPY_VAR]
- qs = super(CMSChangeList, self).get_query_set().drafts()
+ if django.VERSION[1] > 3:
+ qs = super(CMSChangeList, self).get_query_set(request).drafts()
+ else:
+ qs = super(CMSChangeList, self).get_query_set().drafts()
if request:
site = self._current_site
permissions = Page.permissions.get_change_id_list(request.user, site)
@@ -155,7 +158,7 @@ def set_items(self, request):
for page in pages:
- children = page.get_children()
+ children = list(page.get_children())
# note: We are using change_list permission here, because we must
# display also pages which user must not edit, but he haves a
@@ -195,6 +198,8 @@ def set_items(self, request):
if len(children):
# TODO: WTF!?!
# The last one is not the last... wait, what?
+ # children should NOT be a queryset. If it is, check that
+ # your django-mptt version is 0.5.1
children[-1].last = False
page.menu_level = 0
root_pages.append(page)
View
@@ -167,7 +167,7 @@ def clean(self):
site_id = cleaned_data['site']
if id:
if Page.objects.filter(reverse_id=id, site=site_id, publisher_is_draft=True).exclude(pk=self.instance.pk).count():
- raise forms.ValidationError(_('A page with this reverse URL id exists already.'))
+ self._errors['reverse_id'] = self.error_class([_('A page with this reverse URL id exists already.')])
return cleaned_data
def clean_overwrite_url(self):
Oops, something went wrong.

0 comments on commit b9bbddb

Please sign in to comment.