render() got an unexpected keyword argument 'renderer'
在自己子类化了djjango .forms.widgets。或者导入三方的库,小部件在您的代码中,有一个依赖项的代码应该是这样的:
from django.forms import widgets
.....
def render(self, name, value, attrs=None):
if value is None:
value = ''
# 传入模板的参数
editor_id = "id_%s" % name.replace("-", "_")
uSettings = {
"name": name,
"id": editor_id,
"value": value
}
.......
只要改变render这个方法就可以,如下
def render(self, name, value, attrs=None, renderer=None):