Django 1.5.1 的 Grappelli
我正在尝试在 Django 1.5.1 版本中使用 django-grappelli。
但是在设置好之后,满足了 grappelli 的所有要求,我遇到了以下错误。
TemplateSyntaxError at /admin/
'firstof' is not a valid tag or filter in tag library 'future'
In template C:\Python27\lib\site-packages\grappelli\templates\admin\base.html, error at line 1
{% load admin_static %}{% load firstof from future %}{% load i18n grp_tags %}
有什么想法吗?
1 个回答
1
grappelli 2.4.8(与django 1.5兼容)不包含来自future的firstof功能,而grappelli 2.5.0(与django 1.6兼容)则包含这个功能。
参考链接 https://github.com/sehmaschine/django-grappelli/issues/407