Fed*_* B. 1 python django django-tables2
我有一个这样定义的表django-tables2:
class MyTable(tables.Table):
action = tables.Column()
class Meta:
model = User
fields = ['name', 'email']
def render_action(self, record):
return 'Foo'
Run Code Online (Sandbox Code Playgroud)
但是该render_action方法被忽略,而是为每一行打印一个 -- 。我错过了什么?
| 归档时间: |
|
| 查看次数: |
1000 次 |
| 最近记录: |