Python 应用RichTextfield的django admin中未出现Ckeditor texteditor

Python 应用RichTextfield的django admin中未出现Ckeditor texteditor,python,django,ckeditor,rich-text-editor,django-ckeditor,Python,Django,Ckeditor,Rich Text Editor,Django Ckeditor,我尝试了所有方法,但是文本编辑器没有出现在richtextfield类型的管理页面中。我安装了django ckeditor,并在settings.py中具有以下内容: 我的网址如下: urlpatterns = [ path('admin/', admin.site.urls), path('', admin.site.urls), path('', include('apps.accounts.urls')), path('', include('apps.blogs.urls')), p

我尝试了所有方法,但是文本编辑器没有出现在richtextfield类型的管理页面中。我安装了django ckeditor,并在settings.py中具有以下内容:

我的网址如下:

urlpatterns = [
path('admin/', admin.site.urls),
path('', admin.site.urls),
path('', include('apps.accounts.urls')),
path('', include('apps.blogs.urls')),
path('', include('apps.enquiry.urls')),
path('', include('apps.packages.urls')),
path('', include('apps.booking.urls')),
path('ckeditor', include('ckeditor_uploader.urls')),
]+static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
# ]+static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)

if settings.DEBUG is True:
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)

我甚至尝试过collectstatic,每个文件都被收集,但richtextfield仍然显示为空白。如何解决这个问题???

使用
DEBUG
False
,Django不提供静态/媒体文件。我已经尝试使用DEBUG is True,但结果相同。您还有其他选择吗???@SarojPaudel:您也没有在URL模式中为
static\u URL
static\u ROOT
包含
static(..)
,但是,最好配置
nginx
/
apache
来提供静态文件。
urlpatterns = [
path('admin/', admin.site.urls),
path('', admin.site.urls),
path('', include('apps.accounts.urls')),
path('', include('apps.blogs.urls')),
path('', include('apps.enquiry.urls')),
path('', include('apps.packages.urls')),
path('', include('apps.booking.urls')),
path('ckeditor', include('ckeditor_uploader.urls')),
]+static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
# ]+static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)

if settings.DEBUG is True:
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)