Skip to content

Commit fe78309

Browse files
committed
Add basic docs, remove stub get_context_data
1 parent 7691bf3 commit fe78309

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

django_tables2/columns/templatecolumn.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,9 @@ class TemplateColumn(Column):
1515
Arguments:
1616
template_code (str): template code to render
1717
template_name (str): name of the template to render
18-
extra_context (dict): optional extra template context
18+
context_object_name (str): name of the context variable to pas the record in, defaults to "record".
19+
extra_context (dict): optional extra template context. If a callable is passed, it will be called with
20+
optional record, table, value, bound_column arguments.
1921
2022
A `~django.template.Template` object is created from the
2123
*template_code* or *template_name* and rendered with a context containing:
@@ -91,6 +93,3 @@ def value(self, **kwargs):
9193
"""
9294
html = super().value(**kwargs)
9395
return strip_tags(html).strip() if isinstance(html, str) else html
94-
95-
def get_context_data(self, **kwargs):
96-
return

0 commit comments

Comments
 (0)