Add django-knocker support

This commit is contained in:
Iacopo Spalletti 2016-03-26 01:20:14 +01:00
parent 30ea472372
commit 3677129423

View file

@ -33,6 +33,12 @@ except ImportError:
from cmsplugin_filer_image.models import ThumbnailOption # NOQA from cmsplugin_filer_image.models import ThumbnailOption # NOQA
thumbnail_model = 'cmsplugin_filer_image.ThumbnailOption' thumbnail_model = 'cmsplugin_filer_image.ThumbnailOption'
try:
from knocker.mixins import KnockerModel
except ImportError:
class KnockerModel(object):
pass
@python_2_unicode_compatible @python_2_unicode_compatible
class BlogCategory(TranslatableModel): class BlogCategory(TranslatableModel):
@ -91,7 +97,7 @@ class BlogCategory(TranslatableModel):
@python_2_unicode_compatible @python_2_unicode_compatible
class Post(ModelMeta, TranslatableModel): class Post(KnockerModel, ModelMeta, TranslatableModel):
""" """
Blog post Blog post
""" """