Commit be628a66 authored by fred's avatar fred

allow all logged in users to use ckeditor image management

parent fb7190f7
...@@ -178,6 +178,8 @@ LOGGING = { ...@@ -178,6 +178,8 @@ LOGGING = {
CKEDITOR_CONFIGS = { CKEDITOR_CONFIGS = {
'default': { 'default': {
'filebrowserUploadUrl': '/ckeditor/upload/',
'filebrowserBrowseUrl': '/ckeditor/browse/',
'toolbar_Own': [['Source', 'Format', '-', 'Bold', 'Italic'], 'toolbar_Own': [['Source', 'Format', '-', 'Bold', 'Italic'],
['NumberedList','BulletedList'], ['NumberedList','BulletedList'],
['JustifyLeft', 'JustifyCenter', 'JustifyRight', 'JustifyBlock'], ['JustifyLeft', 'JustifyCenter', 'JustifyRight', 'JustifyBlock'],
......
...@@ -6,6 +6,8 @@ from django.contrib.auth.decorators import login_required ...@@ -6,6 +6,8 @@ from django.contrib.auth.decorators import login_required
from django.contrib import admin from django.contrib import admin
from ckeditor.views import upload as ckeditor_upload
from ckeditor.views import browse as ckeditor_browse
from haystack.views import search_view_factory from haystack.views import search_view_factory
from haystack.forms import FacetedSearchForm from haystack.forms import FacetedSearchForm
from haystack.query import SearchQuerySet from haystack.query import SearchQuerySet
...@@ -26,7 +28,8 @@ sqs = SearchQuerySet().models(Emission, Episode, NewsItem).facet('categories').f ...@@ -26,7 +28,8 @@ sqs = SearchQuerySet().models(Emission, Episode, NewsItem).facet('categories').f
urlpatterns = patterns('', urlpatterns = patterns('',
url(r'^$', 'panikdb.views.home', name='home'), url(r'^$', 'panikdb.views.home', name='home'),
(r'^ckeditor/', include('ckeditor.urls')), url(r'^ckeditor/upload/', login_required(ckeditor_upload)),
url(r'^ckeditor/browse/', login_required(ckeditor_browse)),
url(r'^search/', search_view_factory(view_class=FacetedSearchView, url(r'^search/', search_view_factory(view_class=FacetedSearchView,
form_class=FacetedSearchForm, searchqueryset=sqs), name='haystack_search'), form_class=FacetedSearchForm, searchqueryset=sqs), name='haystack_search'),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment