rebase plugin over django-cms-text-ckeditor

This commit is contained in:
Benjamin Dauvergne 2014-04-03 11:24:58 +02:00
parent 6ff9c8dcde
commit 735ca6320b
3 changed files with 3 additions and 4 deletions

View File

@ -1 +1 @@
__version__ = '1.2'
__version__ = '2.0'

View File

@ -1,13 +1,12 @@
from django.utils.translation import ugettext_lazy as _
from django.template import loader
from cmsplugin_text_wrapper.cms_plugins import TextPlugin
from djangocms_text_ckeditor.cms_plugins import TextPlugin
from cms.plugin_pool import plugin_pool
class AjaxTextPlugin(TextPlugin):
name = _(u'Text (asynchronous loading)')
ajax_render_template = 'cms_ajax_text_plugin/plugin.html'
text_enabled = True
def get_ajax_body(self, instance, context):
t = loader.get_template(self.ajax_render_template)
@ -17,7 +16,6 @@ class AjaxTextPlugin(TextPlugin):
request = context.get('request')
if 'updatecache' in request.GET:
instance.args = '?updatecache'
context['object'] = instance
edit_mode = request and 'edit' in request.GET
is_ajax = request and request.is_ajax()
if edit_mode or is_ajax:

View File

@ -114,6 +114,7 @@ setup(name="django-cms-ajax-text-plugin",
],
install_requires=[
'django-cms<3',
'djangocms-text-ckeditor',
],
cmdclass={'build': build, 'install_lib': install_lib,
'compile_translations': compile_translations,