Skip to content

Commit

Permalink
reversions fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
Patrick Lauber committed Jul 7, 2009
1 parent 93c3227 commit e5752e3
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 20 deletions.
5 changes: 2 additions & 3 deletions cms/plugin_pool.py
Expand Up @@ -3,6 +3,7 @@
from cms import settings as cms_settings
from cms.plugin_base import CMSPluginBase


class PluginPool(object):
def __init__(self):
self.plugins = {}
Expand All @@ -25,11 +26,9 @@ def register_plugin(self, plugin):

if 'reversion' in settings.INSTALLED_APPS:
import reversion
import reversion.registration
import reversion.revisions
try:
reversion.register(plugin.model, follow=["cmsplugin_ptr"])
except reversion.revisions.RegistrationError, reversion.registration.RegistrationError:
except reversion.revisions.RegistrationError:

This comment has been minimized.

Copy link
@corrni

corrni Jul 8, 2009

i'm pretty sure instead of:
except reversion.revisions.RegistrationError:
it should be:
except reversion.registration.RegistrationError:

pass

def get_all_plugins(self, placeholder=None):
Expand Down
34 changes: 17 additions & 17 deletions example/settings.py
Expand Up @@ -146,23 +146,23 @@
('sampleapp.urlstwo', 'Second sample application'),
)

CMS_PLACEHOLDER_CONF = {
'right-column': {
"plugins": ('FilePlugin','FlashPlugin','LinkPlugin','PicturePlugin','TextPlugin', 'SnippetsPlugin'),
"extra_context": {"theme":"16_16"},
"name":gettext("right column")
},

'body': {
"extra_context": {"theme":"16_5"},
"name":gettext("body"),
},
'fancy-content': {
"plugins": ('TextPlugin', 'LinkPlugin'),
"extra_context": {"theme":"16_11"},
"name":gettext("fancy content"),
},
}
#CMS_PLACEHOLDER_CONF = {
# 'right-column': {
# "plugins": ('FilePlugin','FlashPlugin','LinkPlugin','PicturePlugin','TextPlugin', 'SnippetsPlugin'),
# "extra_context": {"theme":"16_16"},
# "name":gettext("right column")
# },
#
# 'body': {
# "extra_context": {"theme":"16_5"},
# "name":gettext("body"),
# },
# 'fancy-content': {
# "plugins": ('TextPlugin', 'LinkPlugin'),
# "extra_context": {"theme":"16_11"},
# "name":gettext("fancy content"),
# },
#}


CMS_NAVIGATION_EXTENDERS = (('example.categories.navigation.get_nodes', 'Categories'),)
Expand Down

2 comments on commit e5752e3

@hixi
Copy link

@hixi hixi commented on e5752e3 Jul 8, 2009

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my revision says the same thing: I'll second that

@hixi
Copy link

@hixi hixi commented on e5752e3 Jul 9, 2009

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If using the newest checkout from trunk of django-reversion (http://code.google.com/p/django-reversion/source/checkout), it works fine. Sorry for any hassle that this reporting may have caused.

Please sign in to comment.