Commits

Harro van der Klauw  committed ced3a04

Fixed a small bug.

  • Participants
  • Parent commits 5abbfec

Comments (0)

Files changed (3)

File cmsplugin_news/widgets/tinymce_widget.py

 from tinymce.widgets import TinyMCE, get_language_config
-from django.conf.settings import CMS_MEDIA_URL
+from django.conf import settings.settings.CMS_MEDIA_URL
 from django.utils.translation import get_language
 from django.template.loader import render_to_string
 from django.utils.safestring import mark_safe
         context = {
             'name': name,
             'language': language,
-            'CMS_MEDIA_URL': CMS_MEDIA_URL,
+            'settings.CMS_MEDIA_URL': settings.CMS_MEDIA_URL,
             'installed_plugins': self.installed_plugins,
         }
         return mark_safe(render_to_string(
         
     def _media(self):
         media = super(TinyMCEEditor, self)._media()
-        media.add_js([join(CMS_MEDIA_URL, path) for path in (
+        media.add_js([join(settings.CMS_MEDIA_URL, path) for path in (
                       'js/lib/jquery.js',
                       )])
-        media.add_css({"all":[join(CMS_MEDIA_URL, path) for path in ('css/jquery/cupertino/jquery-ui.css',
+        media.add_css({"all":[join(settings.CMS_MEDIA_URL, path) for path in ('css/jquery/cupertino/jquery-ui.css',
                                                                      'css/tinymce_toolbar.css')]})
         
         return media

File cmsplugin_news/widgets/wymeditor_widget.py

 from django.template.loader import render_to_string
 from django.forms import Textarea
 
-from django.conf.settings import CMS_MEDIA_URL
+from django.conf import settings
 from cms.plugins.text import settings as text_settings
 from django.utils.translation.trans_real import get_language
 
 class WYMEditor(Textarea):
     class Media:
-        js = [join(CMS_MEDIA_URL, path) for path in (
+        js = [join(settings.CMS_MEDIA_URL, path) for path in (
             'js/lib/jquery.js',
             'wymeditor/jquery.wymeditor.js',
             'wymeditor/plugins/resizable/jquery.wymeditor.resizable.js',
         context = {
             'name': name,
             'language': language,
-            'CMS_MEDIA_URL': CMS_MEDIA_URL,
+            'settings.CMS_MEDIA_URL': settings.CMS_MEDIA_URL,
             'WYM_TOOLS': mark_safe(text_settings.WYM_TOOLS),
             'WYM_CONTAINERS': mark_safe(text_settings.WYM_CONTAINERS),
             'WYM_CLASSES': mark_safe(text_settings.WYM_CLASSES),
 
 setup(
     name='cmsplugin-news',
-    version='0.2a',
+    version='0.2a2',
     description='This is a news app/plugin for the django-cms 2',
     author='Harro van der Klauw',
     author_email='hvdklauw@gmail.com',